This repository contains a templated project and utilities to generate packaged Add-on examples that are easily and quickly deployed into Seeq via the Add-on Manager. The example packaged Add-on can be used as a starting point for developing your own Add-ons.
The Add-on Example Generator requires the following software to be installed on your machine:
- Python 3.8 or later
- Node.js 21.7.3 or later
- On Windows, make sure that long paths are enabled both in Windows RegEdit and Git.
- You can enable long paths in the Windows RegEdit by running the following command in PowerShell as an
administrator:
Set-ItemProperty -Path 'HKLM:\SYSTEM\CurrentControlSet\Control\FileSystem' -Name 'LongPathsEnabled' -Value 1
. - To enable long paths in Git, run the following command in Git Bash:
git config --system core.longpaths true
- You can enable long paths in the Windows RegEdit by running the following command in PowerShell as an
administrator:
To install the Add-on Example Generator, follow these steps:
- Clone this repository to your local machine. (e.g.
git clone https://github.com/seeq12/seeq-addon-templates.git
) - Navigate to the root directory of the cloned repository.
- Run
./install_template
(Linux/Mac) or double-click oninstall_template.bat
(Windows) to install the utility.
Once the installation is complete you can run addon --help
from a terminal window (bash/zsh on Mac or Command
Prompt in Windows) to see the available commands.
There are two main commands available in the Add-on Example Generator:
addon create
- This command generates a new Add-on project in the specified directory.addon update
- This command updates the Add-on project in the specified directory with the latest version of the Add-on Example Generator and the updated answers from the user without recreating the existing virtual environment.addon --help
- This command displays the available commands and options.
To create a new Add-on project, follow these steps:
- Run
addon create <path/to/destination/folder>
from a terminal window. - Follow the prompts to answer the questions about the Add-on project.
- Navigate to the destination folder and follow the instructions in the README.md file of your newly created Add-on project.
- Open the project in your favorite IDE to start developing your Add-on. VS Code is a good choice if you don't have a favorite IDE.
- The answers to your prompts are stored in the
.copier-answers.yml
file in the project folder. You can update the answers by runningaddon update <path/to/destination/folder>
from a terminal window. - Navigate to the root directory of the generated project and run the command
python addon.py -h
to get a description of the available commands of Add-on Developer Tools. - Open the README.md file in the project folder to get started with the Add-on project.
To update the Add-on Example Generator, follow these steps:
- Run
git checkout develop
in the root directory of the cloned repository to get the latest version of the Add-on Example Generator. - Run
git pull
to update your local repository with the latest changes. - Run
./install_template
(Linux/Mac) or double-click oninstall_template.bat
(Windows) to re-install the utility.
Once the installation is complete you can run addon --help
from a terminal window (bash/zsh on Mac or Command
Prompt in Windows) to see the available commands.