Files
dotfiles/shell-common/.config/shell-common/aliases.sh

22 lines
483 B
Bash

# shellcheck shell=bash
alias ls="ls -F --color=auto"
# Use code-insiders if installed
if [ -x "$(command -v code-insiders)" ]; then
alias code="code-insiders"
fi
# NixOS aliases
if [ -f "/etc/NIXOS" ]; then
alias nixos-rebuild="cd ~/nixos-config && make rebuild"
fi
# Tmux
if [ -x "$(command -v tmux)" ]; then
alias t='(tmux has-session 2>/dev/null && tmux attach) || (tmux new-session)'
alias tma="tmux attach"
fi
alias last="last | head"
alias dp="demoprompt"