update scripts
This commit is contained in:
parent
2015ad637c
commit
490f2f3eb8
32
home/default/scripts/convert-to-audio
Executable file
32
home/default/scripts/convert-to-audio
Executable file
@ -0,0 +1,32 @@
|
||||
#!/usr/bin/env sh
|
||||
|
||||
# rename .MKV -> .MKV
|
||||
count=`ls -1 *.JPG 2>/dev/null | wc -l`
|
||||
if [ $count != 0 ]; then
|
||||
rename MKV mkv *.MKV
|
||||
fi
|
||||
|
||||
# convert to opus
|
||||
count=`ls -1 *.mkv 2>/dev/null | wc -l`
|
||||
if [ $count != 0 ]; then
|
||||
for i in *.mkv; do
|
||||
ffmpeg -i "$i" "${i%.mkv}.opus";
|
||||
rm "$i";
|
||||
done
|
||||
fi
|
||||
|
||||
# rename .WEBM -> .webm
|
||||
count=`ls -1 *.WEBM 2>/dev/null | wc -l`
|
||||
if [ $count != 0 ]; then
|
||||
rename WEBM webm *.WEBM
|
||||
fi
|
||||
|
||||
# convert to opus
|
||||
count=`ls -1 *.webm 2>/dev/null | wc -l`
|
||||
if [ $count != 0 ]; then
|
||||
for i in *.webm; do
|
||||
ffmpeg -i "$i" "${i%.webm}.opus";
|
||||
rm "$i";
|
||||
done
|
||||
fi
|
||||
|
7
home/default/scripts/list-packages
Executable file
7
home/default/scripts/list-packages
Executable file
@ -0,0 +1,7 @@
|
||||
#!/usr/bin/env bash
|
||||
set -eou pipefail
|
||||
|
||||
echo $(pacman -Qqe) | \
|
||||
tr " " "\n" | \
|
||||
sort \
|
||||
> /packages.txt
|
5
home/default/scripts/refresh-screens
Executable file
5
home/default/scripts/refresh-screens
Executable file
@ -0,0 +1,5 @@
|
||||
#!/bin/bash
|
||||
set -eou pipefail
|
||||
|
||||
swaymsg "output * dpms off" && \
|
||||
swaymsg "output * dpms on"
|
12
home/default/scripts/restart-audio
Executable file
12
home/default/scripts/restart-audio
Executable file
@ -0,0 +1,12 @@
|
||||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
echo stopping pipewire-media-session...
|
||||
systemctl --user stop pipewire-media-session
|
||||
echo stopping pipewire...
|
||||
systemctl --user stop pipewire
|
||||
echo starting pipewire...
|
||||
systemctl --user start pipewire
|
||||
echo starting pipewire-media-session...
|
||||
systemctl --user start pipewire-media-session
|
||||
|
Loading…
Reference in New Issue
Block a user