6 tf - Team Foundation Client
11 'tf' [/server:<server name or ip address>] [/login:<login credentials>]
12 <command> [<command arguments>]
17 'tf' is a source control client for Microsoft Team Foundation Server.
21 */login:username [,password]*::
22 Provide authentication credentials. If you don't specify a
23 password you will be prompted for one. If you have
24 gnome-keyring support enabled, TF will store the login
25 credentials on your default keyring if configured to do so
26 (see "Credentials.Save" configuration option below).
28 */server:<server name or ip address>*::
29 Specify the Team Foundation Server. If you are within a mapped
30 working folder, you don't need to specify the /server option,
31 as this information is stored in the VersionControl.config
37 Pend an add on a file or files to the repository. To commit, you
38 must issue a checkin command.
40 *changeset <changeset id>*::
41 Show changeset details: committer, date, comment, and files changed.
42 The changeset id is just an integer - no "C" prefix is required as in
43 the diff command below.
45 *checkin [ <filenames or path> /recursive /comment:<comment> ]*::
46 Checkin pending changes in workspace. With no arguments, this command
47 will checkin all files in your workspace, not just all files underneath
48 your current working directory. Due to a limitation in Mono.GetOptions,
49 the /comment parameter cannot include spaces. This will be fixed soon!
51 *checkout <filenames>*::
52 Checkout a file for editing. Command alias: edit.
54 *configure [ <key> | <key> <value> ]*::
55 With no arguments, displays current configuration. With 1 argument,
56 deletes the configuration setting <key>. With 2 arguments,
57 sets the value of <key> to <value>. See Configuration section below
58 for more details on valid settings.
60 *delete <filenames> [ /recursive ]*::
61 Pend a delete against a file or files from the repository. To commit, you
62 must issue a checkin command.
64 *diff <filename or path or changeset id> [ /old | /modified ]*::
65 Show pending changes as a diff. With /old, shows changes from current
66 workspace to latest on the server as a diff. With /modified, shows
67 changes to writable workspace files as a diff - another way to preview
68 changes before using the *online* command. With a changeset id, like
69 C12278, the command will show you a diff of the files changed in that
73 List files in specified server path. A way to explore the folders on the server
74 without setting up a workspace and downloading the files.
77 Update local repository with latest versions from the server.
78 Think "cvs/svn update". Note: Files are initially set to read-only, until
79 checked out with the *checkout* command.
81 *history <filename | path > [ /format:detailed /recursive ]*::
82 Display changelog history for specified file. If you are looking for a
83 git-log/svn log type function use this and add /recursive.
85 *label <labelname> <itemspec> [ /recursive ]*::
86 Add a label or tag to an item.
88 *labels [ <labelname> /owner:<ownername> /format:detailed ]*::
89 Displays labels or tags. Can optionally filter by <labelname> and <ownername>.
91 *ls-files <path> [ /deleted | /modified | /old | /unknown ]*::
92 Shows known, deleted, modified, old, or unknown files under the given path.
93 With no options, ls-files shows known files. /old option by default shows
94 only files in your workspace which are out of date, not new files on the
95 server you've not yet fetched. To show those files as well, use "/old /all".
96 This behavior may change in future releases, based on user feedback.
98 *online <path> [ /added | /modified | /deleted | /preview ]*::
99 Finds all writable files and marks them as pending changes on the server.
100 It also finds all unknown files and marks them as pending adds, missing
101 files are marked as pending deletes. A great command to use if you apply
102 a patch to a clean tfs-managed tree and want to pend the changes to the
103 server for checkin. The /added, /modified, /deleted flags can be used
104 to show just additions, just modifications, or just deletions respectively.
105 These flags may be combined. With no flags, all changes are shown.
108 Show server permissions on a file. Command alias: permission.
110 *properties <filenames> [ /recursive ]*::
111 Show detailed properties for each filename including server locks, encoding,
112 last modified date, changeset id, and whether the file has a newer version
115 *rename <oldname> <newname>*::
116 Rename a file or files in the repository.
118 *status [<filenames> /recursive ]*::
119 Show status of all pending changes in local workspace. Optional paths/filenames
120 may be added to narrow the resulting output.
123 Delete all files not under version control. Use /preview to see what
126 *undo <filenames> [ /recursive ]*::
127 Undo pending changes.
129 *unlabel <labelname> <itemspec>*::
130 Add a label or tag to an item.
132 *workspace [ /new | /delete ]*::
135 *workspaces [ /format:detailed ]*::
136 List workspaces in server repository. Use /format:detailed for additional
139 *workfold [ <server path> <local path> | /unmap <local path> ]*::
140 Manage working folders. With no arguments, print current working folder
141 mappings. With a server path and local path, creates a new working folder
144 *view <filenames | server paths>*::
145 Displays the latest version of the specified file or files.
150 *List all workspaces on the server 10.2.10.2, using a username of "domain\\username" and a password of "password".*::
151 tf workspaces /server:10.2.10.2 /login:domain\\username,password /owner:"+++*+++" /computer:"+++*+++"
153 *Create a workspace with the name "workspaceName" with an owner name of ownerName.*::
154 tf workspace /new "workspaceName;ownerName"
156 *Setup a working folder for the project "ProjectName" in directory ~/src/project.*::
157 tf workfold "$/ProjectName" /home/username/src/project
159 *Fetch/Get all files in folder in project "ProjectName" to local machine.*::
160 tf get /recursive /home/username/src/project
162 *Delete the workspace "workspaceName" created above.*::
163 tf workspace /delete workspaceName
168 You can execute multiple commands in sequence in a single run of TF,
169 by separating the commands with '%'. Here's how you might checkin a
170 patch with a single run of TF:
174 $ patch -p1 < ~/new-feature.diff
175 $ tf online % checkin
181 The TF client stores configuration settings in ~/.tf/TfClient.config.
184 The TF client will display a summary of pending
185 changes and ask for confirmaton below committing changes to the server
186 when set to "true". The default is "false". It's non-trivial to rollback
187 a committed change, so this option is highly recommended.
190 The TF client will always checkout the latest version rather than
191 the workspace version if this setting is set to "true". Note: this option
192 only effects the checkout command, not the "online" command.
195 The TF client will store login credentials if this
196 setting is set to "true". The default is "false".
199 A comma separated list of files to ignore. Currently, only the "online"
200 command honors this setting. The wildcard characters * and ? are supported.
201 Example setting: "*.dll,*.pdb".
204 The TF client will automatically do recursive gets when set
205 to "true". IMHO, this is far more useful than the default behavior.
207 *History.DefaultToCwd*::
208 The TF client will default to the current working directory if not options
209 are given when running the subcommand "history". The default behavior of the
210 standard client is to require a path for all history queries. This option
211 provides an optional and more sensible default.
213 *History.Recursive*::
214 The TF client will automatically do recursive history queries when set
215 to "true". IMHO, this is far more useful than the default behavior.
218 The TF client will automatically do a recursive online command when set
219 to "true". IMHO, this is far more useful than the default behavior for
220 clean trees. Not as helpful for trees littered with build output files.
225 The TF client keeps a cache of workspaces and folder mappings in
226 ~/.tf/Cache/VersionControl.config. Here's a sample file:
229 <VersionControlServer>
231 <ServerInfo uri="http://10.2.1.2:8080/">
232 <WorkspaceInfo name="neo" ownerName="DOMAIN\USER" computer="MYBOX" comment="" LastSavedCheckinTimeStamp="4/26/2007 11:55:50 PM">
234 <MappedPath path="/home/jreed/Source/xyz-project" />
235 <MappedPath path="/home/jreed/Source/abc-project" />
240 </VersionControlServer>
246 TFS doesn't have built in support for tracking file attributes, for
247 example, whether the file is executable or not. The TF client included
248 in this package makes use of libmagic to determine whether a file
249 should be marked executable or not.
254 http://groups.google.com/group/tf4mono
255 http://msdn2.microsoft.com/en-us/library/bb130146(VS.80).aspx
256 http://msdn2.microsoft.com/en-us/teamsystem/default.aspx
257 http://msdn2.microsoft.com/en-us/cc31bk2e(VS.80).aspx
262 Written by Joel Reed <joelwreed@gmail.com>
267 Documentation by Joel Reed <joelwreed@gmail.com>