Updated comments.

This commit is contained in:
dabruh 2022-06-08 21:23:51 +02:00
parent c3e7c1dfa3
commit b0605fa018
14 changed files with 47 additions and 8 deletions

View File

@ -1,10 +1,11 @@
#!/bin/bash
# cmus-track
#
# Remove or move the current playing cmus track and play the next track.
# cmus track control for moving or removing the current track.
#
# Usage:
# cmus-track rm
# cmus-track rm # will also switch to the next track
# cmus-track mv path/to/new/dir
#

View File

@ -1,5 +1,10 @@
#!/bin/bash
# cmusctl
#
# Allows executing 'cmus-remote' commands and writes the currently
# playing song to a file so be consumed by e.g. i3status.
SCRIPT_NAME="$(basename -- "$0")"
function usage() {

View File

@ -1,6 +1,8 @@
#!/bin/bash
# Simple console CSV viewer
# csview
#
# A very simple and crude terminal CSV viewer - nothing more.
file="${1:?}" || exit 1
sed -e 's/,,/, ,/g' "$file" | column -s, -t | less -#5 --LINE-NUMBERS --chop-long-lines --RAW-CONTROL-CHARS

View File

@ -1,5 +1,7 @@
#!/bin/bash
# cx - Kubernetes context switcher
LAST=/tmp/last_kube_context
CURR="$(kubectl config current-context)"
[[ -z "$1" ]] && kubectl config get-contexts && exit

View File

@ -1,5 +1,9 @@
#!/bin/bash
# dmenuexit
#
# Provides a dmenu for the various commands available through ./i3exit
# shellcheck disable=SC2086
DMENU_ARGS="-i -nb #e74c3c -nf #303030 -sb #c0392b -sf #ecf0f1"

View File

@ -1,5 +1,7 @@
#!/bin/bash
# dmenugtranslate
#
# Translate the current clipboard with the help of dmenu
#
# Utilized gtranslate. Install instructions here:

View File

@ -1,5 +1,11 @@
#!/bin/bash
# dmenuxautolock
#
# Provides a dmenu for configuring the lock timeout and notification duration
# for xautolock - a utility which triggers screen lock - in this case using
# 'loginctl lock-session'.
SCRIPT_NAME="$(basename -- "$0")"
FILE="/tmp/dmenuxautolock"
DEFAULT_TIMEOUT=60

View File

@ -1,7 +1,6 @@
#!/bin/bash
#
# Title: i3-config-builder
# i3-config-builder
# Version: 0.1.0
# Author: dabruh
# GitLab: https://gitlab.com/dabruh
@ -22,7 +21,6 @@
# executes this script.
#
# The contents of the .layer files are read first, and then sorted.
#
HOSTNAME="$(hostname | cut -d. -f1)"
PATTERNS=(

View File

@ -1,5 +1,8 @@
#!/bin/bash
# /usr/bin/i3exit
# i3exit
#
# Provide simple arguments for various locking and power related tasks.
# with openrc use loginctl
[[ $(cat /proc/1/comm) == "systemd" ]] && logind=systemctl || logind=loginctl

View File

@ -1,5 +1,8 @@
#!/bin/bash
# kill-remote-sessions
#
# Kills *any* active or inactive 'kubectl exec' or 'ssh' sessions.
pkill -fe 'kubectl exec'
pkill -fe 'ssh '

View File

@ -1,5 +1,10 @@
#!/bin/bash
# pavolctl
#
# Provides an easy method of setting the default sink volume in PulseAudio and
# allows toggling mute on the sink.
PULSEAUDIO_SINK="${PULSEAUDIO_SINK:-"@DEFAULT_SINK@"}"
VOLUME_LIMIT="${VOLUME_LIMIT:-150}"

View File

@ -1,5 +1,9 @@
#!/bin/bash
# randverse
#
# Display a random Bible verse.
BIBLE=~/.local/share/dabruh/bible.txt
LINES="$(wc -l <"$BIBLE")"
LINE=$(( RANDOM % LINES + 2 )) # + 2 to skip first line

View File

@ -1,5 +1,7 @@
#!/bin/bash
# send-bankid-token
#
# Takes a bankid URI as input, extracts the token and writes the token to disk
# on a target Windows SSH host. The target host is expected to watch for this
# file, just like the following PowerShell script does:

View File

@ -1,5 +1,7 @@
#!/bin/bash
# vidstab
#
# Stabilizes a video
input=${1:?}