{"id":19767738,"url":"https://github.com/bergmeister/posh-vsts-cli","last_synced_at":"2026-02-26T18:37:38.209Z","repository":{"id":104984555,"uuid":"111589258","full_name":"bergmeister/posh-vsts-cli","owner":"bergmeister","description":"PowerShell tab completion and object conversion of the vsts-cli","archived":false,"fork":false,"pushed_at":"2017-12-10T14:40:27.000Z","size":97,"stargazers_count":14,"open_issues_count":1,"forks_count":1,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-04-06T03:05:58.699Z","etag":null,"topics":["cli","posh","powershell","powershell-module","tabcompletion","vsts"],"latest_commit_sha":null,"homepage":"","language":"PowerShell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bergmeister.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":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-11-21T19:00:24.000Z","updated_at":"2022-01-14T22:09:05.000Z","dependencies_parsed_at":null,"dependency_job_id":"c9b7753f-9de2-4e06-bc48-280315ab9bff","html_url":"https://github.com/bergmeister/posh-vsts-cli","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bergmeister%2Fposh-vsts-cli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bergmeister%2Fposh-vsts-cli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bergmeister%2Fposh-vsts-cli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bergmeister%2Fposh-vsts-cli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bergmeister","download_url":"https://codeload.github.com/bergmeister/posh-vsts-cli/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251742793,"owners_count":21636511,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["cli","posh","powershell","powershell-module","tabcompletion","vsts"],"created_at":"2024-11-12T04:32:08.554Z","updated_at":"2026-02-26T18:37:33.167Z","avatar_url":"https://github.com/bergmeister.png","language":"PowerShell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# posh-vsts-cli [![Build status](https://ci.appveyor.com/api/projects/status/29qq8ghr1mhlkaeh/branch/master?svg=true)](https://ci.appveyor.com/project/bergmeister/posh-vsts-cli/branch/master) [![AppVeyor tests](http://flauschig.ch/batch.php?type=tests\u0026account=bergmeister\u0026slug=posh-vsts-cli)](https://ci.appveyor.com/project/bergmeister/posh-vsts-cli/build/tests) [![codecov](https://codecov.io/gh/bergmeister/posh-vsts-cli/branch/master/graph/badge.svg)](https://codecov.io/gh/bergmeister/posh-vsts-cli) [![PSScriptAnalyzer](https://img.shields.io/badge/Linter-PSScriptAnalyzer-blue.svg)](http://google.com) [![License: GPL v3](https://img.shields.io/badge/License-GPL%20v3-blue.svg)](https://www.gnu.org/licenses/gpl-3.0)\n\nA `PowerShell` helper that enhances the [vsts-cli](https://github.com/Microsoft/vsts-cli) with\n\n- Tab completion\n- Conversion of the JSON or table output to a PowerShell object by providing the `Convert-FromVstsCli` command\n- Wrapping the call to the `vsts` command and the object conversion in the `iv` command alias\n- Installing the `vsts-cli`\n\n![Subgroup and command tab completion](demos/tabcompletion_demo.gif)\n![Subgroup and command tab completion](demos/Convert-fromVstsCli.gif)\n\n## Installation\n\nInstall it from the [PSGallery](https://www.powershellgallery.com/packages/posh-vsts-cli/1.0):\n\n````powershell\nif ($PSVersionTable.PSVersion.Major -ge 5) {\n    Install-Module posh-vsts-cli -Force\n}\nelse {\n    Install-Module TabExpansionPlusPlus -Force\n    Install-Module posh-vsts-cli -Force\n}\nImport-Module posh-vsts-cli\n````\n\nIf you have not already installed the `vsts-cli`, then you can use the following function of `posh-vsts-cli`, which uses the official installer from [here](https://aka.ms/vsts-cli-windows-installer):\n\n````powershell\nInstall-VstsCli\n````\n\nAlternatively you can also just clone/download this repo and import the `posh-vsts-cli.psd1` module.\n\n## Usage\n\nYou can invoke the VSTS CLI directly via `Invoke-VstsCli` or its alias `iv` and the output gets converted to PowerShell objects.\n\n````powershell\n\u003e $builds = iv build list --top 3 --output table\n\u003e $builds[2] # show the object properties of the third build\nDefinitionName : My VSTS build\nId             : 199\nNumber         : 0.1.0+113\nSourceBranch   : master\nReason         : individualCI\nResult         : partiallySucceeded\nStatus         : completed\nDefinitionId   : 3\nQueuedTime     : 2017-10-01 22:41:02.456000\n\u003e $builds[2].Result # you can get at all those properties individually as well\npartiallySucceeded\n````\n\nUnder the hood the vsts cli gets called and then the output gets convertedd to a PowerShell object. It auto-detects if the output was in JSON or table format.\n\n````powershell\n\u003e $builds = vsts build list --top 3 | ConvertFrom-VstsCli\n````\n\nThe output conversion is currently only tested for the `build` commands of the VSTS CLI using `Windows PowerShell 5.1` and `PowerShell Core 6.0-rc` but should work with others as well and with `PowerShell` versions down to 3.0.\n\n## Tab Completion\n\nTab completion already works for groups (e.g. `vstst build`), commands (e.g. `vsts build list`) and options (e.g. `vsts build list --top`). Tab completion is available for the `vsts` and the `iv` commands and commands. The first time you use it in a new shell, you need to press tab twice and give it a second to initialize but after that just one tab completes the current command.\n\n````powershell\n\u003evsts \u003cTAB\u003e\u003cTAB\u003e\n\u003evsts build\n\u003evsts build \u003cTAB\u003e\n\u003evsts build list\n\u003evsts build list \u003cTAB\u003e\n\u003evsts build queue\n\u003evsts build queue --d \u003cTAB\u003e\n\u003evsts build queue --detect\n\u003evsts build queue --detect \u003cTAB\u003e\n\u003evsts build queue --instance\n````\n\nIt is intended to add future support on available entities (e.g. `vsts build queue --definition-name` to tab complete the available definition names).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbergmeister%2Fposh-vsts-cli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbergmeister%2Fposh-vsts-cli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbergmeister%2Fposh-vsts-cli/lists"}