Version: v3.0.x LTS
Setting up your development environment
Setting up your development environment
Before you follow the development tutorials for creating a Zowe™ CLI plug-in, follow these steps to set up your environment.
Prerequisites
Initial setup
Clone and build your project
-
Create a local development folder named
zowe-tutorialto clone and build all projects in this folder. -
Clone
zowe-cli-sample-pluginand build from source.Clone the repository into your development folder to match the following structure:
zowe-tutorial
└── zowe-cli-sample-plugin- Open a terminal and enter
cd zowe-tutorialto change directory into yourzowe-tutorialfolder. - Enter
git clone https://github.com/zowe/zowe-cli-sample-pluginto clone thezowe-cli-sample-pluginrepository. - Enter
cd zowe-cli-sample-pluginto change directory into yourzowe-cli-sample-pluginfolder. - Enter
npm installto install all dependencies and modules for the project. - Enter
npm run buildto create a production build.
- Open a terminal and enter
Optional step: Run automated tests
We recommend running automated tests on all code changes.
To run automated tests:
- Use Visual Studio Code or your file explorer to copy the content in the
example_properties.yamlfile to thecustom_properties.yamlfile. - Use a text editor to edit the properties within
custom_properties.yamlto contain valid system information for your site. - In a terminal, enter
cd zowe-cli-sample-pluginto change directory into yourzowe-cli-sample-pluginfolder. - Enter
npm run testto run the automated test.
Next steps
After you complete your setup, follow the Installing the sample plug-in tutorial to install this sample plug-in to Zowe CLI.