summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.zsh/zshfunctions19
-rw-r--r--.zsh/zshrc2
-rw-r--r--.zshenv3
3 files changed, 23 insertions, 1 deletions
diff --git a/.zsh/zshfunctions b/.zsh/zshfunctions
index ad50ea1..823a65b 100644
--- a/.zsh/zshfunctions
+++ b/.zsh/zshfunctions
@@ -82,3 +82,22 @@ emerge()
command emerge $@
fi
}
+
+# keyword a specific package using flaggie
+# relies on the $_kw variable set in .zshenv
+kw()
+{
+ if [[ -z $1 ]]; then
+ echo "Error: Need the package"
+ return 1
+ fi
+
+ if whence flaggie NOE; then
+ # use 'flaggie'
+ flaggie $1 "+$_kw"
+ else
+ echo "Error: flaggie not installed"
+ echo "Do it yourself!"
+ return 1
+ fi
+}
diff --git a/.zsh/zshrc b/.zsh/zshrc
index 14627d4..c01414a 100644
--- a/.zsh/zshrc
+++ b/.zsh/zshrc
@@ -31,7 +31,7 @@ alias la='ls -a'
alias man='LANG= man'
# emerge stuff
-alias AK='ACCEPT_KEYWORDS="~amd64"'
+alias AK=ACCEPT_KEYWORDS="$_kw" # _kw should be set in .zshenv
alias NS='FEATURES="nostrip" CFLAGS="-O0 -ggdb -pipe -march=native" CXXFLAGS="${CFLAGS}"'
alias e="eix -e"
alias i="eix -I"
diff --git a/.zshenv b/.zshenv
index 21c7a8c..f38c243 100644
--- a/.zshenv
+++ b/.zshenv
@@ -7,6 +7,9 @@ autoload ${fpath[1]}/*(:t)
[[ -d ~/bin ]] && path=(~/bin $path)
+# other variables
+_kw="~amd64"
+
# exports
export ECHANGELOG_USER="René Neumann (Necoro) <gentoo@necoro.eu>"
export EDITOR=vim