I have a specific command that I use to delete a Team Foundation Server workspace:
tf workspace /delete "packages sacred";domain\user /server:http://domain:8080/tfs
We've recently had someone leave who prefixed about half of his workspaces with a dash/hyphen, so running my usual command line
tf workspace /delete "-name";domain\user /server:http://domain:8080/tfs
returns the error Unrecognized command option 'name;domain\user'.
If I try using "^-name"
I get TF14061: The workspace ^-name;FirstName LastName does not exist.
tf workspace /delete ^-name;domain\user /server:http://domain:8080/tfs
returns the error Unrecognized command option 'name;domain\user'.
as well.
Double hyphen and single quotes doesn't work either.
Ideally I'd like to know how to delete a workspace that starts with a hyphen using the tf
command line tool, so unless it's impossible, I'm not looking for a link to another tool to use. Is there a way to escape the name correctly?