My configurations for the software I use
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Remove unused scripts

yemou 6b19ad82 62670728

-251
-5
data/shellscripts/firefox
··· 1 - #!/bin/sh 2 - export HOMEWRAP_HOME="${XDG_STATE_HOME:-$HOME/.local/state}/homewrap/mozilla" 3 - [ -d "$HOMEWRAP_HOME" ] || mkdir -p "$HOMEWRAP_HOME" 4 - 5 - exec homewrap /usr/bin/firefox "$@"
-5
data/shellscripts/flatpak
··· 1 - #!/bin/sh 2 - export HOMEWRAP_HOME="${XDG_STATE_HOME:-$HOME/.local/state}/homewrap/flatpak" 3 - [ -d "$HOMEWRAP_HOME" ] || mkdir -p "$HOMEWRAP_HOME" 4 - 5 - exec homewrap /usr/bin/flatpak "$@"
-31
data/shellscripts/homewrap
··· 1 - #!/bin/sh 2 - # Some applications (namely java apps) get the home directory from /etc/passwd meaning that 3 - # we can't easily prevent these apps from writing in the home directory by changing the HOME env 4 - # var. Use bubblewrap to bind a random directory to /home/$USER instead. 5 - 6 - # Make sure we have a command to execute 7 - [ "$*" ] || { 8 - printf '%s\n' "Missing command to execute" 1>&2 9 - exit 1 10 - } 11 - 12 - # If HOMEWRAP_HOME isn't set, make our own and ensure that it exists 13 - : "${HOMEWRAP_HOME:=${XDG_STATE_HOME:-$HOME/.local/state}/homewrap/default}" 14 - mkdir -p "$HOMEWRAP_HOME" 15 - 16 - # Create sandbox with temporary home 17 - # This breaks if there is a broken symlink in the directory 18 - args="--dev-bind / / --dev-bind $HOMEWRAP_HOME $HOME " 19 - 20 - # Recreate the home directory 21 - for i in "$HOME/"* "$HOME/".* 22 - do 23 - case $i in 24 - "$HOME/." ) continue ;; 25 - "$HOME/.." ) continue ;; 26 - esac 27 - args="${args}--dev-bind $i $i " 28 - done 29 - 30 - # shellcheck disable=SC2086 31 - exec bwrap $args "$@"
-67
data/shellscripts/info-fetch
··· 1 - #!/bin/sh 2 - # Print some information about the system. This script was written with gentoo systems in mind. 3 - 4 - # Used Environment Variables 5 - # $SHELL 6 - # $USER 7 - 8 - # Used Files 9 - # /etc/os-release 10 - # /proc/sys/kernel/hostname 11 - # /proc/uptime 12 - # /proc/version 13 - 14 - # Get the hostname of the computer 15 - read -r hostname < /proc/sys/kernel/hostname 16 - 17 - # Source /etc/os-release if it exist 18 - # shellcheck source=/dev/null 19 - [ -f /etc/os-release ] && . /etc/os-release 20 - [ "$PRETTY_NAME" ] || PRETTY_NAME="Linux" 21 - 22 - # Get the kernel version 23 - read -r _ _ kernel_version _ < /proc/version 24 - 25 - # Read uptime 26 - read -r uptime _ < /proc/uptime 27 - 28 - # Remove extra percision 29 - up=${uptime%.*} 30 - 31 - # Calculate days, hours, minutes and seconds from the given output 32 - days=$((up / 86400)) 33 - hours=$(((up % 86400) / 3600)) 34 - min=$((((up % 86400) % 3600) / 60)) 35 - sec=$((((up % 86400) % 3600) % 60)) 36 - 37 - # Only display the value if it is not zero 38 - [ $days = 0 ] || dout="${days}d " 39 - [ $hours = 0 ] || hout="${hours}h " 40 - [ $min = 0 ] || mout="${min}m " 41 - [ $sec = 0 ] || sout="${sec}s" 42 - pretty_uptime="$dout$hout$mout$sout" 43 - 44 - # Calculate package count (Gentoo) 45 - set -- /var/db/pkg/*/* 46 - pkg_count=$# 47 - 48 - # Color Showcase 49 - for i in 0 1 2 3 4 5 6 7 50 - do 51 - normal_colors="$normal_colors\033[4${i}m\033[3${i}m " 52 - bright_colors="$bright_colors\033[10${i}m\033[9${i}m " 53 - done 54 - 55 - # Colors and Formatting 56 - color="\033[35;1m" 57 - nocolor="\033[m" 58 - underline="\033[4m" 59 - 60 - printf '%b\n' "\n$color$underline$USER$nocolor@$underline$color$hostname$nocolor" \ 61 - "${color}os$nocolor $PRETTY_NAME" \ 62 - "${color}ke$nocolor $kernel_version" \ 63 - "${color}up$nocolor $pretty_uptime" \ 64 - "${color}sh$nocolor ${SHELL##*/}" \ 65 - "${color}pk$nocolor $pkg_count\n" \ 66 - "$normal_colors$nocolor" \ 67 - "$bright_colors$nocolor\n"
-61
data/shellscripts/moulog
··· 1 - #!/bin/sh 2 - # A much better way to handle my logging 3 - 4 - #- Settings -# 5 - # Place to store log files 6 - : "${MOULOG_DIR:=${XDG_CACHE_HOME:-$HOME/.cache}/moulog}" 7 - # Max number of old dirs to keep 8 - : "${MOULOG_MAX:=5}" 9 - 10 - # TODO: Add option to name the log file. 11 - # As of right now, my wayfire logs aren't named anything related to wayfire. 12 - # This also extends to other logs. 13 - 14 - usage() { 15 - while read -r line 16 - do printf '%b\n' "$line" 17 - done <<-EOF 18 - ${0##*/} [options] [command] 19 - example: moulog -n 20 - example: moulog wlsunset -l 0 -L 0 21 - 22 - options: 23 - -h | --help - display this message 24 - -n | --new - create a new logging directory 25 - - useful if being run multiple times in the background 26 - 27 - environment vars: 28 - MOULOG_DIR - place to store logs (default: $XDG_CACHE_HOME/moulog) 29 - MOULOG_MAX - max number of old dirs to keep (default: 5) 30 - EOF 31 - 32 - exit "${1:-1}" 33 - } 34 - 35 - new_dir() { 36 - touch /tmp/moulog 37 - [ -d "$MOULOG_DIR.$MOULOG_MAX" ] && rm -r "$MOULOG_DIR.$MOULOG_MAX" 38 - 39 - i=$((MOULOG_MAX)) 40 - until [ $i = 1 ] 41 - do 42 - [ -d "$MOULOG_DIR.$((i-1))" ] && mv "$MOULOG_DIR.$((i-1))" "$MOULOG_DIR.$i" 43 - i=$((i-1)) 44 - done 45 - 46 - [ -d "$MOULOG_DIR" ] && mv "$MOULOG_DIR" "$MOULOG_DIR.1" 47 - mkdir -p "$MOULOG_DIR" 48 - } 49 - 50 - case $1 in 51 - -h|--help ) usage 0 ;; 52 - -n|--new ) new_dir; exit 0 ;; 53 - -N|--name ) program_name=$2; shift 2 ;; 54 - esac 55 - 56 - # Using this file to decide if a new directory should be made 57 - [ -f /tmp/moulog ] || new_dir 58 - 59 - 60 - printf '%s\n' "#### moulog start time: $(date +%s) ####" >> "$MOULOG_DIR/${program_name:=$1}.log" 61 - exec "$@" >> "$MOULOG_DIR/${program_name:=$1}.log" 2>&1
-6
data/shellscripts/scp
··· 1 - #!/bin/sh 2 - SSH_CONFIG="${XDG_CONFIG_HOME:-$HOME/.config}/ssh/config" 3 - SSH_ID="${XDG_DATA_HOME:-$HOME/.local/share}/ssh/id_ed25519" 4 - 5 - export TERM=xterm-256color 6 - exec /usr/bin/scp -F "$SSH_CONFIG" -i "$SSH_ID" "$@"
-2
data/shellscripts/slurp
··· 1 - #!/bin/sh 2 - exec /usr/bin/slurp -b 00000040 -w 0 "$@"
-6
data/shellscripts/ssh
··· 1 - #!/bin/sh 2 - SSH_CONFIG="${XDG_CONFIG_HOME:-$HOME/.config}/ssh/config" 3 - SSH_ID="${XDG_DATA_HOME:-$HOME/.local/share}/ssh/id_ed25519" 4 - 5 - export TERM=xterm-256color 6 - exec /usr/bin/ssh -F "$SSH_CONFIG" -i "$SSH_ID" "$@"
-17
data/shellscripts/steam
··· 1 - #!/bin/sh 2 - 3 - # Steam allows account switching now 4 - # case $1 in 5 - # b|blanklily ) S_HOME="blanklily"; shift ;; 6 - # c|crazykill_97 ) S_HOME="crazykill_97"; shift ;; 7 - # * ) S_HOME="blanklily" ;; 8 - # esac 9 - 10 - export HOMEWRAP_HOME="${XDG_STATE_HOME:-$HOME/.local/state}/homewrap/valve" 11 - [ -d "$HOMEWRAP_HOME" ] || mkdir -p "$HOMEWRAP_HOME" 12 - 13 - [ -f "${XDG_DATA_HOME:-$HOME/.local/share}/Steam/bootstrap.tar.xz" ] \ 14 - && rm -f "${XDG_DATA_HOME:-$HOME/.local/share}/Steam/bootstrap.tar.xz" 15 - 16 - export SDL_VIDEODRIVER=x11 17 - exec homewrap /usr/bin/steam "$@"
-13
data/shellscripts/wl
··· 1 - #!/bin/sh 2 - # Start new logging directory 3 - # moulog -n 4 - 5 - # Pick Wayland Compositor 6 - case $1 in 7 - wayfire|w ) 8 - export QT_QPA_PLATFORMTHEME=gnome 9 - export XDG_CURRENT_DESKTOP=Wayfire 10 - export XDG_SESSION_TYPE=wayland 11 - # exec moulog -N compositor dbus-run-session wayfire ;; 12 - exec dbus-run-session wayfire ;; 13 - esac
-38
data/shellscripts/wl-post
··· 1 - #!/bin/sh 2 - # Post startup script for wayland compositors 3 - 4 - # TODO: find a more standard way to autostart applications 5 - # https://wiki.archlinux.org/title/XDG_Autostart 6 - # https://specifications.freedesktop.org/autostart-spec/autostart-spec-latest.html 7 - 8 - # # Dbus (atleast with elogind) doesn't get updated environment variables causing 9 - # # some applications (like mako) to not autostart. 10 - # # moulog -N dbus-env dbus-update-activation-environment --all --systemd & 11 - # dbus-update-activation-environment --all --systemd & 12 - 13 - # # Configure displays 14 - # # moulog -N output-manager kanshi & 15 - # kanshi & 16 - 17 - # # Set idle actions 18 - # swayidle timeout 900 swaylock & 19 - 20 - # # Set a wallpaper 21 - # # moulog -N wallpaper swaybg \ 22 - # # -i "${HOME}/misc/syncthing/media/images/wallpapers/dark/evie-s-Pb1KFv4tauY-unsplash.jpg" \ 23 - # # -m fill & 24 - # swaybg \ 25 - # -i "${HOME}/misc/syncthing/media/images/wallpapers/dark/evie-s-Pb1KFv4tauY-unsplash.jpg" \ 26 - # -m fill & 27 - 28 - # # Nightlight 29 - # # moulog -N blue-light-filter wlsunset -l 33.9 -L -84.5 & 30 - # wlsunset -l 33.9 -L -84.5 & 31 - 32 - # # Syncthing 33 - # # moulog -N sync syncthing -no-browser & 34 - # syncthing -no-browser & 35 - 36 - # # Panel 37 - # moulog -N panel waybar & 38 - # waybar &