Skip to content

Latest commit

 

History

History
67 lines (41 loc) · 2.1 KB

File metadata and controls

67 lines (41 loc) · 2.1 KB

🚀 HAI VS Code Plugin

The HAI VS Code Plugin enhances the capabilities of the HAI Code Generator by providing a user-friendly UI for seamless task execution. This plugin Leveraging Specif AI to load and execute tasks efficiently, offering a streamlined development experience directly within VS Code.

Table of Contents

🛠 Setup and Build

Prerequisites

  • Node.js == 20.18.1
  • npm package manager
  • HAI Code Generator binary file
  • VS Code installed

Step-by-Step Guide

1️⃣ Install Dependencies

npm install

2️⃣ Move CLI Binary to Plugin Project

Create a directory cli in the plugin project root and move the HAI Code Generator binary (dist/cli-<version>-<platform> from the HAI Code Generator) into it:

mkdir cli
mv ../code-generator/dist/cli-* ./cli/

3️⃣ Start the Plugin in Development Mode

Ensure that the plugin folder is opened in a separate VS Code window.

Press fn + F5 in VS Code to launch the plugin in a new Extension Development Host window.

💡 Tip: Use this environment for testing and debugging the plugin during development.

4️⃣ Build the VSIX package

To get the VSIX build, run npm run build

🧩 Extensions Required

Ensure the following extensions are installed in VS Code for local testing:

  1. dbaeumer.vscode-eslint - Ensures code quality with ESLint.
  2. connor4312.esbuild-problem-matchers - Handles build issues with ESBuild.
  3. ms-vscode.extension-test-runner - Facilitates running tests for the plugin.

Install these extensions from the VS Code Extensions Marketplace if not already present.

🛠️ Troubleshooting

  • Issue: Plugin fails to load tasks from Specif AI.

    • Solution: Verify that the tasks have been generated correctly.
  • Issue: Development host does not launch.

    • Solution: Verify all required dependencies and extensions are installed.

For additional help, reach out to the project maintainers or check the documentation in the repository.