Git Product home page Git Product logo

tfs-cli's Introduction

Node CLI for VSTS and TFS

NOTE: If you are looking for the new VSTS CLI, see vsts-cli

NPM version

Command utility for interacting with Microsoft Team Foundation Server and Visual Studio Team Services. It is cross platform and supported on Windows, OS X, and Linux.

Setup

First, download and install Node.js 4.0.x or later and NPM (included with the installer)

Linux/OSX

sudo npm install -g tfx-cli

Windows

npm install -g tfx-cli

Commands

To see a list of commands:

tfx

For help with an individual command:

tfx <command> --help

Help info is dynamically generated, so it should always be the most up-to-date authority.

Command sets

  • tfx build (builds): Queue, view, and get details for builds
  • tfx build tasks (build tasks): Create, list, upload and delete build tasks
  • tfx extension (extensions): Package, manage, publisher Team Foundation Server / Team Services extensions
  • tfx workitem (work items): Create, query and view work items.

Login

To avoid providing credentials with every command, you can login once. Currently supported credential types: Personal Access Tokens and basic auth credentials.

NTLM support is under consideration

Warning! Using this feature will store your login credentials on disk in plain text.

Personal access token

Start by creating a personal access token and paste it into the login command.

~$ tfx login
Copyright Microsoft Corporation

> Service URL: {url}
> Personal access token: xxxxxxxxxxxx
Logged in successfully

Examples of valid URLs are:

  • https://marketplace.visualstudio.com
  • https://youraccount.visualstudio.com/DefaultCollection

Basic auth

You can alternatively use basic auth by passing --auth-type basic (see Configuring Basic Auth).

Settings cache

To avoid providing other options in every command, you can save options out to a settings file by adding the --save flag.

~$ tfx build list --project MyProject --definition-name println --top 5 --save

...

id              : 1
definition name : TestDefinition
requested by    : Teddy Ward
status          : NotStarted
queue time      : Fri Aug 21 2015 15:07:49 GMT-0400 (Eastern Daylight Time)

~$ tfx build list
Copyright Microsoft Corporation

...

id              : 1
definition name : TestDefinition
requested by    : Teddy Ward
status          : NotStarted
queue time      : Fri Aug 21 2015 15:07:49 GMT-0400 (Eastern Daylight Time)

If you used --save to set a default value for an option, you may need to override it by explicitly providing the option with a different value. You can clear any saved settings by running tfx reset.

Troubleshooting

To see detailed tracing output, you can set a value for the TFX_TRACE environment value and then run commands. That may offer a clue into the problem (and will certainly help if logging an issue).

Linux/OSX

export TFX_TRACE=1

Windows

set TFX_TRACE=1

PowerShell

$env:TFX_TRACE=1

Contributing

We take contributions and fixes via Pull Request. Read here for the details.

Code of Conduct

This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact [email protected] with any additional questions or comments.

tfs-cli's People

Contributors

t-hugs avatar bryanmacfarlane avatar mmanela avatar joaomoreno avatar vishalkiri avatar akbarmdmd avatar ericsciple avatar bfcamara avatar kesane-msft avatar nschonni avatar cschleiden avatar scottdallamura avatar willsmythe avatar onlyutkarsh avatar gaurav42 avatar colindembovsky avatar mmitrik avatar divais avatar tcyrus avatar sumitsharma0999 avatar janjaali avatar mjring avatar jamesandersen avatar deborshisaha1988 avatar dwilsonactual avatar kant avatar charisk avatar aldoms avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.