Skip to content

Commit

Permalink
Merge branch 'master' of github.com:dther/dotfiles
Browse files Browse the repository at this point in the history
  • Loading branch information
dther committed Nov 25, 2021
2 parents cbc3b98 + d2fbe3e commit 7fdd200
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 8 deletions.
12 changes: 11 additions & 1 deletion .profile
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ export XDG_CACHE_HOME="$HOME/.cache"
#export XINITRC="${XDG_CONFIG_HOME:-$HOME/.config}/x11/xinitrc"
#export XAUTHORITY="$XDG_RUNTIME_DIR/Xauthority" # This line will break some DMs.
export NOTMUCH_CONFIG="${XDG_CONFIG_HOME:-$HOME/.config}/notmuch-config"
export GTK2_RC_FILES="${XDG_CONFIG_HOME:-$HOME/.config}/gtk-2.0/gtkrc-2.0"
#export GTK2_RC_FILES="${XDG_CONFIG_HOME:-$HOME/.config}/gtk-2.0/gtkrc-2.0"
export LESSHISTFILE="-"
export WGETRC="${XDG_CONFIG_HOME:-$HOME/.config}/wget/wgetrc"
export INPUTRC="${XDG_CONFIG_HOME:-$HOME/.config}/shell/inputrc"
Expand All @@ -51,5 +51,15 @@ export NETHACKOPTIONS="@${XDG_CONFIG_HOME:-$HOME/.config}/nethackrc"
# Java bein broke
export AWT_TOOLKIT=MToolkit

## eye candy
# XXX: Requires Flat Color GTK theme. It's on the AUR somewhere.
export GTK2_RC_FILES="/usr/share/themes/FlatColors/gtk-2.0/gtkrc"
export GTK_THEME="FlatColor:dark"

# makes Qt look like Gtk2 themes
# XXX: Requires 'qt5-styleplugins' from the AUR
export QT_QPA_PLATFORMTHEME="gtk2"
export QT_STYLE_OVERRIDE="gtk2"

# source bashrc?? I use yash now so i'll need to make changes. TODO
[ "$SHELL" = "/bin/bash" ] && . ~/.bashrc
7 changes: 4 additions & 3 deletions .yashrc
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,15 @@ export VISUAL='vim'
export EDITOR=$VISUAL
export _JAVA_AWT_WM_NONREPARENTING=1
export XDG_CONFIG_HOME="$HOME/.config/"
export QT_QPA_PLATFORMTHEME="gtk2"
export QT_STYLE_OVERRIDE="gtk2"
export GTK_THEME="FlatColor:dark"
export INPUTRC='~/.inputrc'
export ELVISBG="dark"
export CHROME_EXECUTABLE='brave'
export TASHK_DIR="$HOME/docs/todo/"

export QT_QPA_PLATFORMTHEME="gtk2"
export QT_STYLE_OVERRIDE="gtk2"
export GTK_THEME="FlatColor:dark"

# Home clean up.
# TODO: MOVE THIS TO ANOTHER FILE. IN $XDG_CONFIG_HOME, IDEALLY.
alias cataclysm="cataclysm --configdir $XDG_CONFIG_HOME/.config/cataclysm-dda"
Expand Down
26 changes: 22 additions & 4 deletions bin/import-dotfiles.sh
Original file line number Diff line number Diff line change
@@ -1,14 +1,32 @@
#!/bin/sh

# Initialise home directory the way I like it.
# Installs configuration and creates the necessary XDG directories
# (e.g. Pictures, Documents, but named the way I like them)

git clone --bare [email protected]:dther/dotfiles.git "$HOME/.myconf"
alias config='/usr/bin/git --git-dir=$HOME/.myconf/ --work-tree=$HOME'
config config status.showUntrackedFiles no

if config checkout; then
printf "%s\n" "Dotfiles installed successfully."
printf "%s\n%s\n" "Dotfiles installed successfully." \
"Making XDG directories..."
while read -r dir; do
dir=${dir%%#*}
[ -z "$dir" ] && continue
dir=${dir#*\"}
dir=${dir%%\"*}
# simulate xdg-user-dir's "shell expansion" (it doesn't really)
dir=$(printf "%s" "$dir" | sed "s|\$HOME|$HOME|g")
printf "Making %s...\n" "$dir"
mkdir "$dir"
done < "$HOME/.config/user-dirs.dirs"
printf "%s\n" \
"That should have been mostly painless.
Run 'xdg-user-dirs-update' to finish up.
(This allows userspace programs to know where your folders are...)"
exit 0
fi;

printf "Failed to install dotfiles! Please check/backup the following files:\n"
config checkout
printf "and try again.\n"
printf "Failed to install dotfiles! Please check/backup your files and try again."
exit 1

0 comments on commit 7fdd200

Please sign in to comment.