diff options
| author | EuAndreh <eu@euandre.org> | 2018-08-30 12:25:56 -0300 |
|---|---|---|
| committer | EuAndreh <eu@euandre.org> | 2018-08-30 12:25:56 -0300 |
| commit | 3882ecaee9c088e10c944176c1a781e2603fdbbe (patch) | |
| tree | df95f0ff85f091457341f21c4ff6a848e390a6a8 | |
| parent | Add security course channel. (diff) | |
| download | dotfiles-3882ecaee9c088e10c944176c1a781e2603fdbbe.tar.gz dotfiles-3882ecaee9c088e10c944176c1a781e2603fdbbe.tar.xz | |
Run Linux commands only when in Linux
| -rw-r--r-- | bash/env.sh | 4 | ||||
| -rw-r--r-- | bash/xdg.sh | 8 |
2 files changed, 8 insertions, 4 deletions
diff --git a/bash/env.sh b/bash/env.sh index 9eeab51..64f79c4 100644 --- a/bash/env.sh +++ b/bash/env.sh @@ -67,7 +67,9 @@ isLinux && { # export GUIX_PROFILE="$HOME/.guix-profile/etc/profile" -source "$GUIX_PROFILE" +isLinux && { + source "$GUIX_PROFILE" +} export PATH="$HOME/.guix-profile/bin${PATH:+:}$PATH" export PATH="$HOME/.config/guix/current/bin${PATH:+:}$PATH" export GUIX_LOCPATH="$HOME/.guix-profile/lib/locale" # after running guix package -i glibc-utf8-locales diff --git a/bash/xdg.sh b/bash/xdg.sh index ca8ee57..6b8981a 100644 --- a/bash/xdg.sh +++ b/bash/xdg.sh @@ -1,8 +1,9 @@ #!/usr/bin/env bash -mkdir -p ~/.local/share/applications/ +isLinux && { + mkdir -p ~/.local/share/applications/ -cat << EOF > ~/.local/share/applications/evince-andreh.desktop + cat << EOF > ~/.local/share/applications/evince-andreh.desktop [Desktop Entry] Type=Application Name=evince @@ -12,4 +13,5 @@ Exec=evince Categories=Network;WebBrowserEOF EOF -xdg-mime default evince-andreh.desktop application/pdf + xdg-mime default evince-andreh.desktop application/pdf +} |
