This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
#ssum: machine status report | |
UNAME=`uname` | |
if [ 'Linux' == "$UNAME" ] | |
then | |
MACHINE=`hostname` | |
OSVERSION=`cat /etc/issue` | |
IP=`hostname --all-ip-addresses` | |
fi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
""" | |
Scan repos for "behind upstream" status (i.e. you need to catch up). | |
Optionally hints whether a merge would likely be clean (no working tree changes). | |
Usage: | |
./gitcon # scans ~/code | |
./gitcon /path/to/src # scan a different base directory | |
""" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import os | |
import subprocess | |
def find_git_repos_with_unpushed_commits(base_dir): | |
messages = [] | |
for root, dirs, files in os.walk(base_dir): | |
if '.git' in dirs: | |
repo_dir = root | |
try: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#frequent | |
alias c="clear;pwd;echo;ls;echo;" | |
alias e="exit" | |
alias m="more" | |
alias o="open.sh" | |
alias sc="sc2" | |
alias cd-="cd .." | |
alias u="cd .." | |
alias u2="cd ../.." | |
alias u3="cd ../../.." |