diff --git a/common/bin/? b/common/bin/? new file mode 100755 index 0000000..bbf6d34 --- /dev/null +++ b/common/bin/? @@ -0,0 +1,8 @@ +#!/usr/bin/env fish + +echo "Keys you never remember:" +echo +echo "C-t fuzzy find a file or directory to insert into your command" +echo "C-g fuzzy find a directory to cd to" + +# https://github.com/lotabout/skim/blob/master/shell/key-bindings.fish diff --git a/common/bin/N b/common/bin/N index 79b9441..5ec9178 100755 --- a/common/bin/N +++ b/common/bin/N @@ -1,2 +1,2 @@ #!/usr/bin/env bash -fn="${1}"; shift; nf "${fn}.md" "$@" +fn="${1}"; shift; nf "${fn}.md" "$@" \ No newline at end of file diff --git a/common/bin/arch-in-docker b/common/bin/arch-in-docker deleted file mode 100755 index 54edeec..0000000 --- a/common/bin/arch-in-docker +++ /dev/null @@ -1,7 +0,0 @@ -#!/usr/bin/env fish - -if test (count $argv) -lt 2 - docker run -it --rm archlinux bash -else - docker run -it --rm $argv[1..-2] archlinux $argv[-1] -end diff --git a/common/bin/at b/common/bin/at index 0ffe44a..1c8a1f3 100755 --- a/common/bin/at +++ b/common/bin/at @@ -1,8 +1,12 @@ #!/usr/bin/env bash usage() { + echo "at - waits until after the specified datetime" echo "Usage:" - echo " at && command..." + echo " at && command..." + echo + echo "Examples:" + echo " at 15:00:00 && echo \"it is 3 o'clock\"" } [[ -z "$1" ]] && { echo "Error: No DATE argument provided." >&2; usage; exit 1; } @@ -13,4 +17,5 @@ while [[ "$d" -ge "$(date +%s)" ]]; do days=$((_dt / 86400)) echo -ne "\rTime Remaining: ${days}d $(date -u --date @$((_dt)) +%H:%M:%S) "; sleep 0.1 -done \ No newline at end of file +done +exit 0 \ No newline at end of file diff --git a/common/bin/b b/common/bin/b deleted file mode 100755 index 55a680d..0000000 --- a/common/bin/b +++ /dev/null @@ -1,14 +0,0 @@ -#!/usr/bin/env bash - -bbin="bible" # npm i -g bible -pbin="less" - -# bible args -bargs=("") - -# pager args -pargs="-R" - -[[ $1 = s ]] && { bargs+=("--search"); shift; } - -"${bbin}" "${bargs[@]}" "$*" | "${pbin}" $pargs diff --git a/common/bin/backupify b/common/bin/backupify deleted file mode 100755 index 1623895..0000000 --- a/common/bin/backupify +++ /dev/null @@ -1,52 +0,0 @@ -#!/usr/bin/env fish - -# deps: fish, zstd, gpg, ssh - -set -q HOST || set HOST (head -n 1 /etc/hostname | tr -d '\n') - -# use the backup-host in the ~/.ssh/config as the default backup remote host -set -q BACKUP_REMOTE_HOST || set BACKUP_REMOTE_HOST backup-host - -# use a user-specific dir by default to backup to -set -q BACKUP_REMOTE_DIR || set BACKUP_REMOTE_DIR "/storage/"(whoami)"/backups/$HOST" - -set BACKUP_FILE_EXT .tar.zstd.gpg - -if not set -q argv[1] - echo "No target file or directory provided" - exit 2 -end - -set target $argv[1] -if not test -d $target - echo "Target '$target' is not a directory" - exit 1 -end - -set remote_path - -pushd (dirname $target) >/dev/null -# TODO: progress bar/status? - set friendly_target (pwd) - set path_friendly_target (pwd | cut -c2- | string replace -a / %) - set backup_file_name (date +%Y-%m-%d_%H-%M-%S)_"$path_friendly_target" - - set remote_path "$BACKUP_REMOTE_DIR/$backup_file_name$BACKUP_FILE_EXT" - echo "Streaming PGP encrypted backup of $friendly_target to SSH host $BACKUP_REMOTE_HOST at $remote_path" - ssh $BACKUP_REMOTE_HOST "mkdir -p $BACKUP_REMOTE_DIR" || begin - echo "Failed to SSH to $BACKUP_REMOTE_HOST and create remote dir $BACKUP_REMOTE_DIR" - exit 3 - end - # TODO: progress indicator? - tar cf - . | - zstd --ultra -T2 -22 | - gpg --encrypt --recipient daniel@lyte.dev | - ssh $BACKUP_REMOTE_HOST "cat - > $remote_path" || begin - echo "Failed to stream backup" - exit 4 - end -popd >/dev/null - -# TODO: checksum? -echo "Uploaded to host rift via ssh at $remote_path" -echo " Run 'unbackupify \"$backup_file_name$BACKUP_FILE_EXT\"' to restore!" diff --git a/common/bin/bupstash-wip b/common/bin/bupstash-wip deleted file mode 100755 index e8417a6..0000000 --- a/common/bin/bupstash-wip +++ /dev/null @@ -1,14 +0,0 @@ -#!/usr/bin/env fish - -set keyfile $HOME/.bupstash/backups.key -if not test -f $keyfile - echo Loading key from pass... - pass bupstash | tail -n+3 > $keyfile; or begin; - echo Failed to load key from pass - exit 1 - end -end - -set rift ssh://rift/storage/daniel-backups - -bupstash init --repository $rift diff --git a/common/bin/calc b/common/bin/calc deleted file mode 100755 index 43f4a6e..0000000 --- a/common/bin/calc +++ /dev/null @@ -1,3 +0,0 @@ -#!/usr/bin/env bash - -python -c "print(${*})" diff --git a/common/bin/cdp b/common/bin/cdp deleted file mode 100755 index a6c001e..0000000 --- a/common/bin/cdp +++ /dev/null @@ -1,4 +0,0 @@ -#!/usr/bin/env bash - -# TODO: needs fixing...? -cd "$(dirname "$(sk)")" || exit 1 diff --git a/common/bin/check_domain b/common/bin/check-domain-availability similarity index 97% rename from common/bin/check_domain rename to common/bin/check-domain-availability index 151f2df..5afce64 100755 --- a/common/bin/check_domain +++ b/common/bin/check-domain-availability @@ -20,7 +20,7 @@ COLOR_RESET="\x1b[0m" COLOR_GREEN="\x1b[32m" COLOR_YELLOW="\x1b[33m" COLOR_RED="\x1b[31m" -DOMAINS=( \ +TLDS=( \ '.com' '.net' '.org' '.eu' '.in' '.it' '.sk' '.ac' '.ae' '.af' '.ag' '.al' \ '.am' '.as' '.at' '.ax' '.be' '.bi' '.bo' '.by' '.bz' '.cc' '.cd' '.cf' '.cg' \ '.ch' '.ci' '.cl' '.cm' '.cn' '.co' '.cr' '.cx' '.cz' '.dk' '.dm' '.do' '.ec' \ @@ -80,10 +80,10 @@ check_domain() { # iterate all provided domain names combined with all TLDs and check them # concurrently -elements=${#DOMAINS[@]} +elements=${#TLDS[@]} while (( "$#" )); do for (( i=0;i "$fn" echo "$fn" - # grim -g "$dim" - | tee "$fn" | wl-copy -f else exit 1 fi +# TODO: implement for X and other OSs? + # pkill unclutter # sleep 0.1 # import "$fn" diff --git a/common/bin/clipstatus b/common/bin/clipstatus deleted file mode 100755 index 6d0b030..0000000 --- a/common/bin/clipstatus +++ /dev/null @@ -1,5 +0,0 @@ -#!/usr/bin/env sh - -echo "Primary : $(xclip -out -selection primary)" -echo "Secondary: $(xclip -out -selection primary)" -echo "Clipboard: $(xclip -out -selection clipboard)" diff --git a/common/bin/compress b/common/bin/compress deleted file mode 100755 index b7cfcf4..0000000 --- a/common/bin/compress +++ /dev/null @@ -1,3 +0,0 @@ -#!/usr/bin/env bash - -zstd "$@" diff --git a/common/bin/copy-git-forge-url b/common/bin/copy-git-forge-url index a7a5ae7..287a94f 100755 --- a/common/bin/copy-git-forge-url +++ b/common/bin/copy-git-forge-url @@ -1,8 +1,21 @@ #!/usr/bin/env sh +usage() { + echo "copy-git-forge-url <$FILE>[#L$LINE_NUMBERS]" + echo " Copies a link to the git forge's web interface for the current branch to the clipboard" + echo + echo " Examples:" + echo " \$ copy-git-forge-url readme.md#L12" +} + +if [ "$#" -lt 1 ]; then + usage + exit 1 +fi + url="$(gitforge-url.ts "$1")" case "$(uname)" in Linux*) echo "$url" | clip;; - Darwin*) echo "$url" | pbcopy;; + Darwin*) echo "$url" | clip;; *) echo "OS not supported"; exit 1; esac \ No newline at end of file diff --git a/common/bin/countdown b/common/bin/countdown index d987c23..d6f00da 100755 --- a/common/bin/countdown +++ b/common/bin/countdown @@ -1,6 +1,6 @@ #!/usr/bin/env bash -[[ -z "${@}" ]] && { echo "No argument provided." >&2 ; exit 1; } +[[ $# -lt 1 ]] && { echo "No argument provided." >&2 ; exit 1; } d=$(($(date +%s) + $1)); echo "Countdown started at $(date)" diff --git a/common/bin/decompress b/common/bin/decompress deleted file mode 100755 index f47ea85..0000000 --- a/common/bin/decompress +++ /dev/null @@ -1,3 +0,0 @@ -#!/usr/bin/env bash - -unzstd "$@" diff --git a/common/bin/devtunnel b/common/bin/devtunnel deleted file mode 100755 index 30f1249..0000000 --- a/common/bin/devtunnel +++ /dev/null @@ -1,11 +0,0 @@ -#!/usr/bin/env moon -arg_spec = { - {"target", "REMOTE_MACHINE", "remote"} - {"fwd", "FORWARD_PORTS", "1313,3000,4800:8000,8080,1234,4400:4000,40080:80,40443:443"} - {"sargs", "SSH_ARGS", "-XY"} -} -args = {v[1], os.getenv(v[2]) or arg[i] or v[3] for i, v in ipairs(arg_spec)} -ports = {a, (if b == "" then a else b) for a, b in args.fwd\gmatch "(%d+):?(%d*),?"} -pargs = table.concat ["-L #{k}:localhost:#{v}" for k,v in pairs ports], " " -for k,v in pairs ports do print "Forwarding localhost:#{k} to #{args.target}:#{v}" -os.execute "ssh -N #{args.target} #{pargs} #{args.sargs}" diff --git a/common/bin/disable-laptop-keyboard b/common/bin/disable-laptop-keyboard deleted file mode 100755 index 223d1f6..0000000 --- a/common/bin/disable-laptop-keyboard +++ /dev/null @@ -1,5 +0,0 @@ -#!/usr/bin/env bash - -KEYBOARD_SEARCH_STRING="AT Translated.*keyboard" -BUILTIN_KEYBOARD_ID=$(xinput list | grep "$KEYBOARD_SEARCH_STRING" | sed -ne 's/^.*id\=\([0-9]*\).*/\1/p') -sudo xinput float "$BUILTIN_KEYBOARD_ID" diff --git a/common/bin/dotfiles-update b/common/bin/dotfiles-update deleted file mode 100755 index ea41dbe..0000000 --- a/common/bin/dotfiles-update +++ /dev/null @@ -1,5 +0,0 @@ -#!/usr/bin/env bash - -# TODO: implement - -echo "Not implemented" diff --git a/common/bin/email-via-mailgun-smtp b/common/bin/email-via-mailgun-smtp index 76f30b6..86aff63 100755 --- a/common/bin/email-via-mailgun-smtp +++ b/common/bin/email-via-mailgun-smtp @@ -69,5 +69,4 @@ swaks --auth \ --ap "$password" \ --to "$recipient" \ --h-Subject: "$subject" \ - --body "$body" - + --body "$body" \ No newline at end of file diff --git a/common/bin/enable-laptop-keyboard b/common/bin/enable-laptop-keyboard deleted file mode 100755 index 59149cc..0000000 --- a/common/bin/enable-laptop-keyboard +++ /dev/null @@ -1,8 +0,0 @@ -#!/usr/bin/env bash - -KEYBOARD_PARENT_SEARCH_STRING="Virtual core keyboard.*master keyboard" -PARENT_KEYBOARD_ID=$(xinput list | grep "$KEYBOARD_PARENT_SEARCH_STRING" | sed -ne 's/^.*id\=\([0-9]*\).*/\1/p') - -KEYBOARD_SEARCH_STRING="AT Translated.*keyboard" -BUILTIN_KEYBOARD_ID=$(xinput list | grep "$KEYBOARD_SEARCH_STRING" | sed -ne 's/^.*id\=\([0-9]*\).*/\1/p') -sudo xinput reattach "$BUILTIN_KEYBOARD_ID" "$PARENT_KEYBOARD_ID" diff --git a/common/bin/encrypted-dir-archive b/common/bin/encrypted-dir-archive deleted file mode 100755 index c205dda..0000000 --- a/common/bin/encrypted-dir-archive +++ /dev/null @@ -1,50 +0,0 @@ -#!/usr/bin/env bash - -usage() { - # shellcheck disable=SC2016 - echo 'encrypted-dir-archive - -This script streams an gpg-encrypted byte-stream of a zstd-compressed \ -tarball this can be redirected to a file for an encrypted backup. - -Very roughly, this is a small wrapper around `tar cf . | zstd | gpg --encrypt` \ -so you can go backwards to reverse the process `gpg --decrypt | zstd -d | tar xf`. - -You can stream over ssh as a remote backup by piping to something like this: \ -`ssh "$HOST" "cat - > '\$REMOTE_FILE'"`'. -} - -if [ "$1" = '-h' ] || [ "$1" = "--help" ]; then - usage - exit 0 -fi - -dir="$1" - -if [ -z "$dir" ]; then - echo "no directory argument provided" >&2 - usage - exit 1 -fi - -if [ ! -d "$dir" ]; then - echo "'$dir' is not a directory" >&2 - usage - exit 2 -fi - -# go to directory containing target directory -parent="$(dirname "$dir")" -pushd "$parent" >/dev/null || { echo "failed to cd to '$parent'" >&2; exit 3; } - -# https://stackoverflow.com/a/30520299 -if [ -t 1 ]; then - echo "not dumping encrypted data to terminal" - exit 4 -fi - -tar cf - "$(basename "$dir")" \ - | zstd --ultra -T2 -22 \ - | gpg --encrypt --recipient daniel@lyte.dev - -popd || echo "failed to return to original directory" >&2 diff --git a/common/bin/fsw b/common/bin/fsw deleted file mode 100755 index 56898aa..0000000 --- a/common/bin/fsw +++ /dev/null @@ -1,97 +0,0 @@ -#!/usr/bin/env bash - -_VERSION="0.2.0" - -function help() { - I=" " - cat << USAGE -fsw - run a command when a file is modified - v$_VERSION - -Usage: -${I}fsw [filter] [dirs...] - -${I}command - the specified bash command to eval -${I}filter - an optional filename filter -${I}dirs - the directories to watch (defaults to current directory) - -Advanced: -${I}Command Variables: -${I}${I}Your commands have runtime access to some variables associated with the -${I}${I}${I}inotifywait event enabling further extensibility: -${I}${I}+ FSW_FILENAME - the name of the file -${I}${I}+ FSW_DIR - the directory containing the file -${I}${I}+ FSW_PATH - the full relative path of the file -${I}${I}+ FSW_FILE_EVENTS - a comma-separated list of the inotify events -${I}Environment: -${I}${I}Some customization options exist using environment variables -${I}${I}${I}due to their uncommon usage. -${I}${I}+ FSW_EVENTS - the list of events to have inotifywait observe - -References: -${I}+ Filter works with grep -P -${I}+ See inotifywait(1) for FSW_EVENTS options. - -Examples: -${I}fsw 'make' '\.c$' -${I}fsw 'bash \$filename' '\.bash$' -${I}fsw 'mix test --failed' '.exs?$' lib test -${I}FSW_EVENTS=open,access fsw 'espeak "Intruder Alert!"' \\ -${I}${I}${I}'.*' /etc/secrets \$HOME/.secrets -USAGE -} - -dbg() { - if [[ -n ${FSW_DEBUG+x} ]]; then - echo -e "[debug] fsw: $*" - fi -} - -contains_element () { - local e match="$1"; shift - for e; do [[ "$e" == "$match" ]] && return 0; done - return 1 -} - -if [[ $1 = '-h' ]] || [[ $1 = '--help' ]] || [[ -z $1 ]]; then - help - exit 0 -fi - -FSW_EVENTS="${FSW_EVENTS:-close_write}" -dbg "Events: $FSW_EVENTS" -SHELL_COMMAND="${1}"; shift -dbg "Command: $SHELL_COMMAND" -FILTER="${1}"; shift -dbg "Filter: $FILTER" -dbg "Directory: ${1}" -DIRS=("${1:-.}"); shift -if [[ -e $FILTER ]]; then - # TODO: this is a sad hack/workaround - echo "It looks like your filter is an actual file. I'll just watch that for you." - DIRS=("${FILTER}") -fi -while [[ -n $1 ]] && realpath "$1" &> /dev/null; do - dbg "Directory: ${1}" - DIRS+=("$1"); shift -done -inotifywait -m -e "${FSW_EVENTS},delete,delete_self" -r "${DIRS[@]}" 2>&1 \ - | grep --line-buffered -v ' Beware: since -r was given, this may take a while!' \ - | while read -r dir events filename; do - if contains_element "$dir" "${DIRS[@]}" && [[ $events =~ "delete" ]]; then - echo "One of the watched directories (\"$dir\") was deleted. Exiting..." - exit 75 - fi - if [[ "$dir $events" = "Watches established." ]]; then - echo "Ready." - dbg "Directory: ${DIRS[*]}" - else - export FSW_FILENAME="$filename" - export FSW_DIR="$dir" - export FSW_PATH="$dir$filename" - export FSW_FILE_EVENTS="$events" - export FSW_EVENT="$events $dir$filename" - dbg "Event:\n $(date)\n $FSW_PATH\n $FILTER\n $FSW_EVENT\n $dir $events $filename\n ${SHELL_COMMAND}" - dbg "Filtered Event: $(<<< "$FSW_PATH" grep -P "$FILTER")" - <<< "$FSW_PATH" grep -P "$FILTER" > /dev/null 2>&1 && eval "${SHELL_COMMAND}" - fi -done diff --git a/common/bin/fswi b/common/bin/fswi deleted file mode 100755 index fc53f8b..0000000 --- a/common/bin/fswi +++ /dev/null @@ -1,4 +0,0 @@ -#!/usr/bin/env bash - -eval "${1}" -exec fsw "$@" diff --git a/common/bin/fzf-history-weight b/common/bin/fzf-history-weight deleted file mode 100755 index 35e2f9a..0000000 --- a/common/bin/fzf-history-weight +++ /dev/null @@ -1,15 +0,0 @@ -#!/usr/bin/env bash - -rf="$1" # history count record file -cf="$1" # all choices file - -touch "$LAUNCHER_HISTORY_FILE" -app="$( - < "$rf" awk 'NF{NF--};1' | cat - "$cf" | \ - sort | uniq -c | sort -nr | \ - sd '^\s+' '' | \ - cut -d' ' -f2- | \ - sk - )" -echo "$app $(date +%s)" >> "$LAUNCHER_HISTORY_FILE" -echo "$app" diff --git a/common/bin/fzfp b/common/bin/fzfp deleted file mode 100755 index 9204aad..0000000 --- a/common/bin/fzfp +++ /dev/null @@ -1,16 +0,0 @@ -#!/usr/bin/env sh - -FZFP_PASS_CMD="pass" -FZFP_PASS_DIR="$HOME/.password-store" - -FZFP_HEIGHT="${FZFP_HEIGHT:-40%}" -FZFP_PROMPT="${FZFP_PROMPT:-"$FZFP_PASS_CMD@$FZFP_PASS_DIR> "}" -FZFP_PASS_OPTS="${FZFP_PASS_OPTS:-}" - -cd "$FZFP_PASS_DIR" || { echo "Could not cd to $FZFP_PASS_DIR" >&2; exit 1; } - -# TODO: weighted history (see ./launch) -"${FZFP_PASS_CMD}" $FZFP_PASS_OPTS "$@" \ - "$(fd gpg | sd ".gpg" "" | fzf --height "$FZFP_HEIGHT" --prompt "$FZFP_PROMPT")" - -cd - >/dev/null || return 1 diff --git a/common/bin/fzfy b/common/bin/fzfy deleted file mode 100755 index fa76cb3..0000000 --- a/common/bin/fzfy +++ /dev/null @@ -1,3 +0,0 @@ -#!/usr/bin/env fish - -fish -c (history | head -n 1 | grep -v history) | sk diff --git a/common/bin/gcwd b/common/bin/gcwd deleted file mode 100755 index daa9bce..0000000 --- a/common/bin/gcwd +++ /dev/null @@ -1,6 +0,0 @@ -#!/usr/bin/env sh - -# TODO: must be sourced so as to not run in subshell? - -addon=""; [ -n "$1" ] && addon="-${1}" -cd "$(cat "${DOTFILES_PATH}/.cwd${addon}.tmp")" || return diff --git a/common/bin/git-authors b/common/bin/git-authors index b4856eb..ef75b2a 100755 --- a/common/bin/git-authors +++ b/common/bin/git-authors @@ -1,4 +1,8 @@ #!/usr/bin/env bash -git ls-tree -r -z --name-only HEAD -- "$1" | xargs -0 -n1 git blame \ - --line-porcelain HEAD | grep "^author "| sort | uniq -c | sort -nr +git ls-tree -r -z --name-only HEAD -- "$1" \ + | xargs -0 -n1 git blame --line-porcelain HEAD \ + | grep "^author " \ + | sort \ + | uniq -c \ + | sort -nr diff --git a/common/bin/git-cleanup-local-branches b/common/bin/git-cleanup-local-branches deleted file mode 100644 index 8094c0d..0000000 --- a/common/bin/git-cleanup-local-branches +++ /dev/null @@ -1,5 +0,0 @@ -#!/usr/bin/env sh - -git branch --merged | \ - grep -v "(^\*|master|main|dev)" | \ - xargs git branch -dr diff --git a/common/bin/grb b/common/bin/grb deleted file mode 100755 index 868024f..0000000 --- a/common/bin/grb +++ /dev/null @@ -1,12 +0,0 @@ -#!/usr/bin/env bash - -MAIN_BRANCH="master" -CUR_BRANCH="$(git branch | grep '\*' | cut -d ' ' -f2-)" -if [[ -n ${2+x} ]]; then - MAIN_BRANCH="$2" - CUR_BRANCH="$1" -elif [[ -n ${1+x} ]]; then - MAIN_BRANCH="$1" -fi - -git rebase -i "$(git merge-base "$CUR_BRANCH" "$MAIN_BRANCH")" diff --git a/common/bin/image-viewer b/common/bin/image-viewer deleted file mode 100755 index 54e6db9..0000000 --- a/common/bin/image-viewer +++ /dev/null @@ -1,2 +0,0 @@ -#!/usr/bin/env bash -feh -C /usr/share/fonts/ttf-iosevka-type -e "IosevkaLyte-type-regular/12" -d -., "$@" diff --git a/common/bin/inforge b/common/bin/inforge deleted file mode 100644 index dcf9579..0000000 --- a/common/bin/inforge +++ /dev/null @@ -1,3 +0,0 @@ -#!/usr/bin/env sh - -# open the target file in its git-forge in the browser diff --git a/common/bin/open-in-git-forge b/common/bin/open-in-git-forge index 1651240..30e4549 100755 --- a/common/bin/open-in-git-forge +++ b/common/bin/open-in-git-forge @@ -1,5 +1,18 @@ #!/usr/bin/env sh +usage() { + echo "open-in-git-forge <$FILE>[#L$LINE_NUMBERS]" + echo " Opens the URL in your browser to the git forge's web interface for the current branch for $FILE" + echo + echo " Examples:" + echo " \$ open-in-git-forge readme.md#L12" +} + +if [ "$#" -lt 1 ]; then + usage + exit 1 +fi + url="$(gitforge-url.ts "$1")" case "$(uname)" in Linux*) xdg-open "$url";; diff --git a/common/bin/optimize-image-for-web b/common/bin/optimize-photo-for-web similarity index 100% rename from common/bin/optimize-image-for-web rename to common/bin/optimize-photo-for-web diff --git a/common/fish/key-bindings.fish b/common/fish/key-bindings.fish index a12605b..1b02fd5 100644 --- a/common/fish/key-bindings.fish +++ b/common/fish/key-bindings.fish @@ -1,6 +1,13 @@ function fish_user_key_bindings set --export SKIM_TMUX_HEIGHT "" - command -q sk && functions | grep skim_key_bindings &>/dev/null && skim_key_bindings + set --export --universal SKIM_ALT_C_COMMAND "fd --hidden --type directory" + set --export --universal SKIM_CTRL_T_COMMAND "fd --hidden" + command -q sk && begin + functions | grep skim_key_bindings &>/dev/null && skim_key_bindings + + + bind -M insert \cg skim-cd-widget + end fish_vi_key_bindings insert --no-erase set --universal fish_cursor_default block diff --git a/os/linux/arch/provision.d/70-optional-packages.bash b/os/linux/arch/provision.d/70-optional-packages.bash index d864b26..453da44 100755 --- a/os/linux/arch/provision.d/70-optional-packages.bash +++ b/os/linux/arch/provision.d/70-optional-packages.bash @@ -23,4 +23,5 @@ paru -Sy --needed --noconfirm \ cloc `# For counting lines of code` \ gitui `# Git TUI` \ tokei `# Counting Lines of Code (cloc alternative)` \ + swaks `# Email CLI` \ pigz `# Multicore Compression Utility` \ diff --git a/os/linux/sway/mimeapps.list b/os/linux/sway/mimeapps.list index e69de29..3857901 100644 --- a/os/linux/sway/mimeapps.list +++ b/os/linux/sway/mimeapps.list @@ -0,0 +1,11 @@ +[Added Associations] +image/jpeg=krita_jpeg.desktop +image/png=krita_png.desktop + +[Default Applications] +image/jpeg=krita_jpeg.desktop +image/png=krita_png.desktop + +[MIME Cache] +image/jpeg=krita_jpeg.desktop +image/png=krita_png.desktop