Compare commits

8 Commits

10 changed files with 33 additions and 14 deletions
+3 -3
View File
@@ -68,7 +68,7 @@ doUpdateSystem() {
updateFlatpak() {
if [[ ! $(commandExists flatpak) ]]; then
if ! $(commandExists flatpak); then
return 1;
fi
noconfirm=
@@ -127,7 +127,7 @@ finds () {
# sends a desktop-notification with an icon signalling an error
notifyError () {
if [[ ! $(commandExists notify-send) ]]; then
if ! $(commandExists notify-send); then
echo "ERROR: $1";
else
notify-send "$1" --icon=data-warning;
@@ -137,7 +137,7 @@ notifyError () {
# sends a desktop-notification with an icon signalling a simple information
notifyInfo () {
if [[ ! $(commandExists notify-send) ]]; then
if ! $(commandExists notify-send); then
echo "INFO: $1";
else
notify-send "$1" --icon=preferences-desktop-notification;
+1 -1
View File
@@ -2,7 +2,7 @@
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples
set -o pipefail
# set -o pipefail
# set -u
# If not running interactively, don't do anything
+2 -2
View File
@@ -32,10 +32,10 @@ backupRootDirectory /etc/docker/daemon.json $BACKUP_DIR_ROOT/docker/
### upload backup ###
#####################
if [[ "$1" == "--noupload" ]]; then
if [[ $# > 0 && "$1" == "--noupload" ]]; then
exit 0;
fi
sd rsync_backup -e "ssh -i /home/edi/.ssh/id_ed25519" --filter="P /home/docker" /sync/backup/ fabian@garrus:/citadel/backup/edi/
sd rsync_backup -e "ssh -i /home/edi/.ssh/id_ed25519" /sync/backup/ fabian@garrus:/citadel/backup/edi/
sd rsync_backup -e "ssh -i /home/edi/.ssh/id_ed25519" /home/edi/docker/ fabian@garrus:/citadel/backup/edi/home/docker/
echo "Note: remember to keep /citadel in sync!"
+1 -1
View File
@@ -20,7 +20,7 @@ backupDirectory $HOME/.ssh/ $BACKUP_DIR_HOME/.ssh/
### upload backup ###
#####################
if [[ "$1" == "--noupload" ]]; then
if [[ $# > 0 && "$1" == "--noupload" ]]; then
exit 0;
fi
+1 -1
View File
@@ -4,4 +4,4 @@ set -euo pipefail
source /sync/scripts/dockerContainerAction.sh
# FIXME!!! implement possibility to pass down directory
upDownContainers down
upDownContainers down $@
+1
View File
@@ -13,6 +13,7 @@ replacements['(']='_';
replacements[')']='_';
replacements['[']='_';
replacements[']']='_';
replacements[',']='_';
while [[ $# > 0 ]]; do
replacements["$1"]="$2";
shift 2;
+18
View File
@@ -0,0 +1,18 @@
#!/usr/bin/env bash
set -euo pipefail
/sync/scripts/escapeFilenames.sh . _
declare -a dirs=();
for d in *; do
dirs+=($d);
done
for d in "${dirs[@]}"; do
cd "$d";
/sync/scripts/escapeFilenames.sh Chapter Kapitel
/sync/scripts/reencode_m4a.sh -map;
rm *.m4a;
mv * "../${d}_reencode";
cd ..;
rmdir "$d"
mv "${d}_reencode" "$d";
done
+1 -1
View File
@@ -4,4 +4,4 @@ set -euo pipefail
source /sync/scripts/dockerContainerAction.sh
# FIXME!!! implement possibility to pass down directory
upDownContainers pull
upDownContainers pull $@
+3 -3
View File
@@ -6,15 +6,15 @@ map=
vbr=
while [[ $# > 0 ]]; do
case $1 in
-map) map='-map 0:0'; shift;;
-vbr) vbr='aac_at -profile:a aac_he -b:a 64k'; shift;;
-map) map='-map 0:a'; shift;;
-vbr) vbr='aac -profile:a aac_he -b:a 64k'; shift;;
* ) break ;; # Anything else stops command line processing.
esac
done
# if no variable bitrate, just copy audio
if [[ -z $vbr ]]; then
map="$map copy"
vbr="copy"
fi
# ensure existence of destination folder
+1 -1
View File
@@ -4,4 +4,4 @@ set -euo pipefail
source /sync/scripts/dockerContainerAction.sh
# FIXME!!! implement possibility to pass down directory
upDownContainers up -d
upDownContainers up -d $@