From 2a88cdbcc88022e88ebe50a62e28bc0950b8b17c Mon Sep 17 00:00:00 2001 From: xHyroM Date: Tue, 15 Aug 2023 10:08:37 +0200 Subject: [PATCH] pacman ru, +x bin --- .local/bin/+x | 8 ++++++++ .zshrc | 8 ++++++++ 2 files changed, 16 insertions(+) create mode 100755 .local/bin/+x diff --git a/.local/bin/+x b/.local/bin/+x new file mode 100755 index 0000000..79e7ef8 --- /dev/null +++ b/.local/bin/+x @@ -0,0 +1,8 @@ +#!/bin/bash +# +x [file] +# make a file executable +if [ -z "$1" ]; then + echo "usage: +x [file]" + exit 1 +fi +chmod +x $@ diff --git a/.zshrc b/.zshrc index 3ab4e61..553722b 100644 --- a/.zshrc +++ b/.zshrc @@ -101,3 +101,11 @@ source $ZSH/oh-my-zsh.sh # alias ohmyzsh="mate ~/.oh-my-zsh" alias cat="bat" # use bat - https://github.com/sharkdp/bat alias ssh="kitty +kitten ssh" + +function pacman { + if [[ $1 == "ru" ]]; then + command pacman -Qtdq | sudo pacman -Rns - + else + command pacman "$@" + fi +}