Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Prepare README for release #38

Merged
merged 5 commits into from
Aug 1, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 29 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,37 @@ OpenFGA is designed to make it easy for application builders to model their perm

## Installation

TBD
- Download and install from [OpenFGA on the VSCode marketplace](https://marketplace.visualstudio.com/publishers/openfga)
- Alternatively, you can find [VSIX releases on GitHub](https://github.com/openfga/vscode-ext/releases) and install it manually

![Installing from VSIX file](resources/vsix-install.png)

## Usage

TBD
The extension currently offers 2 core features, with more to come.

- Syntax Highlighting for OpenFGA files
- A unique theme for OpenFGA for VSCode
- Once installed, go to your extensions
- Click on `OpenFGA` and click `Set Color Scheme`
- Click on `OpenFGA Dark` in the prompt

![Prompt to set OpenFGA Dark color scheme](resources/set-color-scheme.png)


## Development

- Run `npm install` in the root directory. This installs all necessary npm modules.
- Run `npm run webpack` to bundle the code.
- Run `npm run compile && npm test` to execute the client test suite.

### Distribution (Optional)

To generate an installable build of this extension, you can do the following:

- Run `npm install --global @vscode/vsce` to get the latest version of `vsce` for packaging
- Run `vsce package` to generate an installable `VISX` artifact for testing or distribution

### Structure

```
Expand All @@ -45,17 +68,17 @@ TBD

### Running the Client

- Run `npm install` in this folder. This installs all necessary npm modules.
- Open VS Code on this folder.
- Run `npm install` in the root directory. This installs all necessary npm modules.
- Open the root directory in VS Code.
- Press Ctrl+Shift+B to start compiling the client and server in [watch mode](https://code.visualstudio.com/docs/editor/tasks#:~:text=The%20first%20entry%20executes,the%20HelloWorld.js%20file.).
- Switch to the Run and Debug View in the Sidebar (Ctrl+Shift+D).
- Select `Launch Client` from the drop down (if it is not already).
- Press ▷ to run the launch config (F5).

### Testing

- Run `npm install` in this folder. This installs all necessary npm modules.
- Run `npm run compile` to compile the code & client tests.
- Run `npm install` in the root directory. This installs all necessary npm modules.
- Run `npm run compile` to compile the code & client for testing.
- Run `npm test` to execute the client test suite.

## Roadmap
Expand Down
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "openfga-vscode",
"displayName": "OpenFGA",
"description": "Language support for OpenFGA authorization models",
"author": "OpenFGA",
"icon": "./resources/openfga-icon-color.png",
"keywords": [
"openfga",
"authorization",
Expand Down
Binary file added resources/openfga-icon-color.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/set-color-scheme.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/vsix-install.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.