Steps to create custom tasks in different CI/CD platforms.
Go to the task directory and build using NCC compiler. For example;
npm install
npm run build
git commit -m "Update task"
Note: After building the task, delete the node_modules directory. Otherwise it slows down the deployment.
From home directory
tfx extension publish -t <PERSONAL_ACCESS_TOKEN>
Note: --shared-with is needed until the extension is publically shared
To create a UUID for newly created tasks, you can use uuidgen command in Mac.
Cross-platform CLI for Azure DevOps to package your extensions. You can install tfx-cli by using npm, a component of Node.js, by running;
npm i -g tfx-cli
For each new task, create a GUID using;
- MacOS/Linux - uuidgen
- Windows (PowerShell) - New-Guid