{"id":24017625,"url":"https://github.com/piraces/azure-devops-bicep-task","last_synced_at":"2026-02-06T22:02:57.180Z","repository":{"id":40486513,"uuid":"332497583","full_name":"piraces/azure-devops-bicep-task","owner":"piraces","description":"Simple yet useful Azure DevOps set of tasks that allow to install and run Microsoft Bicep CLI commands in Azure Pipelines","archived":false,"fork":false,"pushed_at":"2026-01-21T21:07:54.000Z","size":984,"stargazers_count":13,"open_issues_count":1,"forks_count":7,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-01-22T09:58:24.411Z","etag":null,"topics":["azure-devops","azure-devops-extension","azure-devops-extensions","azure-devops-pipelines","bicep","bicep-cli","ci-cd","devops"],"latest_commit_sha":null,"homepage":"https://marketplace.visualstudio.com/items?itemName=piraces.bicep-tasks","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/piraces.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2021-01-24T16:28:17.000Z","updated_at":"2026-01-21T21:07:51.000Z","dependencies_parsed_at":"2023-11-13T10:27:02.980Z","dependency_job_id":"aa1c933e-3908-4619-86f4-961b565b3575","html_url":"https://github.com/piraces/azure-devops-bicep-task","commit_stats":null,"previous_names":[],"tags_count":19,"template":false,"template_full_name":null,"purl":"pkg:github/piraces/azure-devops-bicep-task","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/piraces%2Fazure-devops-bicep-task","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/piraces%2Fazure-devops-bicep-task/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/piraces%2Fazure-devops-bicep-task/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/piraces%2Fazure-devops-bicep-task/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/piraces","download_url":"https://codeload.github.com/piraces/azure-devops-bicep-task/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/piraces%2Fazure-devops-bicep-task/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29178565,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-06T20:14:21.878Z","status":"ssl_error","status_checked_at":"2026-02-06T20:14:21.443Z","response_time":59,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["azure-devops","azure-devops-extension","azure-devops-extensions","azure-devops-pipelines","bicep","bicep-cli","ci-cd","devops"],"created_at":"2025-01-08T09:42:17.297Z","updated_at":"2026-02-06T22:02:57.174Z","avatar_url":"https://github.com/piraces.png","language":"TypeScript","readme":"# Azure DevOps Bicep Tasks\n![Node.js CI](https://github.com/piraces/azure-devops-bicep-task/workflows/Node.js%20CI/badge.svg)\n[![Build Status](https://raulejea.visualstudio.com/Bicep%20Tasks/_apis/build/status/Test%20Bicep%20Tasks%20with%20latest%20version?branchName=main)](https://raulejea.visualstudio.com/Bicep%20Tasks/_build/latest?definitionId=19\u0026branchName=main)\n\n![Bicep Logo](https://raw.githubusercontent.com/piraces/azure-devops-bicep-task/main/images/bicep_logo.png)\n\nThis is a simple yet useful Azure DevOps set of tasks that allow to install and run [Microsoft Bicep CLI](https://github.com/Azure/bicep) commands in Azure Pipelines (cross-platform).\n\n[View in Marketplace](https://marketplace.visualstudio.com/items?itemName=piraces.bicep-tasks)\n\n## ✨ What's New in v0.6.0\n\n- **🚀 Node 20 Runtime**: Tasks now run on Node 20 (with Node 16 fallback), eliminating the end-of-life Node 6 warning\n- **📦 Updated Dependencies**: All dependencies updated to their latest versions for improved security and performance\n- **🤖 Automated Publishing**: New GitHub Actions workflow for automated releases to the Marketplace\n\n# Install Bicep CLI task\n\nThis task downloads and installs in the agent any version of the Bicep CLI available (adding it to the PATH environment variable). After running the task, the `Run Bicep CLI build command task` can be used. Alternatively, `bicep` command could be used in a script directly.\n\nThe tool is cached in the agent after download, so subsequent runs will be faster.\n\nThis task takes only one `version` parameter input (semantic versioning) which is the version of Bicep to download.\n\n## Sample YAML with the task\n\n```yaml\nsteps:\n- task: BicepInstall@0\n  inputs:\n    version: 0.10.13\n```\n\n# Run Bicep CLI build command task\n\nThis tasks runs the `bicep build` command with an input path containing `.bicep` file(s) ([glob](https://en.wikipedia.org/wiki/Glob_(programming)) is supported). After running the task, the resulting `.json` files are left in the same folder as the `.bicep` file resides.\n\nThis task takes only one `sourceDirectory` or `sourceFile` parameter input which is the path where the bicep file/files reside (can be a glob, directory, or a single file).\n\n**Note**: When using a directory as `sourceDirectory`, all `.bicep` files in the directory will be processed (including files in subfolders), and non-.bicep files will be automatically ignored. Example: `./bicep_files` would be interpreted as `./bicep_files/**/*.bicep`.\n\n**Tip**: You can use glob patterns to have more control over which files to process. For example:\n- `./templates/**/*.bicep` - Process all .bicep files recursively\n- `./templates/*.bicep` - Process only .bicep files in the root of templates folder\n- `./templates/{main,modules}/*.bicep` - Process .bicep files in specific subdirectories\n\n## Sample YAML with the task (for multiple files)\n\n```yaml\nsteps:\n- task: BicepBuild@0\n  inputs:\n    process: 'multiple'\n    sourceDirectory: '.\\bicep_files\\*.bicep'\n    stdout: false # Note if stdout is true 'outputDirectory' will not be interpreted\n    outputDirectory: '.\\bicep_files\\out' # Only when 'stdout' is false or not defined\n```\n\n## Sample YAML with the task (for single file)\n\n```yaml\nsteps:\n- task: BicepBuild@0\n  inputs:\n    process: 'single'\n    sourceFile: '.\\bicep_files\\sample1.bicep'\n    stdout: false # Note if stdout is true 'outputDirectory' will not be interpreted\n    outputFile: '.\\bicep_files\\sample1.out.json' # Only when 'stdout' is false or not defined and 'outputDirectory' is empty or not defined\n```\n\n# Run Bicep CLI decompile command task\n\nThis tasks runs the `bicep decompile` command with an input path containing `.json` file(s) ([glob](https://en.wikipedia.org/wiki/Glob_(programming)) is supported). After running the task, the resulting `.bicep` files are left in the same folder as the `.json` file resides.\n\nThis task takes only one `sourceDirectory` or `sourceFile` parameter input which is the path where the bicep file/files reside (can be a glob, directory, or a single file).\n\n**Note**: When using a directory as `sourceDirectory`, all `.json` files in the directory will be processed (including files in subfolders), and non-.json files will be automatically ignored. Example: `./arm_templates` would be interpreted as `./arm_templates/**/*.json`.\n\n**Tip**: You can use glob patterns to have more control over which files to process. For example:\n- `./templates/**/*.json` - Process all .json files recursively\n- `./templates/*.json` - Process only .json files in the root of templates folder\n\n## Sample YAML with the task (for multiple files)\n\n```yaml\nsteps:\n- task: BicepDecompile@0\n  inputs:\n    process: 'multiple'\n    sourceDirectory: '.\\arm_templates\\*.json'\n    stdout: false # Note if stdout is true 'outputDirectory' will not be interpreted\n    outputDirectory: '.\\arm_templates\\out' # Only when 'stdout' is false or not defined\n```\n\n## Sample YAML with the task (for single file)\n\n```yaml\nsteps:\n- task: BicepDecompile@0\n  inputs:\n    process: 'single'\n    sourceFile: '.\\arm_templates\\arm_storage_account.json'\n    stdout: false # Note if stdout is true 'outputDirectory' will not be interpreted\n    outputFile: '.\\arm_templates\\sample1.out.bicep' # Only when 'stdout' is false or not defined and 'outputDirectory' is empty or not defined\n```\n\n# Important notes\n\nStarting on version 0.3 of the tasks, the user can specify an `outputProcess` input to choose the output option. The available options are:\n\n- `default`: Default (same name and directory as input files).\n- `outDir`: Selecting an output directory with the input `outputDirectory`.\n- `outFile`: Selecting an output file with the input `outputFile`.\n- `stdout`: Standard output (stdout).\n\nNevertheless, this option can be skipped and only specify the inputs `outputDirectory`, `outputFile`, `stdout` accordingly. **Note that the inputs are exclusive. Do not specify multiple output options at once**.\n\nThe order of preference of the inputs if `outputProcess` is not defined is the following:\n\n- `stdout`: if set to true.\n- `outputFile`: if set.\n- `outputDirectory`: if set.\n\nIf no input regarding output options is set, it will default to the source directory and source filename as output (only changing the extension).\n\n## Warnings handling\n\nStarting with the patch 0.3.4, warnings in the build or decompilation processes will report a `SucceededWithIssues` status, showing all warnings in the pipeline execution.\n\n## Bicep versions support\n\nPlease consider using the latest version of the Bicep CLI, this extension does not ensure a correct execution with versions prior to `0.4.x`. \n\n## Decompile command\n\nStarting on version `0.3.7` of this extension, the decompile command will overwrite the destination file if it exists.\n\n# Local Development\n\n**Requirements:**\n- **Node.js 20.x or higher** (recommended to match the production runtime)\n- [Bicep](https://github.com/Azure/bicep) installed locally\n- [TypeScript](https://www.typescriptlang.org/download) installed globally (`npm i typescript -g`)\n\n1. Run `npm install` in the root directory.\n2. Run `npm run build` in the root directory.\n3. Define the needed agent environment parameters:\n\n```powershell\n# For PowerShell:\n$env:AGENT_TEMPDIRECTORY = \"C:\\TEMP\" # Or any other existing directory\n$env:AGENT_TOOLSDIRECTORY = \"C:\\tools\" # Or any other existing directory\n```\n```bash\n# For bash:\nexport AGENT_TEMPDIRECTORY=\"/temp\" # Or any other existing directory\nexport AGENT_TOOLSDIRECTORY=\"/tools\" # Or any other existing directory\n```\n\n4. (Optional) Set variables for the tasks (as you want to test):\n\n```powershell\n# For PowerShell:\n$env:INPUT_VERSION = \"0.10.13\" # Or any other valid Bicep version\n$env:INPUT_PROCESS = \"multiple\" # Selection between 'multiple' or 'single' file(s) processing\n$env:INPUT_SOURCEDIRECTORY = \"C:\\bicep_files\\*.bicep\" # Or any other existing directory with bicep file(s)\n$env:INPUT_SOURCEFILE = \"C:\\bicep_files\\sample1.bicep\" # Or any other existing bicep file\n$env:INPUT_STDOUT = $false # To print the output to standard output (stdout) or not\n$env:INPUT_OUTPUTDIRECTORY = \"C:\\bicep_files\\out\" # Or any other existing directory to store the json generated file(s)\n$env:INPUT_OUTPUTFILE = \"C:\\bicep_files\\sample1.out.json\" # Or any other path/filename to store the generated file\n```\n```bash\n# For bash:\nexport INPUT_VERSION=\"0.10.13\" # Or any other valid Bicep version\nexport INPUT_PROCESS = \"multiple\" # Selection between 'multiple' or 'single' file(s) processing\nexport INPUT_SOURCEDIRECTORY=\"C:\\bicep_files\\*.bicep\" # Or any other existing directory with bicep file(s)\nexport INPUT_SOURCEFILE = \"C:\\bicep_files\\sample1.bicep\" # Or any other existing bicep file\nexport INPUT_STDOUT = false # To print the output to standard output (stdout) or not\nexport INPUT_OUTPUTDIRECTORY = \"C:\\bicep_files\\out\" # Or any other existing directory to store the json generated file(s)\nexport INPUT_OUTPUTFILE = \"C:\\bicep_files\\sample1.out.json\" # Or any other path/filename to store the generated file\n```\n\n5. Run `node src/install/index.js` and `node src/run/index.js` to execute the two tasks.\n\n*Note:* the `bicep_files` and the `arm_templates` directories containing `.bicep` and `.json` files are only for development and testing purposes.\n\n# Contributing\n\nFeel free to open an issue or a PR if you want to without any problem :)\n\n# License\n\nThis project is licensed under the [MIT License](https://github.com/piraces/azure-devops-bicep-task/blob/main/LICENSE).\n\nSee the LICENSE file in the root of this repository.\n\n# Attributions\n\nThe base logo for the tasks and the extension is property of the Microsoft Bicep project, used without any commercial purpose.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpiraces%2Fazure-devops-bicep-task","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpiraces%2Fazure-devops-bicep-task","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpiraces%2Fazure-devops-bicep-task/lists"}