### Starting Documentation Development Server Source: https://github.com/robotcodedev/robotcode/blob/main/CONTRIBUTING.md Commands to set up and run a local development server for the project's documentation using npm. ```bash cd docs npm install npm run dev # Start development server at http://localhost:3000 ``` -------------------------------- ### Local Development Setup with Hatch (Python) Source: https://github.com/robotcodedev/robotcode/blob/main/CONTRIBUTING.md This snippet demonstrates the local development setup for RobotCode using Hatch, a Python project and package manager. It covers environment creation and installing editable packages for VS Code and IntelliJ. ```python # Install Hatch (choose one method): # Option A: Using system package manager (if available) # Ubuntu/Debian: sudo apt install hatch # Fedora: sudo dnf install hatch # Arch: sudo pacman -S hatch # Option B: Using pipx (recommended if not in package manager) pip install pipx pipx install hatch # Option C: Check https://hatch.pypa.io/latest/install/ for other methods # Create development environment hatch env create devel # install needed packages for the vscode and intellij packaging hatch run build:install-bundled-editable ``` -------------------------------- ### Clone Repository and Install Dependencies (Bash) Source: https://github.com/robotcodedev/robotcode/blob/main/CONTRIBUTING.md Clones the RobotCode repository and installs necessary Node.js dependencies using npm. This is a common step for local development. ```bash git clone https://github.com/robotcodedev/robotcode.git cd robotcode # Install Node.js dependencies npm install --also-dev ``` -------------------------------- ### Building Documentation for Production Source: https://github.com/robotcodedev/robotcode/blob/main/CONTRIBUTING.md Commands to build the project's documentation for production deployment using npm. ```bash cd docs npm run build # Build for production npm run preview # Preview production build ``` -------------------------------- ### Install robotcode-repl using pip Source: https://github.com/robotcodedev/robotcode/blob/main/packages/repl/README.md Installs the robotcode-repl package, enabling the interactive REPL for Robot Framework. This is the primary method to get started with the tool. ```console pip install robotcode-repl ``` -------------------------------- ### Building Project Package Source: https://github.com/robotcodedev/robotcode/blob/main/CONTRIBUTING.md Command to package the project for distribution using Hatch. This generates the necessary distribution files. ```bash hatch run build:package ``` -------------------------------- ### Install Robot Framework Core Dependency Source: https://github.com/robotcodedev/robotcode/blob/main/docs/02_get_started/index.md This snippet shows the basic content for a `requirements.txt` file, listing Robot Framework as a core dependency for a project. ```txt robotframework ``` -------------------------------- ### Code Quality and Linting Commands Source: https://github.com/robotcodedev/robotcode/blob/main/CONTRIBUTING.md Execute commands to ensure code quality and adherence to style guides. These commands utilize the 'hatch' build tool for linting and formatting checks. ```bash hatch run lint:typing ``` ```bash hatch run lint:style ``` ```bash hatch run lint:all ``` -------------------------------- ### Managing Node.js Dependencies Source: https://github.com/robotcodedev/robotcode/blob/main/CONTRIBUTING.md Commands to clean and reinstall Node.js dependencies, useful for resolving issues related to package management. ```bash # Clean and reinstall npm dependencies rm -rf node_modules package-lock.json npm install --also-dev ``` -------------------------------- ### Create Basic Robot Framework Test Case Source: https://github.com/robotcodedev/robotcode/blob/main/docs/02_get_started/index.md A simple Robot Framework test case that logs the message 'Hello world' to the debug console. This serves as a basic example for new users. ```robotframework *** Test Cases *** First Test Case Log Hello world ``` -------------------------------- ### Release and Documentation Management Commands Source: https://github.com/robotcodedev/robotcode/blob/main/CONTRIBUTING.md Manage project releases and documentation updates using 'hatch'. This includes updating changelogs, versions, packaging, and publishing. ```bash hatch run build:update-changelog ``` ```bash hatch run build:update-git-versions ``` ```bash hatch run build:bump [major|minor|patch] ``` ```bash hatch run build:package ``` ```bash hatch run build:publish ``` -------------------------------- ### Install Dependencies with pip Source: https://github.com/robotcodedev/robotcode/blob/main/docs/02_get_started/index.md Installs Robot Framework and other dependencies specified in the requirements.txt file using pip. This command should be executed in the project's root directory within the terminal. ```shell pip install -r requirements.txt ``` -------------------------------- ### Python/Backend Development Commands Source: https://github.com/robotcodedev/robotcode/blob/main/CLAUDE.md Commands for setting up the development environment, installing packages, running tests, linting, formatting, building, and publishing Python packages using Hatch. ```bash # Setup development environment hatch env create devel # Install all packages in development mode hatch run install-packages # Run tests hatch run test:test hatch run test:test-reset # Reset regression test snapshots # Linting and formatting hatch run lint:all # Run mypy and ruff checks hatch run lint:fix # Auto-fix formatting and linting issues hatch run lint:typing # Type checking only hatch run lint:style # Code style checks only # Build and packaging hatch run build:package # Build packages hatch run build:publish # Publish to PyPI ``` -------------------------------- ### Git Branching and Committing Source: https://github.com/robotcodedev/robotcode/blob/main/CONTRIBUTING.md Standard Git commands for creating a new feature branch, committing changes, and preparing for a pull request. Essential for collaborative development. ```bash git checkout -b feature/your-feature-name ``` ```bash git commit -m "Your commit message" ``` -------------------------------- ### Install Robot Framework with Robocop and Browser Library Source: https://github.com/robotcodedev/robotcode/blob/main/docs/02_get_started/index.md This snippet demonstrates how to list additional dependencies in a `requirements.txt` file, including Robot Framework, robotframework-robocop for linting, and robotframework-browser for browser automation. ```txt robotframework robotframework-robocop robotframework-browser ``` -------------------------------- ### VS Code Extension Development Commands Source: https://github.com/robotcodedev/robotcode/blob/main/CLAUDE.md Commands for installing dependencies, performing development builds, and production builds for the VS Code extension. ```bash # Install dependencies npm install --include=dev # Build extension npm run compile # Development build npm run package # Production build # Testing npm run test ``` -------------------------------- ### Verify Robot Framework Installation Source: https://github.com/robotcodedev/robotcode/blob/main/docs/02_get_started/index.md This command checks if Robot Framework is installed correctly by displaying its version. It's typically run in a terminal or command prompt within an activated virtual environment. ```shell robot --version ``` -------------------------------- ### Troubleshooting Hatch Environment Issues Source: https://github.com/robotcodedev/robotcode/blob/main/CONTRIBUTING.md Commands to resolve common issues with Hatch environment creation and management, including pruning old environments and recreating the development environment. ```bash # Clear Hatch cache and try again hatch env prune hatch env create devel ``` -------------------------------- ### Hatch Environment Management Source: https://github.com/robotcodedev/robotcode/blob/main/CONTRIBUTING.md Commands for managing Hatch environments, including creation, display, and running tasks within specific environments. Useful for setting up and interacting with project dependencies. ```bash hatch env create devel ``` ```bash hatch env show ``` -------------------------------- ### VS Code Python Interpreter Configuration Source: https://github.com/robotcodedev/robotcode/blob/main/CONTRIBUTING.md Instructions for configuring the VS Code Python interpreter to correctly point to the development environment managed by Hatch. ```bash # Use hatch env find devel to get the exact path # Manually select the interpreter in VS Code using this path ``` -------------------------------- ### Resolving Test Import Errors Source: https://github.com/robotcodedev/robotcode/blob/main/CONTRIBUTING.md Steps to fix import errors in tests by ensuring the correct Hatch environment is activated and development packages are installed. ```bash # Ensure you're in the correct hatch environment # Run hatch run build:install-bundled-editable to install development packages ``` -------------------------------- ### Basic TOML Syntax Example Source: https://github.com/robotcodedev/robotcode/blob/main/docs/02_get_started/configuration.md Demonstrates the fundamental syntax of TOML files, including comments, key-value pairs, and nested sections. ```toml # This is a comment key = "value" [section] nested_key = "nested value" ``` -------------------------------- ### Project Maintenance and Code Generation Commands Source: https://github.com/robotcodedev/robotcode/blob/main/CONTRIBUTING.md Utilize 'hatch' to manage project maintenance tasks and generate essential project files, including syntax definitions and configuration schemas. ```bash hatch run generate-tmlanguage ``` ```bash hatch run create-json-schema ``` ```bash hatch run generate-rf-options ``` ```bash hatch run build:install-bundled-editable ``` -------------------------------- ### Configure Git for Automatic Commit Signing Source: https://github.com/robotcodedev/robotcode/blob/main/CONTRIBUTING.md Sets Git to automatically sign all commits with your GPG key. This is a global configuration for your Git environment. ```bash git config --global commit.gpgsign true ``` -------------------------------- ### Hatch Task Execution Source: https://github.com/robotcodedev/robotcode/blob/main/CONTRIBUTING.md Commands to run specific tasks using Hatch, including tests, linting, and code formatting. Allows for targeted execution of development workflows. ```bash hatch run devel.py312-rf73:test ``` ```bash hatch run lint:all ``` ```bash hatch run lint:style ``` -------------------------------- ### IntelliJ Plugin Development Commands Source: https://github.com/robotcodedev/robotcode/blob/main/CLAUDE.md Commands for building the IntelliJ plugin and running a development instance from the command line. ```bash cd intellij-client # Build plugin ./gradlew build # Run development instance ./gradlew runIde ``` -------------------------------- ### Installing robotcode-runner Source: https://github.com/robotcodedev/robotcode/blob/main/docs/02_get_started/configuration.md Provides the command to install the necessary package for running Robot Framework tests using robotcode. ```bash pip install robotcode[runner] ``` -------------------------------- ### Verify Signed Commits Source: https://github.com/robotcodedev/robotcode/blob/main/CONTRIBUTING.md Displays the commit history, including signature verification status for each commit. Useful for confirming that your commits are indeed signed. ```bash git log --show-signature ``` -------------------------------- ### Running All Tests with Hatch Source: https://github.com/robotcodedev/robotcode/blob/main/CONTRIBUTING.md Commands to execute tests across various Python and Robot Framework versions using Hatch. The `test` command runs all combinations, while specific versions can be targeted. ```bash hatch run test ``` ```bash hatch run test tests/specific_test.py ``` -------------------------------- ### Robot Framework Example Snippet Source: https://github.com/robotcodedev/robotcode/blob/main/resources/report_issue_body_template.md This snippet demonstrates a basic Robot Framework test case structure, including settings and a test case with a keyword call. It serves as an example for users to provide code when reporting issues. ```robotframework ***Settings*** Library Collections ***Test Cases*** a simple test do something # this should shown something ``` -------------------------------- ### Targeted Test Execution with Hatch Source: https://github.com/robotcodedev/robotcode/blob/main/CONTRIBUTING.md Execute tests against specific Python and Robot Framework version combinations using Hatch. This is crucial for focused development and debugging. ```bash hatch run test.rf70:test ``` ```bash hatch run test.rf73:test ``` ```bash hatch run devel.py39-rf73:test ``` ```bash hatch run devel.py312-rf73:test ``` ```bash hatch run rfbeta:test ``` ```bash hatch run rfmaster:test ``` ```bash hatch run rfdevel:test ``` -------------------------------- ### TOML: Example of passing arguments to Robot Framework Source: https://github.com/robotcodedev/robotcode/blob/main/docs/03_reference/config.md Provides an example of how to pass command-line arguments to the Robot Framework executable via the robot.toml file. ```toml args = ["-t", "abc"] ``` -------------------------------- ### Install robotcode-repl-server using pip Source: https://github.com/robotcodedev/robotcode/blob/main/packages/repl_server/README.md This command installs the robotcode-repl-server package using pip, the Python package installer. Ensure you have Python and pip installed. ```console pip install robotcode-repl-server ``` -------------------------------- ### Install RobotCode CLI Tool Source: https://github.com/robotcodedev/robotcode/blob/main/docs/03_reference/cli.md Installs the core RobotCode CLI tool and optional packages for expanded functionality. Use `[all]` to install all dependencies. ```bash pip install robotcode ``` ```bash pip install robotcode[runner] pip install robotcode[analyze] pip install robotcode[debugger] pip install robotcode[repl] pip install robotcode[language-server] ``` ```bash pip install robotcode[all] ``` -------------------------------- ### Get Robot Framework Environment Information Source: https://github.com/robotcodedev/robotcode/blob/main/docs/03_reference/cli.md Displays information about the current Robot Framework environment. This command provides insights into the setup and configuration. ```bash robotcode discover info ``` -------------------------------- ### Install robotcode-analyze Source: https://github.com/robotcodedev/robotcode/blob/main/packages/analyze/README.md Installs the robotcode-analyze package using pip. This is the primary method for integrating the tool into your Python environment. ```console pip install robotcode-analyze ``` -------------------------------- ### Install robotcode-runner Source: https://github.com/robotcodedev/robotcode/blob/main/packages/runner/README.md This snippet shows the command to install the robotcode-runner package using pip. It's a straightforward installation for Python projects. ```console pip install robotcode-runner ``` -------------------------------- ### Commit Message Format Source: https://github.com/robotcodedev/robotcode/blob/main/CONTRIBUTING.md The standard format for commit messages, including type, scope, subject, body, and footer for clear and consistent project history. ```text ():