summaryrefslogtreecommitdiff
path: root/etc
diff options
context:
space:
mode:
Diffstat (limited to 'etc')
-rw-r--r--etc/rc13
1 files changed, 8 insertions, 5 deletions
diff --git a/etc/rc b/etc/rc
index 2031a07..b1dd892 100644
--- a/etc/rc
+++ b/etc/rc
@@ -6,10 +6,13 @@
## https://derf.homelinux.org/~derf/dotfiles/zsh/rc
## see also: https://derf.homelinux.org/~derf/dotfiles/zsh/
-## mostly internal stuff
-uname=$(uname)
-alias 'linux:'='[[ $uname = Linux ]] &&'
-alias 'openbsd:'='[[ $uname = OpenBSD ]] &&'
+## What are we running on?
+system=${$(uname):l}
+alias 'linux:'='[[ $system == linux ]] &&'
+alias 'openbsd:'='[[ $system == openbsd ]] &&'
+if [[ $system == linux ]] {
+ [[ -f /etc/debian_version ]] && distro=debian
+}
## include the actual config
source $ZDIR/options
@@ -44,5 +47,5 @@ unalias 'openbsd:'
unfunction check_com
unfunction xexport
unfunction xsource
-unset uname
+unset system distro
unset ps_fail ps_green ps_info ps_red ps_reset ps_yellow