git.lirion.de

Of git, get, and gud

aboutsummaryrefslogtreecommitdiffstats
path: root/.gitmodules
blob: f595963d5b22c75bd0c24a4cf40b8c96453401fa (plain)
1
2
3
4
5
6
[submodule "tmux-gpakosz"]
	path = tmux-gpakosz
	url = https://github.com/gpakosz/.tmux
[submodule "tmux-yank"]
	path = tmux-yank
	url = https://github.com/tmux-plugins/tmux-yank
e */ .highlight .c1 { color: #aaaaaa; font-style: italic } /* Comment.Single */ .highlight .cs { color: #0000aa; font-style: italic } /* Comment.Special */ .highlight .gd { color: #aa0000 } /* Generic.Deleted */ .highlight .ge { font-style: italic } /* Generic.Emph */ .highlight .gr { color: #aa0000 } /* Generic.Error */ .highlight .gh { color: #000080; font-weight: bold } /* Generic.Heading */ .highlight .gi { color: #00aa00 } /* Generic.Inserted */ .highlight .go { color: #888888 } /* Generic.Output */ .highlight .gp { color: #555555 } /* Generic.Prompt */ .highlight .gs { font-weight: bold } /* Generic.Strong */ .highlight .gu { color: #800080; font-weight: bold } /* Generic.Subheading */ .highlight .gt { color: #aa0000 } /* Generic.Traceback */ .highlight .kc { color: #0000aa } /* Keyword.Constant */ .highlight .kd { color: #0000aa } /* Keyword.Declaration */ .highlight .kn { color: #0000aa } /* Keyword.Namespace */ .highlight .kp { color: #0000aa } /* Keyword.Pseudo */ .highlight .kr { color: #0000aa } /* Keyword.Reserved */ .highlight .kt { color: #00aaaa } /* Keyword.Type */ .highlight .m { color: #009999 } /* Literal.Number */ .highlight .s { color: #aa5500 } /* Literal.String */ .highlight .na { color: #1e90ff } /* Name.Attribute */ .highlight .nb { color: #00aaaa } /* Name.Builtin */ .highlight .nc { color: #00aa00; text-decoration: underline } /* Name.Class */ .highlight .no { color: #aa0000 } /* Name.Constant */ .highlight .nd { color: #888888 } /* Name.Decorator */ .highlight .ni { color: #880000; font-weight: bold } /* Name.Entity */ .highlight .nf { color: #00aa00 } /* Name.Function */ .highlight .nn { color: #00aaaa; text-decoration: underline } /* Name.Namespace */ .highlight .nt { color: #1e90ff; font-weight: bold } /* Name.Tag */ .highlight .nv { color: #aa0000 } /* Name.Variable */ .highlight .ow { color: #0000aa } /* Operator.Word */ .highlight .w { color: #bbbbbb } /* Text.Whitespace */ .highlight .mb { color: #009999 } /* Literal.Number.Bin */ .highlight .mf { color: #009999 } /* Literal.Number.Float */ .highlight .mh { color: #009999 } /* Literal.Number.Hex */ .highlight .mi { color: #009999 } /* Literal.Number.Integer */ .highlight .mo { color: #009999 } /* Literal.Number.Oct */ .highlight .sa { color: #aa5500 } /* Literal.String.Affix */ .highlight .sb { color: #aa5500 } /* Literal.String.Backtick */ .highlight .sc { color: #aa5500 } /* Literal.String.Char */ .highlight .dl { color: #aa5500 } /* Literal.String.Delimiter */ .highlight .sd { color: #aa5500 } /* Literal.String.Doc */ .highlight .s2 { color: #aa5500 } /* Literal.String.Double */ .highlight .se { color: #aa5500 } /* Literal.String.Escape */ .highlight .sh { color: #aa5500 } /* Literal.String.Heredoc */ .highlight .si { color: #aa5500 } /* Literal.String.Interpol */ .highlight .sx { color: #aa5500 } /* Literal.String.Other */ .highlight .sr { color: #009999 } /* Literal.String.Regex */ .highlight .s1 { color: #aa5500 } /* Literal.String.Single */ .highlight .ss { color: #0000aa } /* Literal.String.Symbol */ .highlight .bp { color: #00aaaa } /* Name.Builtin.Pseudo */ .highlight .fm { color: #00aa00 } /* Name.Function.Magic */ .highlight .vc { color: #aa0000 } /* Name.Variable.Class */ .highlight .vg { color: #aa0000 } /* Name.Variable.Global */ .highlight .vi { color: #aa0000 } /* Name.Variable.Instance */ .highlight .vm { color: #aa0000 } /* Name.Variable.Magic */ .highlight .il { color: #009999 } /* Literal.Number.Integer.Long */
#!/bin/bash

RETVAL=0
declare -x NCURSINST SCDIR GROOTDIR BASHLIST KORNLIST ECMALIST TIDYLIST
command -v tput >/dev/null 2>&1&&NCURSINST=1||NCURSINST=0
SCDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
# I AM G(IT)ROOT!
GROOTDIR="$(git rev-parse --show-toplevel)"||exit 1
BASHLIST="$GROOTDIR/aux/git-checkers/bashlist"
KORNLIST="$GROOTDIR/aux/git-checkers/kornlist"
POSHLIST="$GROOTDIR/aux/git-checkers/poshlist"
ECMALIST="$GROOTDIR/aux/git-checkers/ecmalist"
TIDYLIST="$GROOTDIR/aux/git-checkers/tidylist"
MAKELIST="$GROOTDIR/aux/git-checkers/makelist"

function initmimick {
	[ -z "$1" ]&&echo "crit_fail in initmimick(): no parameter passed" >&2&&exit 1
	[ -z "$2" ]&&echo "crit_fail in initmimick(): no string passed" >&2&&exit 2
        case "$1" in
		0)
			echo -en "\\033[999D";echo -en "\\033[K"
			case "$NCURSINST" in
				1)echo -en "[ $(tput setaf 2)$(tput bold)OK$(tput sgr0) ] $2.";;
				*)echo -en "[ OK ] $2.";;
			esac
			echo " $3"
		;;
		*)
			echo -en "\\033[999D";echo -en "\\033[K"
			case "$NCURSINST" in
				1)echo -en "[ $(tput setaf 1)$(tput bold)FAIL$(tput sgr0) ] $2:";;
				*)echo -en "[ FAIL ] $2:";;
			esac
			echo " $3"
		;;
	esac
}
STAGECMD="Generating Bash code list"
echo -n "[....] $STAGECMD"
if [ "$(find "$GROOTDIR" -type f -exec file '{}' \;|grep Bourne-Again|grep -vE "tmp/|aux/github-markdown"|sed "s|:.*||g;s|$GROOTDIR/||g"|grep -vcP "$(tr '\n' '|' < "$GROOTDIR/.gitignore"|sed 's/|$//g')")" -gt 0 ];then
	if [ -e "$GROOTDIR/.gitignore" ];then
		find "$GROOTDIR" -type f -exec file '{}' \;|grep Bourne-Again|grep -vE "tmp/|aux/github-markdown"|sed "s|:.*||g;s|$GROOTDIR/||g"|grep -vP "$(tr '\n' '|' < "$GROOTDIR/.gitignore"|sed 's/|$//g')" > "$BASHLIST"
	else
		find "$GROOTDIR" -type f -exec file '{}' \;|grep Bourne-Again|grep -vE "tmp/|aux/github-markdown"|sed "s|:.*||g;s|$GROOTDIR/||g"> "$BASHLIST"
	fi
else
	true>"$BASHLIST"
fi
CRETVAL="$?"
case "$CRETVAL" in
	0) initmimick 0 "$STAGECMD" "...$(wc -l "$BASHLIST"|awk '{print $1}') found";;
	*) initmimick 1 "$STAGECMD" "...$(wc -l "$BASHLIST"|awk '{print $1}') found";((++RETVAL));;
esac
STAGECMD="Generating KSH code list"
echo -n "[....] $STAGECMD"
if [ "$(find "$GROOTDIR" -type f -exec file '{}' \;|grep Korn\ shell|grep -vE "/tmp/|aux/github-markdown"|sed "s|:.*||g;s|$GROOTDIR/||g"|grep -vcP "$(tr '\n' '|' < "$GROOTDIR/.gitignore"|sed 's/|$//g')")" -gt 0 ];then
	if [ -e "$GROOTDIR/.gitignore" ];then
		find "$GROOTDIR" -type f -exec file '{}' \;|grep Korn\ shell|grep -vE "/tmp/|aux/github-markdown"|sed "s|:.*||g;s|$GROOTDIR/||g"|grep -vP "$(tr '\n' '|' < "$GROOTDIR/.gitignore"|sed 's/|$//g')" > "$KORNLIST"
	else
		find "$GROOTDIR" -type f -exec file '{}' \;|grep Korn\ shell|grep -vE "/tmp/|aux/github-markdown"|sed "s|:.*||g;s|$GROOTDIR/||g" > "$KORNLIST"
	fi
else
	true>"$KORNLIST"
fi
CRETVAL="$?"
case "$CRETVAL" in
	0) initmimick 0 "$STAGECMD" "...$(wc -l "$KORNLIST"|awk '{print $1}') found";;
	*) initmimick 1 "$STAGECMD" "...$(wc -l "$KORNLIST"|awk '{print $1}') found";((++RETVAL));;
esac
STAGECMD="Generating POSIX shell code list"
echo -n "[....] $STAGECMD"
if [ "$(find "$GROOTDIR" -type f -exec file '{}' \;|grep POSIX\ shell|grep -vE "/tmp/|aux/github-markdown|\.git/"|sed "s|:.*||g;s|$GROOTDIR/||g"|grep -vcP "$(tr '\n' '|' < "$GROOTDIR/.gitignore"|sed 's/|$//g')")" -gt 0 ];then
	if [ -e "$GROOTDIR/.gitignore" ];then
		find "$GROOTDIR" -type f -exec file '{}' \;|grep POSIX\ shell|grep -vE "/tmp/|aux/github-markdown|\.git/"|sed "s|:.*||g;s|$GROOTDIR/||g"|grep -vP "$(tr '\n' '|' < "$GROOTDIR/.gitignore"|sed 's/|$//g')" > "$POSHLIST"
	else
		find "$GROOTDIR" -type f -exec file '{}' \;|grep POSIX\ shell|grep -vE "/tmp/|aux/github-markdown|\.git/"|sed "s|:.*||g;s|$GROOTDIR/||g" > "$POSHLIST"
	fi
else
	true>"$POSHLIST"
fi
CRETVAL="$?"
case "$CRETVAL" in
	0) initmimick 0 "$STAGECMD" "...$(wc -l "$POSHLIST"|awk '{print $1}') found";;
	*) initmimick 1 "$STAGECMD" "...$(wc -l "$POSHLIST"|awk '{print $1}') found";((++RETVAL));;
esac
STAGECMD="Generating ECMA script list"
echo -n "[....] $STAGECMD"
if [ "$(find "$GROOTDIR" -type f -name "*.js"|sed "s|$GROOTDIR/||g"|grep -vcE "/tmp/")" -gt 0 ];then
	find "$GROOTDIR" -type f -name "*.js"|sed "s|$GROOTDIR/||g"|grep -vE "/tmp/" > "$ECMALIST" 2>/dev/null
else
	true>"$ECMALIST"
fi
CRETVAL="$?"
case "$CRETVAL" in
	0) initmimick 0 "$STAGECMD" "...$(wc -l "$ECMALIST"|awk '{print $1}') found";;
	*) initmimick 1 "$STAGECMD" "...$(wc -l "$ECMALIST"|awk '{print $1}') found";((++RETVAL));;
esac
STAGECMD="Generating PHP and HTML code list"
echo -n "[....] $STAGECMD"
if [ "$(find "$GROOTDIR" -type f -exec file '{}' \;|grep -E 'PHP script|HTML document'|sed "s|:.*||g;s|$GROOTDIR/||g"|wc -l)" -gt 0 ];then
	find "$GROOTDIR" -type f -exec file '{}' \;|grep -E 'PHP script|HTML document'|sed "s|:.*||g;s|$GROOTDIR/||g" > "$TIDYLIST" 2>/dev/null
else
	true>"$TIDYLIST"
fi
CRETVAL="$?"
case "$CRETVAL" in
	0) initmimick 0 "$STAGECMD" "...$(wc -l "$TIDYLIST"|awk '{print $1}') found";;
	*) initmimick 1 "$STAGECMD" "...$(wc -l "$TIDYLIST"|awk '{print $1}') found";((++RETVAL));;
esac
STAGECMD="Generating Makefile code list"
echo -n "[....] $STAGECMD"
if [ "$(find "$GROOTDIR" -type f -exec file '{}' \;|grep makefile\ script|sed "s|:.*||g;s|$GROOTDIR/||g"|wc -l)" -gt 0 ];then
	find "$GROOTDIR" -type f -exec file '{}' \;|grep makefile\ script|sed "s|:.*||g;s|$GROOTDIR/||g" > "$MAKELIST"
else
	true>"$MAKELIST"
fi
CRETVAL="$?"
case "$CRETVAL" in
	0) initmimick 0 "$STAGECMD" "...$(wc -l "$MAKELIST"|awk '{print $1}') found";;
	*) initmimick 1 "$STAGECMD" "...$(wc -l "$MAKELIST"|awk '{print $1}') found";((++RETVAL));;
esac
exit $RETVAL