Compare commits
2 commits
d74eef021f
...
9056b4f474
Author | SHA1 | Date | |
---|---|---|---|
|
9056b4f474 | ||
|
c5500b3ee0 |
8 changed files with 30 additions and 13 deletions
|
@ -371,6 +371,10 @@ alias fc='fossil commit -v'
|
|||
fdf() {
|
||||
fossil diff "$@" | clr
|
||||
}
|
||||
fuu() {
|
||||
rm .fslckout
|
||||
fossil open *.fossil --keep
|
||||
}
|
||||
|
||||
alias gdiff='git diff --word-diff=color --word-diff-regex=. --no-index'
|
||||
|
||||
|
@ -456,15 +460,17 @@ updateDeps() {
|
|||
esac
|
||||
shift 2
|
||||
done
|
||||
echo name "'$name'" depth "'$depth'" pattern "'$oldversion'" version "'$version'"
|
||||
find -maxdepth $depth -not \( -name "*forks" -prune \) -type f -name $name | while read f
|
||||
do highlight $f
|
||||
sed -i "s/\($pattern\)\($oldversion\)/\1${version:-\2}/gw /dev/stdout" $f
|
||||
done
|
||||
echo name "'$name'" depth "'$depth'" pattern "'$oldversion'" version "'$version'" >&2
|
||||
find -maxdepth $depth -not \( -name "*forks" -prune \) -type f -name $name |
|
||||
while read f
|
||||
do highlight $f
|
||||
sed -i "s/\($pattern\)\($oldversion\)/\1${version:-\2}/gw /dev/stdout" $f
|
||||
done
|
||||
}
|
||||
alias updateKotlin="updateDeps build.gradle.kts 'kotlin(\"jvm\") version \"' --version"
|
||||
alias updateGradle='updateDeps gradle-wrapper.properties "services.gradle.org\/distributions\/gradle-" --version'
|
||||
alias updateUtils="updateDeps build.gradle.kts '"'"com.github.Xerus2000.util", ".*", "'" --pattern '[^\"]\+' --version"
|
||||
updateKarma() { rpl "karma-runner.github.io/[^/]\+/" "karma-runner.github.io/$1/"; }
|
||||
|
||||
# Kill all shell background processes
|
||||
alias killbg='kill ${${(v)jobstates##*:*:}%=*}'
|
||||
|
|
|
@ -38,7 +38,7 @@ alias fixmime='sudo rm /usr/share/mime/packages/kde.xml && sudo update-mime-data
|
|||
theme_save="$XDG_CACHE_HOME/theme"
|
||||
#theme_default="$(d=$(date +%H) && test $d -gt 7 && test $d -lt 19 && echo light || echo dark)"
|
||||
theme_default="dark"
|
||||
theme() {
|
||||
themeswitch() {
|
||||
theme="$1"
|
||||
if test "$2" = "kde"
|
||||
then kcmshell5 kcm_lookandfeel
|
||||
|
@ -72,4 +72,4 @@ theme() {
|
|||
}
|
||||
export THEME=$(cat "$theme_save" 2> /dev/null)
|
||||
export THEME=${THEME:-$theme_default}
|
||||
theme $THEME
|
||||
themeswitch $THEME
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
#!/bin/sh -e
|
||||
#!/bin/sh
|
||||
# Suspend screen until enter is pressed
|
||||
xset dpms force off
|
||||
swaymsg "output * dpms off"
|
||||
read
|
||||
xset dpms force on
|
||||
swaymsg "output * dpms on"
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
#!/bin/sh -ex
|
||||
# Set exec flag on all files that should be executable
|
||||
find -maxdepth 4 -name "*.sh" "$@" -exec chmod -v +x {} +
|
||||
find -maxdepth 4 -name "*.sh" -o -path '*/githooks/*' "$@" -exec chmod -v +x {} +
|
||||
|
|
|
@ -1,6 +1,9 @@
|
|||
#!/bin/sh
|
||||
# Upload website to iridion
|
||||
# TODO: derive from id
|
||||
if test $# -eq 0
|
||||
then echo "$0 site [index.html] [USER]"
|
||||
else
|
||||
site=$1
|
||||
shift
|
||||
scp -r "$@" "iridion:web/$site/public_html$(test "$#" -gt 1 || echo '/index.html')"
|
||||
scp -r "$@" "iridion:/home/${2:-$USER}/web/$site/public_html$(test "$#" -gt 1 || echo '/index.html')"
|
||||
fi
|
||||
|
|
6
.local/bin/scripts/keys
Executable file
6
.local/bin/scripts/keys
Executable file
|
@ -0,0 +1,6 @@
|
|||
#!/bin/sh
|
||||
# Lists the keys for each given song
|
||||
for arg
|
||||
do echo -n "$arg: "
|
||||
keyfinder-cli "$arg"
|
||||
done
|
|
@ -1,6 +1,6 @@
|
|||
#!/bin/sh
|
||||
# [M]edia [P]lay
|
||||
# Play given files on mpd, playing external files through symlinking and recursively resolving playlists
|
||||
# Add matchings songs to mpd queue, playing external files through symlinking and recursively resolving playlists
|
||||
# depends: xargs realpath mpc
|
||||
# env: MUSIC
|
||||
# TODO auto-convert unknown types with ffmpeg to flac rather than linking (wav, opus, ...)
|
||||
|
|
|
@ -28,7 +28,7 @@ case $command in
|
|||
(fix) sed -i 's/.*\/\(musi[kc]\|janek\)/../g' "$@";;
|
||||
(cd) dir="${2:-cd}"
|
||||
mkdir "$dir"
|
||||
cat "$1" | python -c "import sys, urllib as ul; [sys.stdout.write(ul.unquote_plus(l)) for l in sys.stdin]" | sed '=' | sed -r 's/^[0-9]$/0\0/' | sed -r "N; s/(.*)\n(.*\/[0-9 ]*(.*))/'\2'\n'$dir\/\1 \3'/" | xargs -L 2 cp;;
|
||||
cat "$1" | python2 -c "import sys, urllib as ul; [sys.stdout.write(ul.unquote_plus(l)) for l in sys.stdin]" | sed '=' | sed -r 's/^[0-9]$/0\0/' | sed -r "N; s/(.*)\n(.*\/[0-9 ]*(.*))/'\2'\n'$dir\/\1 \3'/" | xargs -L 2 cp;;
|
||||
(*) echo "Unknown subcommand '$1' - Possible subcommands:
|
||||
update - update file paths for moved songs in a playlist
|
||||
edit - open playlist in default editor
|
||||
|
|
Loading…
Add table
Reference in a new issue