all repos — dotfiles @ a70f31f437a7fe3899869d4fd0fb48778b27e603

personal dotfiles

.bashrc (view raw)

 1#
 2# ~/.bashrc
 3#
 4
 5# If not running interactively, don't do anything
 6[[ $- != *i* ]] && return
 7
 8# aliases
 9alias ls='ls --color=auto --group-directories-first'
10alias ll='ls -lAh'
11alias cat='bat -p'
12alias ssh='TERM=rxvt ssh'
13alias config='/usr/bin/git --git-dir=$HOME/dotfiles --work-tree=$HOME'
14alias brc='nvim ~/.bashrc && source ~/.bashrc'
15alias vrc='nvim ~/.config/nvim/init.vim && source ~/.config/nvim/init.vim'
16alias v='nvim'
17
18PS1='[\u@\h \W]\$ '
19
20# use gpg authentication key for ssh auth
21export SSH_AUTH_SOCK=$( gpgconf --list-dirs agent-ssh-socket )
22gpgconf --launch gpg-agent
23
24# fzf bindings and tweaks
25source /usr/share/fzf/key-bindings.bash
26source /usr/share/fzf/completion.bash
27export FZF_DEFAULT_COMMAND='fd --type f --hidden --follow --exclude .git'
28export FZF_CTRL_T_COMMAND='$FZF_DEFAULT_COMMAND'
29
30# ripped off from nixcasts' .bashrc
31pacs() {
32    sudo pacman -Syy $(pacman -Ssq | fzf -m --preview="pacman -Si {}" \
33        --preview-window=:hidden --bind=space:toggle-preview)
34}