Pyra VS Code Extension
License
This extension is licensed under the MIT License. See LICENSE for details.
The license only applies to the VS Code extension code, not the Pyra language or CLI itself.
Basic VS Code support for Pyra.
Included:
.pyra language registration
- syntax highlighting
- snippets
- command palette commands for the Pyra CLI
- a first-pass language server
Current language-server features:
- parser-backed syntax diagnostics
- basic completions
- document symbols
- hover on top-level symbols and built-in packages
- go to definition for top-level symbols in the current file
Editor semantic coloring:
- assignment variables
- function names
- class/struct names
- parameters
- loop/catch variables
- member properties
Commands
This extension exposes the main Pyra CLI workflows as VS Code commands, including:
Pyra: Create Project
Pyra: Project Info
Pyra: Format
Pyra: Test
Pyra: Install
Pyra: Add Package
Pyra: Upgrade
Pyra: Remove Package
Pyra: Run Script
Pyra: Register Package
Pyra: Publish Package
Pyra: Unpublish Package
Pyra: Delete Package
Pyra: Packages
Pyra: My Packages
Pyra: Package Info
Pyra: Docs
Pyra: REPL
Pyra: Account Login
Pyra: Account Status
Pyra: Account Logout
Pyra: Build C++
Pyra: Build Python
Pyra: Build EXE
Configuration
Set the CLI path in VS Code settings:
{
"pyra.cliPath": "pyra"
}
If you want to point at the local repo directly during development, use something like:
{
"pyra.cliPath": "python C:/path/to/Pyra/__main__.py"
}
The language server uses Python separately. If needed, set:
{
"pyra.pythonPath": "python"
}
Build A VSIX
From Pyra/vscode-extension:
npm install
npx vsce package
Or use the package script:
npm install
npm run package:out
Then install the generated .vsix in VS Code with:
Extensions: Install from VSIX...