summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--.zsh/zshfunctions9
1 files changed, 6 insertions, 3 deletions
diff --git a/.zsh/zshfunctions b/.zsh/zshfunctions
index d0a5a64..317dd96 100644
--- a/.zsh/zshfunctions
+++ b/.zsh/zshfunctions
@@ -66,6 +66,8 @@ open_ebuild ()
# Works only for simple cases
cci ()
{
+ trap 'unfunction ask' EXIT
+
ask ()
{
echo -n "Is this ok? [y/n] "
@@ -165,6 +167,8 @@ menc()
# based on a script by mv
list_cc_flags()
{
+ trap 'unfunction Usage' EXIT
+
Usage ()
{
printf '%s\n' "Usage: ${0##*/} c|o [gcc-Flags e.g. -march=native -O2]
@@ -189,10 +193,9 @@ PROG
# set job count to 1 if there is only one package to install
emerge()
{
- local e=$(whence -p emerge)
if [[ $# < 3 ]]; then
- $e --jobs=1 $@
+ command emerge --jobs=1 $@
else
- $e $@
+ command emerge $@
fi
}