Skip to content

Commit

Permalink
Remove hostname from bash config
Browse files Browse the repository at this point in the history
  • Loading branch information
t-wissmann committed Oct 30, 2024
1 parent fe6e133 commit d8977ca
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 7 deletions.
3 changes: 3 additions & 0 deletions Xdefaults.d/custom.xga
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@

*.background: #1d1d1d
*.foreground: #fefefe
2 changes: 1 addition & 1 deletion bash.d/aliases
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ alias q3='quake3 +set r_fullscreen 1 +set r_customheight "1024" +setr_customwidt
[ -f ~/.reminders.d/functions.sh ] && source ~/.reminders.d/functions.sh

alias synclient="setxkbmap us; xmodmap ~/.xmodmaprc ; synergyc -f towi04 ; setxkbmap de nodeadkeys ; xmodmap ~/.xmodmaprc"
alias synserver="synergys -a `hostname` -f"
#alias synserver="synergys -a `hostname` -f"
alias dropbox='git'
complete -o bashdefault -o default -o nospace -F _git dropbox 2>/dev/null \
|| complete -o default -o nospace -F _git dropbox
Expand Down
8 changes: 4 additions & 4 deletions bash.d/functions
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ function mkcd()

function unison-sync-all(){
local PROFILES=( uni scripts dev internet privat )
[ `hostname` != morgentau ] && local PROFILES=( ${PROFILES[@]} musik )
[ `hostname` != ameise ] && local PROFILES=( ${PROFILES[@]} biz themes )
[ "$HOSTNAME" != morgentau ] && local PROFILES=( ${PROFILES[@]} musik )
[ "$HOSTNAME" != ameise ] && local PROFILES=( ${PROFILES[@]} biz themes )
# do normal thins first -> batch
# do critical thins interactive -> -auto
for mode in batch auto ; do
Expand Down Expand Up @@ -732,8 +732,8 @@ function timediff() {
local remote=${1:-cip}
local format="%-10s: %s\\n"
printf "$format" HOSTNAME DATE
echo "printf \"$format\" \$(hostname) \$(date +%s)" | ssh $remote bash
echo "printf \"$format\" \$(hostname) \$(date +%s)" | bash
echo "printf \"$format\" \${HOSTNAME} \$(date +%s)" | ssh $remote bash
echo "printf \"$format\" \${HOSTNAME} \$(date +%s)" | bash
}

function get_git_clone_url() {
Expand Down
4 changes: 2 additions & 2 deletions bashrc
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ trysource ~/.bash.d/functions
trysource ~/.bash_private

#load some settings
if [ -f "$HOME/.bash.d/settings.$(hostname)" ] ; then
trysource "$HOME/.bash.d/settings.$(hostname)"
if [ -f "$HOME/.bash.d/settings.${HOSTNAME}" ] ; then
trysource "$HOME/.bash.d/settings.${HOSTNAME}"
else
trysource ~/.bash.d/settings
fi
Expand Down

0 comments on commit d8977ca

Please sign in to comment.