mirror of
https://github.com/starr-dusT/dotfiles.git
synced 2025-02-13 08:17:31 -08:00
change from zsh to bash on kestrel
This commit is contained in:
parent
7aff57181a
commit
08a0bddd46
@ -15,26 +15,6 @@
|
||||
url = "https://github.com/wbthomason/packer.nvim.git"
|
||||
refreshPeriod = "168h"
|
||||
|
||||
[".oh-my-zsh"]
|
||||
type = "archive"
|
||||
url = "https://github.com/ohmyzsh/ohmyzsh/archive/master.tar.gz"
|
||||
extact = true
|
||||
stripComponents = 1
|
||||
refreshPeriod = "168h"
|
||||
|
||||
[".oh-my-zsh/custom/themes/dracula"]
|
||||
type = "archive"
|
||||
url = "https://github.com/dracula/zsh/archive/master.zip"
|
||||
exact = true
|
||||
stripComponents = 1
|
||||
refreshPeriod = "168h"
|
||||
include = ["*/dracula.zsh-theme", "*/lib/**"]
|
||||
|
||||
[".oh-my-zsh/custom/plugins/zsh-syntax-highlighting"]
|
||||
type = "git-repo"
|
||||
url = "https://github.com/zsh-users/zsh-syntax-highlighting.git"
|
||||
refreshPeriod = "168h"
|
||||
|
||||
[".config/xmonad/xmonad"]
|
||||
type = "git-repo"
|
||||
url = "https://github.com/xmonad/xmonad"
|
||||
|
35
home/dot_aliases
Normal file
35
home/dot_aliases
Normal file
@ -0,0 +1,35 @@
|
||||
#!/usr/bin/env bash
|
||||
# https://github.com/starr-dusT/dotfiles
|
||||
|
||||
# nixos
|
||||
alias nixos-update="cd ~/.local/share/chezmoi/provision/nixos && \
|
||||
sudo nixos-rebuild switch --flake .#$(hostname) && \
|
||||
cd -"
|
||||
# sway
|
||||
alias s='sway'
|
||||
|
||||
# tmuxinator
|
||||
alias tsplat='tmuxinator start splat'
|
||||
alias tdot='tmuxinator start dot'
|
||||
alias ttask='tmuxinator start task'
|
||||
|
||||
# chezmoi
|
||||
alias cc="cd ~/.local/share/chezmoi"
|
||||
alias cdr="chezmoi apply --verbose --dry-run"
|
||||
alias ca="chezmoi apply"
|
||||
alias ce='chezmoi edit'
|
||||
|
||||
# trashcli
|
||||
alias rm='echo "This is not the command you are looking for."; false'
|
||||
alias tp='trash-put'
|
||||
alias te='trash-empty'
|
||||
alias tl='trash-list'
|
||||
alias tre='trash-restore'
|
||||
alias trm='trash-rm'
|
||||
alias rofi='wayland-rofi'
|
||||
|
||||
# zk
|
||||
alias cz="cd ~/documents/zet"
|
||||
|
||||
# nnn
|
||||
alias n="nnn -e"
|
@ -1,15 +1,32 @@
|
||||
##⠀⠀⠀⠀⠀⠀⠀⠀⢠⡆⠀⠀⠀⠀⠀⠀⠀⠀⠀
|
||||
#⠀⠀⠀⠀⠀⠀⠀⠀⠀⣿⣿⡀⠀⠀⠀⠀⠀⠀⠀⠀
|
||||
#⠀⠀⠀⠀⠀⠀⠀⠀⣼⡏⠸⣧⠀⠀⠀⠀⠀⠀⠀⠀
|
||||
#⠠⢤⣤⣤⣤⣤⣤⣴⡿⠀⠀⢻⣦⣤⣤⣤⣤⣤⡤⠄ Tyler Starr (starr-dusT)
|
||||
#⠀⠀⠙⠻⣦⣄⠀⠀⠀⠀⠀⠀⠀⠀⣠⣴⠟⠋⠀⠀ https://github.com/starr-dusT/dotfiles
|
||||
#⠀⠀⠀⠀⠀⠙⣿⡆⠀⠀⠀⠀⠰⣿⠋⠀⠀⠀⠀⠀ https://tstarr.us
|
||||
#⠀⠀⠀⠀⠀⢰⡟⠀⣀⣴⣦⣀⠀⢻⡆⠀⠀⠀⠀⠀
|
||||
#⠀⠀⠀⠀⢀⣾⣧⡾⠛⠁⠈⠙⠷⣼⣿⡀⠀⠀⠀⠀
|
||||
# ⠀⠀⠀⡸⠟⠁⠀⠀⠀⠀⠀⠀⠈⠛⢧⠀⠀⠀⠀
|
||||
#
|
||||
# ~/.bash_profile
|
||||
# https://github.com/starr-dusT/dotfiles
|
||||
|
||||
# Get the aliases and functions
|
||||
[ -f $HOME/.bashrc ] && . $HOME/.bashrc
|
||||
export PS1="\u@\h \w> "
|
||||
# Load the shell dotfiles (that are available)
|
||||
for file in ~/.{path,bash_prompt,exports,aliases,functions,extra}; do
|
||||
[ -r "$file" ] && [ -f "$file" ] && source "$file";
|
||||
done;
|
||||
unset file;
|
||||
|
||||
# Case-insensitive globbing (used in pathname expansion)
|
||||
shopt -s nocaseglob;
|
||||
|
||||
# Append to the Bash history file, rather than overwriting it
|
||||
shopt -s histappend;
|
||||
|
||||
# Autocorrect typos in path names when using `cd`
|
||||
shopt -s cdspell;
|
||||
|
||||
# Enable some Bash 4 features when possible:
|
||||
# * `autocd`, e.g. `**/qux` will enter `./foo/bar/baz/qux`
|
||||
# * Recursive globbing, e.g. `echo **/*.txt`
|
||||
for option in autocd globstar; do
|
||||
shopt -s "$option" 2> /dev/null;
|
||||
done;
|
||||
|
||||
if [ -f /etc/bash_completion ]; then
|
||||
source /etc/bash_completion;
|
||||
fi;
|
||||
|
||||
# Enable tab completion for `g` by marking it as an alias for `git`
|
||||
if type _git &> /dev/null; then
|
||||
complete -o default -o nospace -F _git g;
|
||||
fi;
|
||||
|
108
home/dot_bash_prompt
Normal file
108
home/dot_bash_prompt
Normal file
@ -0,0 +1,108 @@
|
||||
#!/usr/bin/env bash
|
||||
# https://github.com/starr-dusT/dotfiles
|
||||
|
||||
prompt_git() {
|
||||
local s='';
|
||||
local branchName='';
|
||||
|
||||
# Check if the current directory is in a Git repository.
|
||||
git rev-parse --is-inside-work-tree &>/dev/null || return;
|
||||
|
||||
# Check for what branch we’re on.
|
||||
# Get the short symbolic ref. If HEAD isn’t a symbolic ref, get a
|
||||
# tracking remote branch or tag. Otherwise, get the
|
||||
# short SHA for the latest commit, or give up.
|
||||
branchName="$(git symbolic-ref --quiet --short HEAD 2> /dev/null || \
|
||||
git describe --all --exact-match HEAD 2> /dev/null || \
|
||||
git rev-parse --short HEAD 2> /dev/null || \
|
||||
echo '(unknown)')";
|
||||
|
||||
# Early exit for Chromium & Blink repo, as the dirty check takes too long.
|
||||
# Thanks, @paulirish!
|
||||
# https://github.com/paulirish/dotfiles/blob/dd33151f/.bash_prompt#L110-L123
|
||||
repoUrl="$(git config --get remote.origin.url)";
|
||||
if grep -q 'chromium/src.git' <<< "${repoUrl}"; then
|
||||
s+='*';
|
||||
else
|
||||
# Check for uncommitted changes in the index.
|
||||
if ! $(git diff --quiet --ignore-submodules --cached); then
|
||||
s+='+';
|
||||
fi;
|
||||
# Check for unstaged changes.
|
||||
if ! $(git diff-files --quiet --ignore-submodules --); then
|
||||
s+='!';
|
||||
fi;
|
||||
# Check for untracked files.
|
||||
if [ -n "$(git ls-files --others --exclude-standard)" ]; then
|
||||
s+='?';
|
||||
fi;
|
||||
# Check for stashed files.
|
||||
if $(git rev-parse --verify refs/stash &>/dev/null); then
|
||||
s+='$';
|
||||
fi;
|
||||
fi;
|
||||
|
||||
[ -n "${s}" ] && s=" [${s}]";
|
||||
|
||||
echo -e "${1}${branchName}${2}${s}";
|
||||
}
|
||||
|
||||
if tput setaf 1 &> /dev/null; then
|
||||
tput sgr0; # reset colors
|
||||
bold=$(tput bold);
|
||||
reset=$(tput sgr0);
|
||||
# Solarized colors, taken from http://git.io/solarized-colors.
|
||||
black=$(tput setaf 0);
|
||||
blue=$(tput setaf 33);
|
||||
cyan=$(tput setaf 37);
|
||||
green=$(tput setaf 64);
|
||||
orange=$(tput setaf 166);
|
||||
purple=$(tput setaf 125);
|
||||
red=$(tput setaf 124);
|
||||
violet=$(tput setaf 61);
|
||||
white=$(tput setaf 15);
|
||||
yellow=$(tput setaf 136);
|
||||
else
|
||||
bold='';
|
||||
reset="\e[0m";
|
||||
black="\e[1;30m";
|
||||
blue="\e[1;34m";
|
||||
cyan="\e[1;36m";
|
||||
green="\e[1;32m";
|
||||
orange="\e[1;33m";
|
||||
purple="\e[1;35m";
|
||||
red="\e[1;31m";
|
||||
violet="\e[1;35m";
|
||||
white="\e[1;37m";
|
||||
yellow="\e[1;33m";
|
||||
fi;
|
||||
|
||||
# Highlight the user name when logged in as root.
|
||||
if [[ "${USER}" == "root" ]]; then
|
||||
userStyle="${red}";
|
||||
else
|
||||
userStyle="${orange}";
|
||||
fi;
|
||||
|
||||
# Highlight the hostname when connected via SSH.
|
||||
if [[ "${SSH_TTY}" ]]; then
|
||||
hostStyle="${bold}${red}";
|
||||
else
|
||||
hostStyle="${yellow}";
|
||||
fi;
|
||||
|
||||
# Set the terminal title and prompt.
|
||||
PS1="\[\033]0;\W\007\]"; # working directory base name
|
||||
PS1+="\[${bold}\]\n"; # newline
|
||||
PS1+="\[${userStyle}\]\u"; # username
|
||||
PS1+="\[${white}\] at ";
|
||||
PS1+="\[${hostStyle}\]\h"; # host
|
||||
PS1+="\[${white}\] in ";
|
||||
PS1+="\[${green}\]\w"; # working directory full path
|
||||
PS1+="\$(prompt_git \"\[${white}\] on \[${violet}\]\" \"\[${blue}\]\")"; # Git repository details
|
||||
PS1+="\n";
|
||||
PS1+="\[${white}\]\$ \[${reset}\]"; # `$` (and reset color)
|
||||
export PS1;
|
||||
|
||||
PS2="\[${yellow}\]→ \[${reset}\]";
|
||||
export PS2;
|
@ -1,43 +1,3 @@
|
||||
##⠀⠀⠀⠀⠀⠀⠀⠀⢠⡆⠀⠀⠀⠀⠀⠀⠀⠀⠀
|
||||
#⠀⠀⠀⠀⠀⠀⠀⠀⠀⣿⣿⡀⠀⠀⠀⠀⠀⠀⠀⠀
|
||||
#⠀⠀⠀⠀⠀⠀⠀⠀⣼⡏⠸⣧⠀⠀⠀⠀⠀⠀⠀⠀
|
||||
#⠠⢤⣤⣤⣤⣤⣤⣴⡿⠀⠀⢻⣦⣤⣤⣤⣤⣤⡤⠄ Tyler Starr (starr-dusT)
|
||||
#⠀⠀⠙⠻⣦⣄⠀⠀⠀⠀⠀⠀⠀⠀⣠⣴⠟⠋⠀⠀ https://github.com/starr-dusT/dotfiles
|
||||
#⠀⠀⠀⠀⠀⠙⣿⡆⠀⠀⠀⠀⠰⣿⠋⠀⠀⠀⠀⠀ https://tstarr.us
|
||||
#⠀⠀⠀⠀⠀⢰⡟⠀⣀⣴⣦⣀⠀⢻⡆⠀⠀⠀⠀⠀
|
||||
#⠀⠀⠀⠀⢀⣾⣧⡾⠛⠁⠈⠙⠷⣼⣿⡀⠀⠀⠀⠀
|
||||
# ⠀⠀⠀⡸⠟⠁⠀⠀⠀⠀⠀⠀⠈⠛⢧⠀⠀⠀⠀
|
||||
#
|
||||
# Bash config.
|
||||
|
||||
# Source global definitions
|
||||
if [ -f /etc/bashrc ]; then
|
||||
. /etc/bashrc
|
||||
fi
|
||||
|
||||
export LC_COLLATE="C"
|
||||
|
||||
# User specific environment
|
||||
if ! [[ "$PATH" =~ "$HOME/.local/bin:$HOME/bin:" ]]
|
||||
then
|
||||
PATH="$HOME/.local/bin:$HOME/bin:$PATH"
|
||||
fi
|
||||
export PATH
|
||||
|
||||
export EDITOR="/usr/bin/nvim"
|
||||
|
||||
export NVM_DIR="$HOME/.nvm"
|
||||
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
|
||||
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
|
||||
|
||||
export PATH="$HOME/.nimble/bin:$PATH"
|
||||
|
||||
alias spl="tmux_splat"
|
||||
alias n="nnn -d -e -H -r"
|
||||
alias s="startx"
|
||||
|
||||
# Chezmoi
|
||||
alias cmc="chezmoi cd"
|
||||
alias cmd="chezmoi apply --verbose --dry-run"
|
||||
alias cma="chezmoi apply"
|
||||
# https://github.com/starr-dusT/dotfiles
|
||||
|
||||
[ -n "$PS1" ] && source ~/.bash_profile;
|
||||
|
14
home/dot_export
Normal file
14
home/dot_export
Normal file
@ -0,0 +1,14 @@
|
||||
#!/usr/bin/env bash
|
||||
# https://github.com/starr-dusT/dotfiles
|
||||
|
||||
# Make vim the default editor.
|
||||
export EDITOR=nvim
|
||||
|
||||
# Customize prompt
|
||||
export PROMPT="%{$fg[red]%}%m $PROMPT"
|
||||
|
||||
# NNN exports
|
||||
export NNN_FCOLORS='0000E6310000000000000000'
|
||||
export NNN_PLUG='g:getdrop'
|
||||
export NNN_FIFO="/tmp/nnn.fifo"
|
||||
export NNN_TRASH=1
|
@ -1,7 +0,0 @@
|
||||
[Desktop Entry]
|
||||
Encoding=UTF-8
|
||||
Type=Application
|
||||
Terminal=false
|
||||
Exec=/home/{{ .user }}/.local/bin/SuperSlicer
|
||||
Name=SuperSlicer
|
||||
Icon=/home/{{ .user }}/.local/share/icons/SuperSlicer.png
|
@ -1,7 +0,0 @@
|
||||
[Desktop Entry]
|
||||
Encoding=UTF-8
|
||||
Type=Application
|
||||
Terminal=false
|
||||
Exec=/home/{{ .user }}/.local/bin/Yuzu
|
||||
Name=Yuzu
|
||||
Icon=/home/{{ .user }}/.local/share/icons/Yuzu.png
|
Binary file not shown.
Before Width: | Height: | Size: 228 KiB |
Binary file not shown.
Before Width: | Height: | Size: 3.2 KiB |
18
home/dot_path
Normal file
18
home/dot_path
Normal file
@ -0,0 +1,18 @@
|
||||
#!/usr/bin/env bash
|
||||
# https://github.com/starr-dusT/dotfiles
|
||||
|
||||
# Add `~/bin` to the `$PATH`
|
||||
export PATH="$HOME/bin:$PATH";
|
||||
|
||||
if ! [[ "$PATH" =~ "$HOME/.local/bin:$HOME/bin:" ]]; then
|
||||
PATH="$HOME/.local/bin:$HOME/bin:$PATH";
|
||||
fi
|
||||
|
||||
if ! [[ "$PATH" =~ "$HOME/.nimble/bin:" ]]; then
|
||||
PATH="$HOME/.nimble/bin:$PATH";
|
||||
fi
|
||||
|
||||
if ! [[ "$PATH" =~ "$HOME/.cargo/bin:" ]]; then
|
||||
PATH="$HOME/.cargo/bin:$PATH" ;
|
||||
fi
|
||||
export PATH
|
@ -1,3 +0,0 @@
|
||||
exec dbus-launch xmonad
|
||||
#exec dbus-launch i3
|
||||
#exec dbus-launch qtile
|
@ -1,78 +0,0 @@
|
||||
##⠀⠀⠀⠀⠀⠀⠀⠀⢠⡆⠀⠀⠀⠀⠀⠀⠀⠀⠀
|
||||
#⠀⠀⠀⠀⠀⠀⠀⠀⠀⣿⣿⡀⠀⠀⠀⠀⠀⠀⠀⠀
|
||||
#⠀⠀⠀⠀⠀⠀⠀⠀⣼⡏⠸⣧⠀⠀⠀⠀⠀⠀⠀⠀
|
||||
#⠠⢤⣤⣤⣤⣤⣤⣴⡿⠀⠀⢻⣦⣤⣤⣤⣤⣤⡤⠄ Tyler Starr (starr-dusT)
|
||||
#⠀⠀⠙⠻⣦⣄⠀⠀⠀⠀⠀⠀⠀⠀⣠⣴⠟⠋⠀⠀ https://github.com/starr-dusT/dotfiles
|
||||
#⠀⠀⠀⠀⠀⠙⣿⡆⠀⠀⠀⠀⠰⣿⠋⠀⠀⠀⠀⠀ https://tstarr.us
|
||||
#⠀⠀⠀⠀⠀⢰⡟⠀⣀⣴⣦⣀⠀⢻⡆⠀⠀⠀⠀⠀
|
||||
#⠀⠀⠀⠀⢀⣾⣧⡾⠛⠁⠈⠙⠷⣼⣿⡀⠀⠀⠀⠀
|
||||
# ⠀⠀⠀⡸⠟⠁⠀⠀⠀⠀⠀⠀⠈⠛⢧⠀⠀⠀⠀
|
||||
#
|
||||
# Zsh config.
|
||||
|
||||
# Zsh specific config
|
||||
export ZSH="$HOME/.oh-my-zsh"
|
||||
|
||||
DISABLE_AUTO_UPDATE="true"
|
||||
plugins=(git zsh-syntax-highlighting fzf-dir-navigator)
|
||||
ZSH_THEME="dracula/dracula"
|
||||
|
||||
source $ZSH/oh-my-zsh.sh
|
||||
|
||||
# Export PATHs
|
||||
export EDITOR=nvim
|
||||
|
||||
if ! [[ "$PATH" =~ "$HOME/.local/bin:$HOME/bin:" ]]; then PATH="$HOME/.local/bin:$HOME/bin:$PATH"; fi
|
||||
if ! [[ "$PATH" =~ "$HOME/.nimble/bin:" ]]; then PATH="$HOME/.nimble/bin:$PATH"; fi
|
||||
if ! [[ "$PATH" =~ "$HOME/.cargo/bin:" ]]; then PATH="$HOME/.cargo/bin:$PATH" ; fi
|
||||
|
||||
export PATH
|
||||
export PROMPT="%{$fg[red]%}%m $PROMPT"
|
||||
|
||||
# Create Aliases
|
||||
|
||||
# Nixos
|
||||
alias nixos-update="cd ~/.local/share/chezmoi/provision/nixos && \
|
||||
sudo nixos-rebuild switch --flake .#$(hostname) && \
|
||||
cd -"
|
||||
|
||||
# Sway
|
||||
alias s='sway'
|
||||
|
||||
# tmuxinator
|
||||
alias tsplat='tmuxinator start splat'
|
||||
alias tdot='tmuxinator start dot'
|
||||
alias ttask='tmuxinator start task'
|
||||
|
||||
# Chezmoi
|
||||
alias cc="cd ~/.local/share/chezmoi"
|
||||
alias cdr="chezmoi apply --verbose --dry-run"
|
||||
alias ca="chezmoi apply"
|
||||
alias ce='chezmoi edit'
|
||||
|
||||
# trashcli
|
||||
alias rm='echo "This is not the command you are looking for."; false'
|
||||
alias tp='trash-put'
|
||||
alias te='trash-empty'
|
||||
alias tl='trash-list'
|
||||
alias tre='trash-restore'
|
||||
alias trm='trash-rm'
|
||||
alias rofi='wayland-rofi'
|
||||
|
||||
# Fedora
|
||||
alias update-grub='sudo grub2-mkconfig -o /boot/efi/EFI/fedora/grub.cfg'
|
||||
|
||||
# Void
|
||||
alias xi="sudo xbps-install"
|
||||
alias xr="sudo xbps-remove"
|
||||
alias xl="void-list-packages"
|
||||
|
||||
# nnn
|
||||
alias n="nnn -e"
|
||||
export NNN_FCOLORS='0000E6310000000000000000'
|
||||
export NNN_PLUG='g:getdrop'
|
||||
export NNN_FIFO="/tmp/nnn.fifo"
|
||||
export NNN_TRASH=1
|
||||
|
||||
# zk
|
||||
alias cz="cd ~/documents/zet"
|
Loading…
x
Reference in New Issue
Block a user