Install OpenLegacy CLI (Windows)
Prerequisites
- Java JDK 17 (required)
- Git BASH for Windows for autocompletion support (optional).
Install OpenLegacy CLI Using Installer
- Download the installation file.
- Unzip the downloaded file.
- Right-click on the file \openlegacy-cli.portable\ol\bin\install.bat and choose Run as administrator.
- Click on Yes when prompted: Do you want to allow this app to make changes to your device?
A message is displayed: Success: Specified value was saved. Press any key to continue... - Add the full path to the directory openlegacy-cli.portable\ol\bin to the System Environment Variable Path.
- Open a new Command Line Interface type window (e.g. cmd or Git BASH).
- Run the ol command to confirm that the CLI is working properly.
C:\WINDOWS\system32>ol
Usage: ol [OPTIONS] COMMAND [ARGS]...
With OL-HUB CLI, you can easily create Module and Asset metadata from your
legacy, store them in the OL-HUB and use them to generate Services. Run "ol
create module" to create your first module.
Options:
-v, -version, --version Display OL-HUB CLI version
-h, --help Show this message and exit
Commands:
add Add Asset to Module metadata
clone Clone metadata
config Configure the CLI or module
copy Copy metadata
create Create metadata
delete Delete metadata from the OL-HUB or Asset/Field properties
deploy Deploy project to cloud
export Export metadata from OL-HUB
import Import metadata to OL Hub
generate Generate Service source code based on a project and a generator
login Login to OL-HUB
logout Logout from OL-HUB
list List modules, projects, connector, etc.
push Push metadata to OL-HUB
set Set Asset/Field properties
start Start service
tag Tag HUB resources
templates Templates operations
test Test an asset or connection
usage Get current tenant objects counters
update Update api-keys, etc.
Install OpenLegacy CLI with Chocolatey
- Install Chocolatey.
- Open your command shell (cmd.exe or powershell.exe) in a Run as Administrator mode.
- Add the OpenLegacy artifacts to Chocolatey.
choco source add --source=https://openlegacy.jfrog.io/artifactory/api/nuget/nuget-chocolatey --name=openlegacy
- Run the choco install command.
choco install openlegacy-cli
If you want to install a specific version, for example 1.5.0, run:
choco install openlegacy-cli --version=1.5.0
- Open a new Command Line Interface type window (e.g. cmd or Git BASH).
- Run the ol command to confirm that the CLI is working properly.
*OpenLegacy packages are also available at Chocolatey.org:
https://chocolatey.org/packages/openlegacy-cli
Upgrade OpenLegacy CLI with Chocolatey
- In your terminal, run the following:
choco upgrade openlegacy-cli
- To confirm that you upgraded OpenLegacy CLI to the latest version, run ol -v.
Uninstall the OpenLegacy CLI with Chocolatey
If you want to uninstall the OpenLegacy CLI run:
choco uninstall openlegacy-cli
Updated 4 months ago