summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Lemon <y@yulqen.org>2024-11-28 21:28:39 +0000
committerMatthew Lemon <y@yulqen.org>2024-11-28 21:28:39 +0000
commit972080ac7344235e75f042e775c250ab95b3a4ac (patch)
treea79568be7ca8b5413a13d88b22a50f98090f164d
parent8bb436815f8f36d8b67c476af75168d678a50879 (diff)
Various things with bashrc
- switch off ls colours - add some ruby stuff - switch off PS1 - other stuff
-rw-r--r--bashrc25
1 files changed, 19 insertions, 6 deletions
diff --git a/bashrc b/bashrc
index 063ccd2..53db8d9 100644
--- a/bashrc
+++ b/bashrc
@@ -12,15 +12,20 @@ case $- in
*) return;;
esac
+# utility functions
+_have() { type "$1" &>/dev/null; }
+_source_if() { [[ -r "$1" ]] && source "$1"; }
+
+_have pandoc && . <(pandoc --bash-completion)
+_source_if ~/.config/todo_completion
+
+
export GDK_SCALE=2
export GDK_DPI_SCALE=0.5
export QT_AUTO_SCREEN_SET_FACTOR=0
export QT_SCALE_FACTOR=2
export QT_FONT_DPI=96
-# secrets
-source ~/secrets
-
# don't put duplicate lines or lines starting with space in the history.
# See bash(1) for more options
HISTCONTROL=ignoreboth
@@ -75,6 +80,9 @@ else
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
fi
unset color_prompt force_color_prompt
+# ignore all that above
+export PS1='$ '
+
# If this is an xterm set the title to user@host:dir
case "$TERM" in
@@ -88,7 +96,7 @@ esac
# enable color support of ls and also add handy aliases
if [ -x /usr/bin/dircolors ]; then
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
- alias ls='ls --color=auto'
+ #alias ls='ls --color=auto'
#alias dir='dir --color=auto'
#alias vdir='vdir --color=auto'
@@ -135,9 +143,10 @@ alias gloga='git log --oneline --decorate --graph --all'
alias batnote='batnote-source-code'
alias am='append_to_masterlist'
alias vi='vim'
-alias ls='ls --color=auto'
+#alias ls='ls --color=auto'
alias h='hey_openai'
alias hd='openai_data'
+alias llatest='ls -ltrc'
alias xclip='xclip -selection c'
alias notes="cd ~/Documents/Notes/"
alias blog="cd ~/code/html/yulqen.org/"
@@ -387,7 +396,7 @@ append_to_masterlist() {
# Colors for ls - yellow directories
# export LS_COLORS="$LS_COLORS:di=1;33"
# Install Ruby Gems to ~/gems
-export GEM_HOME="$HOME/gems"
+#export GEM_HOME="$HOME/gems"
# note() {
@@ -423,3 +432,7 @@ PERL_LOCAL_LIB_ROOT="/home/lemon/perl5${PERL_LOCAL_LIB_ROOT:+:${PERL_LOCAL_LIB_R
PERL_MB_OPT="--install_base \"/home/lemon/perl5\""; export PERL_MB_OPT;
PERL_MM_OPT="INSTALL_BASE=/home/lemon/perl5"; export PERL_MM_OPT;
. "$HOME/.cargo/env"
+eval "$(direnv hook bash)"
+
+# Add RVM to PATH for scripting. Make sure this is the last PATH variable change.
+export PATH="$PATH:$HOME/.rvm/bin"