bin: add scr and https

This commit is contained in:
xeruf 2021-11-02 12:00:02 +00:00
parent e1ee8dba79
commit d0e8310c94
3 changed files with 17 additions and 2 deletions

View File

@ -130,7 +130,15 @@ alias scu='systemctl --user'
alias scue='systemctl --user enable --now'
alias scud='systemctl --user disable --now'
# Restart matching systemctl service
# Reload or restart matching systemctl service
scr() {
systemctl --user reload "$1" ||
sudo systemctl reload "$1" ||
systemctl --user restart "$1" ||
sudo systemctl restart"$1" ||
}
# Restart matching systemctl service with chance for input inbetween
scb() {
systemctl --user stop -T "$1"
sudo systemctl stop -T "$1"

View File

@ -2,9 +2,10 @@
# [b]rowse - custom ls or bat depending on file type
# Show type & contents of given files or PWD
# depends: tput stat bat neovim
# args: files to inspect
set -eo pipefail
# gets the last arg or current dir
# get the last arg or current dir
for last; do true; done
last=${last:-.}

6
.local/bin/scripts/https Executable file
View File

@ -0,0 +1,6 @@
#!/bin/sh
# Setup certbot certificate for nginx
# args:
# 1) domain
# 2) email
sudo certbot -v -n certonly --nginx -m ${2:-$(git config --get user.email)} --agree-tos -d $1