santiago / Upgrade snac to stable
0 mi piace
0 forks
1 files
Ultima volta attivo
| 1 | #!/usr/bin/env bash |
| 2 | |
| 3 | #Pre existing cloned repo |
| 4 | cd $HOME/snac2 |
| 5 | |
| 6 | SNAC_USER=snac |
| 7 | SNAC_DATA=/home/snac/data |
| 8 | |
| 9 | separator() { |
| 10 | printf '=%.0s' $(seq $(tput cols)) |
santiago / /etc/nginx/update-home-ip.sh
0 mi piace
0 forks
1 files
Ultima volta attivo
| 1 | #!/usr/bin/env bash |
| 2 | |
| 3 | # ------------------------------------------------------------------------------ |
| 4 | # This will either allow automically with allowed IP or ask for auth otherwise |
| 5 | # in /etc/nginx/sites-available/search.lema.org |
| 6 | # ------------------------------------------------------------------------------ |
| 7 | # satisfy any; |
| 8 | # include /etc/nginx/home_allow.conf; |
| 9 | # auth_basic "Restricted"; |
| 10 | # auth_basic_user_file /etc/nginx/.htpasswd; |
santiago / vv.sh - vim or sudo vim
0 mi piace
0 forks
1 files
Ultima volta attivo
| 1 | #!/bin/bash |
| 2 | |
| 3 | vv() { |
| 4 | if [ $# -eq 0 ]; then |
| 5 | echo "Usage: vv <file>" |
| 6 | echo "Will edit with current user or sudo if needed but using nvim config of this user" |
| 7 | return 1 |
| 8 | fi |
| 9 | |
| 10 | vpath=$(which $EDITOR) |
santiago / amishell.sh window decoration
0 mi piace
0 forks
1 files
Ultima volta attivo
| 1 | #!/bin/bash |
| 2 | |
| 3 | cd /home/pi/scripts/ |
| 4 | /bin/lxterminal -e 'tmux' & |
| 5 | sleep 8 |
| 6 | source ./windowfix.sh |
| 7 | |
| 8 | window_name="tmux" |
| 9 | |
| 10 | #resizing like this fails on cool retro term but we use geometry above |
santiago / windowfix.sh
0 mi piace
0 forks
1 files
Ultima volta attivo
| 1 | #!/usr/bin/env zsh |
| 2 | |
| 3 | |
| 4 | wait_find_window_id() { |
| 5 | while true; do |
| 6 | window_id=$(wmctrl -l | grep "$1" | awk '{print $1}') |
| 7 | if [ -n "$window_id" ]; then |
| 8 | echo "$window_id" |
| 9 | return |
| 10 | fi |
santiago / mqtt_shutdown_listen.sh
0 mi piace
0 forks
1 files
Ultima volta attivo
Simple script listens to a MQTT value change and shutdown the machine
| 1 | #!/usr/bin/env zsh |
| 2 | |
| 3 | |
| 4 | if [ -z "$RASPISTUFF_DIR" ];then |
| 5 | export RASPISTUFF_DIR="$(cd "$(dirname "$(readlink -f "${(%):-%x}")")" && pwd)" |
| 6 | fi |
| 7 | |
| 8 | |
| 9 | cd $RASPISTUFF_DIR |
santiago / mxd_update_content.sh
0 mi piace
0 forks
1 files
Ultima volta attivo
| 1 | #!/bin/bash |
| 2 | |
| 3 | BASEDIR=/var/www/www.lema.org |
| 4 | |
| 5 | cd $BASEDIR |
| 6 | |
| 7 | # Recreate the zip file with only .md and .adoc files, preserving subfolders |
| 8 | # but not the "content/" folder |
| 9 | (cd content && zip -r ../mxd_content.zip . -i '*.md' '*.gmi' '*.adoc') |
santiago / upgrade_snac_to_head.sh
0 mi piace
0 forks
1 files
Ultima volta attivo
| 1 | "upgrade_snac_to_head.sh" 36L, 604B 16,30 All |
| 2 | #!/usr/bin/env bash |
| 3 | |
| 4 | #Pre existing cloned repo |
| 5 | cd $HOME/snac2 |
| 6 | |
| 7 | SNAC_USER=snac |
| 8 | SNAC_DATA=/home/snac/data |
| 9 | |
| 10 | separator() { |
santiago / upgrade_snac.sh
0 mi piace
0 forks
1 files
Ultima volta attivo
| 1 | ~ |
| 2 | ~ |
| 3 | "upgrade_snac.sh" 39L, 724B 18,1 All |
| 4 | #!/usr/bin/env bash |
| 5 | |
| 6 | #Pre existing cloned repo |
| 7 | cd $HOME/snac2 |
| 8 | |
| 9 | SNAC_USER=snac |
| 10 | SNAC_DATA=/home/snac/data |
Più nuovi
Più vecchi