Installation
Get GScript up and running on your system.
Prerequisites
Before installing GScript, ensure you have:
- Rust toolchain (1.70 or later)
- Git for cloning the repository
- A text editor (VS Code recommended for LSP support)
Installation Methods
Method 1: Install from Source (Recommended)
Clone and build GScript from source:
bash
# Clone the repository
git clone https://github.com/Parametrix-Labs/gscript-core
cd gscript-core
# Build the project in release mode
cargo build --release
# The CLI tool will be at target/release/gscriptcAdd to your PATH for easy access:
bash
# On Linux/macOS
export PATH="$PATH:$(pwd)/target/release"
# Or copy to a system directory
sudo cp target/release/gscriptc /usr/local/bin/On Windows:
powershell
# Add to PATH via System Environment Variables
# Or copy to a directory already in PATH
copy target\release\gscriptc.exe C:\Windows\System32\Method 2: Install via Cargo (Coming Soon)
Once published to crates.io:
bash
cargo install gscriptMethod 3: Download Pre-built Binaries (Coming Soon)
Download pre-built binaries from the releases page.
Available for:
- Linux (x86_64)
- macOS (x86_64, ARM64)
- Windows (x86_64)
Verify Installation
Check that GScript is installed correctly:
bash
gscriptc --versionYou should see output like:
gscript 0.1.0IDE Support
VS Code Extension
Install the GScript VS Code extension for syntax highlighting, validation, and autocomplete:
- Open VS Code
- Go to Extensions (Ctrl+Shift+X / Cmd+Shift+X)
- Search for "GScript"
- Click Install
Or install from source:
bash
cd gscript-vscode
npm install
npm run compile
code --install-extension .Other Editors
The GScript Language Server Protocol (LSP) implementation can be used with any LSP-compatible editor:
- Neovim: Use
nvim-lspconfig - Emacs: Use
lsp-mode - Sublime Text: Use LSP package
Updating GScript
From Source
bash
cd gscript-core
git pull
cargo build --releaseFrom Cargo
bash
cargo install gscript --forceTroubleshooting
Build Fails on Windows
If you encounter build errors on Windows:
- Ensure you have the latest Visual Studio Build Tools
- Install the C++ development workload
- Try building with
--features vendored-opensslif SSL errors occur
Permission Denied on Linux/macOS
If you get permission errors when installing:
bash
# Option 1: Install to user directory
cargo install --root ~/.local gscript
# Option 2: Use sudo for system-wide install
sudo cargo install --root /usr/local gscriptCargo Not Found
If cargo command is not found:
- Install Rust from https://rustup.rs/
- Restart your terminal
- Verify with
cargo --version
Next Steps
Now that GScript is installed:
- Your First Program - Write your first GScript program
- Getting Started - Complete workflow tutorial
- CLI Commands - Learn the CLI commands
- Examples - Explore example programs
Getting Help
If you encounter issues during installation:
- Check GitHub Issues
- Ask in Discussions
- Review the Troubleshooting Guide