:q to quit
Simple way to achieve a colored SVN diff
I'm working in a group project currently and annoyed at the lack of output by my teammates. Wanting hard metrics of how awesome I am and how awesome they aren't, I wrote this command up. It will print a full repository listing of all files, remove the directories which confuse blame, run svn blame on each individual file, and tally the resulting line counts. It seems quite slow, depending on your repository location, because blame must hit the server for each individual file. You can remove the -R on the first part to print out the tallies for just the current directory. Show Sample Output
exclude-dir option requires grep 2.5.3
Put the positive clauses after the '-o' option.
If you don't want to commit files to subversion, and don't want those file to show up when doing an "svn stat", this command is what you need Show Sample Output
just change the date following the -r flag, and/or the user name in the user== conditional statement, and substitute yms_web with the name of your module
This command will output the total number of files in a SVN Repository. Show Sample Output
rsyncs files to a server excluding listed files
also a file can be used to exclude common exclude rules and/or to exclude a ton of files, like so:
rsync --exclude-from '~/.scripts/exclude.txt'
where exclude.txt has one rule per line:
*.mp3
*.svn*
Allows you to save progress without committing.
To revert to an undo point, svn revert then apply the undo point with patch.
svn revert -R . && patch -p0 < .undo/2009-03-27_08:08:11rev57
Similar: http://www.commandlinefu.com/commands/view/373/archive-all-files-containing-local-changes-svn
Show Sample Output
Get the svn info, grep for the "URL" of the repository, pull out the tag/branch/trunk, and then just show the helpful/meaningful bit. Show Sample Output
exported files will get a .r23 extension (where 23 is the revision number)
Lists revisions in a Subversion repository with a timestamp that doesn't follow the revision numbering order. If everything is OK, nothing is displayed.
Manages everything through one sed script instead of pipes of greps and awks. Quoting of shell variables is generally easier within a sed script.
This will diff your local version of the file with the latest version in svn. I put this in a shell function like so:
svd() { vimdiff <(svn cat "$1") "$1"; }
This command dumps all SVN repositories inside of folder "repMainPath" (not recursively) to the folder "dumpPath", where one dump file will be created for each SVN repository.
commandlinefu.com is the place to record those command-line gems that you return to again and again. That way others can gain from your CLI wisdom and you from theirs too. All commands can be commented on, discussed and voted up or down.
Every new command is wrapped in a tweet and posted to Twitter. Following the stream is a great way of staying abreast of the latest commands. For the more discerning, there are Twitter accounts for commands that get a minimum of 3 and 10 votes - that way only the great commands get tweeted.
» http://twitter.com/commandlinefu
» http://twitter.com/commandlinefu3
» http://twitter.com/commandlinefu10
Use your favourite RSS aggregator to stay in touch with the latest commands. There are feeds mirroring the 3 Twitter streams as well as for virtually every other subset (users, tags, functions,…):
Subscribe to the feed for: