Added a few git and osx utility methods #196

Merged
merged 2 commits into from Apr 24, 2013

Projects

None yet

3 participants

@markrickert

OSX:
.DS_Store cleaner (recursive)
See who's connected to your itunes library
Flush dns cache.

GIT:
statistics
history prettyfier
seeing what changed in each commit easily.

markrickert added some commits Apr 9, 2013
@markrickert markrickert Added OSX utility shortcuts
.DS_Store cleaner (recursive)
See who's connected to your itunes library
Flush dns cache.
0cfec65
@markrickert markrickert Added some awesome git aliases for statistics, history, and seeing wh…
…at changed.
8be156f
@tswicegood tswicegood commented on the diff Apr 24, 2013
aliases/available/osx.aliases.bash
@@ -23,3 +23,12 @@ fi
# Requires growlnotify, which can be found in the Growl DMG under "Extras"
alias grnot='growlnotify -s -t Terminal -m "Done"'
+
+# Get rid of those pesky .DS_Store files recursively
+alias dsclean='find . -type f -name .DS_Store -print0 | xargs -0 rm'
@tswicegood
tswicegood Apr 24, 2013

What about using find . -type -f -name .DS_Store -delete instead of piping to xargs?

@seefood
seefood Apr 24, 2013

I am not sure, but I seem to remember GNU's find has -delete while others may not. it's either an attempt to be careful and portable or just someone coming from a non-GNU background, unaware of the feature. doesn't hurt.

@markrickert
markrickert Apr 24, 2013

Unaware of the feature 😄. I can update the pull request to have that line be find . -type -f -name .DS_Store -delete

@markrickert
markrickert Apr 24, 2013

Or not, lol. Either way, it still works.

@tswicegood
tswicegood Apr 24, 2013

@markrickert no need -- it's a to-may-to : to-mah-to type of thing. That said, if ya wanna update it now that it's in master and submit a PR to simplify, that works too. :-)

@markrickert
markrickert Apr 24, 2013

Maybe if I cared a little more, i'd do that...lol... but it's good the way it is. 👍

@tswicegood
Bash-it member

This looks good, just curious if there's a reason not to use -delete.

@tswicegood tswicegood merged commit 8be156f into Bash-it:master Apr 24, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment