From dda760d9a5bb8181121a8d035ab2be9bffa0bbc9 Mon Sep 17 00:00:00 2001 From: Jan Kratochvil Date: Thu, 19 Dec 2019 15:46:47 +0100 Subject: [PATCH] .bashrc: rpmbuildlocal: +time .bashrc: +gdb: -q .bashrc: ulimitme: --m,--d .bashrc: gitcommit: '.'->'' --- .bashrc | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.bashrc b/.bashrc index 65446b3..0ded121 100644 --- a/.bashrc +++ b/.bashrc @@ -159,11 +159,12 @@ eval ' function vncreadonly { vncviewer -FullColor -Shared -ViewOnly "$@"; } function diff {(unset diff; ( diff -dup "$@"; ); );} $(: MAKEFLAGS= - "make install" does not expect -j and .spec files do not force -j1.) - function rpmbuildlocal { MAKEFLAGS= n rpmbuild --define "_topdir $PWD" --define "_builddir $PWD" --define "_rpmdir $PWD" --define "_sourcedir $PWD" --define "_specdir $PWD" --define "_srcrpmdir $PWD" --define "_build_name_fmt %%{NAME}-%%{VERSION}-%%{RELEASE}.%%{ARCH}.rpm" --with buildisa "$@"; rmdir &>/dev/null BUILDROOT; } + function rpmbuildlocal { time MAKEFLAGS= n rpmbuild --define "_topdir $PWD" --define "_builddir $PWD" --define "_rpmdir $PWD" --define "_sourcedir $PWD" --define "_specdir $PWD" --define "_srcrpmdir $PWD" --define "_build_name_fmt %%{NAME}-%%{VERSION}-%%{RELEASE}.%%{ARCH}.rpm" --with buildisa "$@"; rmdir &>/dev/null BUILDROOT; } function gdbn { gdb -nx --command=~/.gdbinit "$@"; } function hd { od -Ax -tx1; } function wget {(unset wget; ( wget --no-check-certificate "$@"; ); );} function ucwkbd { setxkbmap -layout us,cz -variant ,ucw -option grp:caps_switch; } + function gdb {(unset gdb; ( gdb -q "$@"; ); );} ' unset command_not_found_handle @@ -251,7 +252,7 @@ export GIT_MERGE_AUTOEDIT=no function wclines { awk '{x[$0]++}END{for (i in x) print x[i]"\t"i}'; } # SunOS does not support "-m" export ULIMITME_OPTS="" -for i in "-m 100000" "-d 150000" "-v 200000";do +for i in "-v 2000000";do (ulimit $i 2>/dev/null) && ULIMITME_OPTS="$ULIMITME_OPTS $i" done # Prevent: ulimit: -m 100000 -d 150000 -v 200000: invalid number @@ -385,7 +386,7 @@ function rpmsrclist } function valgrind {(set -e;unset valgrind;s=~/.python.valgrind;rm -f $s;cp -p /usr/share/doc/python-devel-2.*/valgrind-python.supp $s;patch $s <$s.patch;perl -i -e 'undef $/;$_=<>;1 while s/^(?:###)?({\n)(?:###)?( *ADDRESS_IN_RANGE.*\n(?:[^}#].*\n)*)###/$1$2/gm;print;' $s;valgrind --num-callers=50 --suppressions=$s "$@";);} function yumupdate {(ulimit -v unlimited;yum makecache;yum -y --skip-broken update "$@";);} -function gitcommit { git commit -a -m .; } +function gitcommit { git commit -a --allow-empty-message -m '' "$@"; } function gpg {(unset gpg; http_proxy= all_proxy= HTTP_PROXY= ALL_PROXY= gpg "$@"; );} function swap() {( set -ex;local TMPFILE=tmp.$$;[ $# = 2 ] && mv "$1" $TMPFILE && mv "$2" "$1" && mv $TMPFILE "$2" && echo done )} -- 1.8.3.1