diff --git a/.bin/dexec_browser b/.bin/dexec_browser index cc24305..b7c9dcf 100755 --- a/.bin/dexec_browser +++ b/.bin/dexec_browser @@ -142,7 +142,8 @@ choose_browser() { *club.de*) DEFAULT="Chrome (default)"; ;; *life.com*) DEFAULT="Chrome (default)"; ;; *videos.com*) DEFAULT="Chrome (default)"; ;; - *youtube.com/watch*) DEFAULT="Mpv (default)"; ;; + *comdirect.de*) DEFAULT="Chrome (default)"; ;; + *youtube.com*) DEFAULT="Chrome (default)"; ;; *media.ccc.de/v/*) DEFAULT="Mpv (default)"; ;; *.pdf|*.cb|*.ps) DEFAULT="Zathura (default)"; ;; *.mp4|*.m4v|*.mkv) DEFAULT="Mpv (default)"; ;; diff --git a/.bin/osmc b/.bin/osmc index 6628425..b5da4a6 100755 --- a/.bin/osmc +++ b/.bin/osmc @@ -1,18 +1,23 @@ #!/bin/sh +USBDISK=/mnt/1TB + case "$1" in - put|push) shift; rsync -rv --progress --append-verify $@ osmc:/media/USBDisk/ ;; - df) shift; ssh osmc "df -h /media/USBDisk/" ;; - ls) shift; ssh osmc "cd /media/USBDisk/ && ls $@ | grep -v lost+found" ;; - lls) shift; ssh osmc "cd /media/USBDisk/ && ls -lh | grep -v lost+found" ;; - del) shift; ssh osmc "cd /media/USBDisk/ && rm -v $@" ;; - ren) shift; ssh osmc "cd /media/USBDisk/ && mv \"$1\" \"$2\"" ;; + mount) shift; ssh -tt osmc "sudo /sbin/cryptdisks_start usbdisk" \ + && ssh osmc "sudo mount /mnt/1TB" ;; + put|push) shift; rsync -rv --progress --append-verify "$@" osmc:$USBDISK/ ;; + df) shift; ssh osmc "df -h $USBDISK" ;; + ls) shift; ssh osmc "cd $USBDISK && ls $@ | grep -v lost+found" ;; + lls) shift; ssh osmc "cd $USBDISK && ls -lh | grep -v lost+found" ;; + del) shift; ssh osmc "cd $USBDISK && rm -v $@" ;; + ren) shift; ssh osmc "cd $USBDISK && mv \"$1\" \"$2\"" ;; at) shift; ssh -tt osmc "tmux at" ;; *) echo "usage: osmc " + echo " mount - mount USB disk" echo " df - show disk space allocation" echo " ls - list files" echo " lls - list files with details" - echo " put - copy files to USBDisk" + echo " put - copy files to USB disk" echo " ren - rename file" echo " del - delete file" echo " at - attach to tmux session" diff --git a/.config/luakit/rc.lua b/.config/luakit/rc.lua index acddc2a..e450404 100644 --- a/.config/luakit/rc.lua +++ b/.config/luakit/rc.lua @@ -220,48 +220,48 @@ end follow.pattern_maker = follow.pattern_styles.match_label --- -- social media enhancer --- local webview = require "webview" --- webview.add_signal('init', function (view) --- view:add_signal('navigation-request', function(v, uri) --- if v.uri:match('https://www.reddit.com') then --- v.uri = v.uri:gsub('%www.reddit.com', 'old.reddit.com') --- return true --- end --- if v.uri:match('https://new.reddit.com') then --- v.uri = v.uri:gsub('%new.reddit.com', 'old.reddit.com') --- return true --- end --- -- if v.uri:match('https://old.reddit.com') then --- -- v.uri = v.uri:gsub('%old.reddit.com', 'libreddit.kylrth.com') --- -- return true --- -- end --- -- if v.uri:match('https://old.reddit.com') then --- -- v.uri = v.uri:gsub('%old.reddit.com', 'libreddit.kylrth.com') --- -- return true --- -- end --- if v.uri:match('https://www.twitter.com') then --- v.uri = v.uri:gsub('%www.twitter.com', 'nitter.net') --- return true --- end --- if v.uri:match('https://twitter.com') then --- v.uri = v.uri:gsub('%twitter.com', 'nitter.net') --- return true --- end --- if v.uri:match('https://www.youtube.com') then --- v.uri = v.uri:gsub('%www.youtube.com', 'tube.cadence.moe') --- return true --- end --- if v.uri:match('https://youtube.com') then --- v.uri = v.uri:gsub('%youtube.com', 'tube.cadence.moe') --- return true --- end --- if v.uri:match('https://youtu.be') then --- v.uri = v.uri:gsub('%youtu.be/', 'tube.cadence.moe/watch?v=') --- return true --- end --- end) --- end) +-- social media enhancer +local webview = require "webview" +webview.add_signal('init', function (view) + view:add_signal('navigation-request', function(v, uri) + if v.uri:match('https://www.reddit.com') then + v.uri = v.uri:gsub('%www.reddit.com', 'old.reddit.com') + return true + end + if v.uri:match('https://new.reddit.com') then + v.uri = v.uri:gsub('%new.reddit.com', 'old.reddit.com') + return true + end + if v.uri:match('https://old.reddit.com') then + v.uri = v.uri:gsub('%old.reddit.com', 'redlib.kylrth.com') + return true + end + if v.uri:match('https://old.reddit.com') then + v.uri = v.uri:gsub('%old.reddit.com', 'redlib.kylrth.com') + return true + end + if v.uri:match('https://www.twitter.com') then + v.uri = v.uri:gsub('%www.twitter.com', 'nitter.net') + return true + end + if v.uri:match('https://twitter.com') then + v.uri = v.uri:gsub('%twitter.com', 'nitter.net') + return true + end + if v.uri:match('https://www.youtube.com') then + v.uri = v.uri:gsub('%www.youtube.com', 'tube.cadence.moe') + return true + end + if v.uri:match('https://youtube.com') then + v.uri = v.uri:gsub('%youtube.com', 'tube.cadence.moe') + return true + end + if v.uri:match('https://youtu.be') then + v.uri = v.uri:gsub('%youtu.be/', 'tube.cadence.moe/watch?v=') + return true + end + end) +end) -- social media blocker local webview = require "webview" diff --git a/.mutt/mailcap b/.mutt/mailcap index d5b3490..870374d 100644 --- a/.mutt/mailcap +++ b/.mutt/mailcap @@ -27,7 +27,7 @@ text/html; w3m -I %{charset} -T %t -cols "$COLUMNS" -s -no-graph -o display_link message/*; cat %s; needsterminal; # documents -application/pdf; ~/.mutt/scripts/call.sh mupdf %s; nametemplate=%s.pdf; +application/pdf; ~/.mutt/scripts/call.sh zathura %s; nametemplate=%s.pdf; application/vnd.openxmlformats-officedocument.wordprocessingml.document; ~/.mutt/scripts/call.sh libreoffice %s; application/vnd.openxmlformats-officedocument.spreadsheetml.sheet; ~/.mutt/scripts/call.sh libreoffice %s; application/vnd.openxmlformats-officedocument.presentationml.presentation; ~/.mutt/scripts/call.sh libreoffice %s;