Search working tree for text matching regular expression regexp:
git grep regexp
Search working tree for lines of text matching regexp A or B:
git grep -e A --or -e B
Git default configuration is good but it can be personalized to improve your workflow efficiency.
Here are some good lines to put in your ~/.gitconfig
:
# The basics, who you commit as:
[user]
name = John Doe
email = [email protected]
Often you are handed-out big CSV files and need to sort, filter, update some cells or other tedious work.
You tried sed
, jq
, and maybe the mighty awk
.
But at the end of the day: You’re using the wrong tool for the job.
Here come csvkit’s csvsql, a small Python script to parse your CSV files and create the corresponding database. You now have the best tool, SQL, to answer your data questions:
#!/bin/bash | |
# | |
# When you are working on your macbook sitting in cafe and you have to go pee, | |
# you need some way to guard you machine. | |
# | |
# Start this script, remove any earphones, and go do the job. | |
# The assumption is the thief will close the lid of the laptop before taking it away. | |
# This script detects the closing of the lid and plays some loud audio that will | |
# likely distract the thief and/or grab attention of nearby people, making the |
Contributed by Fabien Loudet, Linux SysAdmin at Rosetta Stone
The format to use for each line in the file:
hostname:port:database:username:password
Only the owner of the file should have read and write access to it: