Compare commits

...
5 Commits
11 changed files with 60 additions and 16 deletions
+18
View File
@@ -13,3 +13,21 @@
[submodule "RaspberryIO_26"]
path = RaspberryIO_26
url = http://git.blubbfish.net/vs_librarys/RaspberryIO_26.git
[submodule "Coordinates"]
path = Coordinates
url = https://git.blubbfish.net/vs_librarys/Coordinates.git
[submodule "DataMatrix.net"]
path = DataMatrix.net
url = https://git.blubbfish.net/vs_librarys/DataMatrix.net.git
[submodule "GPSDLib"]
path = GPSDLib
url = https://git.blubbfish.net/vs_librarys/GPSDLib.git
[submodule "ImageSharp"]
path = ImageSharp
url = https://git.blubbfish.net/vs_librarys/ImageSharp.git
[submodule "StreamDeckSharp"]
path = StreamDeckSharp
url = https://git.blubbfish.net/vs_librarys/StreamDeckSharp.git
[submodule "TelegramBot"]
path = TelegramBot
url = https://git.blubbfish.net/vs_librarys/TelegramBot.git
Submodule
+1
Submodule Coordinates added at 86f0509c9a
+1
Submodule DataMatrix.net added at ed37b7ba01
Submodule
+1
Submodule GPSDLib added at 0ff9e48e2e
Submodule
+1
Submodule ImageSharp added at 7e8cddf208
+1
Submodule StreamDeckSharp added at 308ba282fb
Submodule
+1
Submodule TelegramBot added at 17393a47d3
+1 -1
Submodule litjson updated: 875248bcdc...63561dc90d
+1 -1
Submodule mqtt updated: bd6472e5e4...0a913efc4a
+33 -13
View File
@@ -1,19 +1,39 @@
#!/bin/bash
function look_for_update() {
if [[ $1 == ./.* ]] || [[ $1 == "." ]]; then
return
fi
printf -v quotedFile '%q' "$1"
if [[ -f $quotedFile/update.sh ]]; then
echo "Switch to subdir $1 and run update.sh"
cd "$1"
bash -c ./update.sh
else
echo "Pull $quotedFile"
cd "$1"
git pull
if [[ $1 == ./.git ]] || [[ $1 == "." ]]; then
echo "Ignore $1"
return
fi
WithoutPrefix=$(echo -n $1 | cut -c 2-)
if grep -qx "$WithoutPrefix" .gitignore; then
echo "Ignore $1, because it's in .gitignore"
return
fi
printf -v FolderNameEscaped '%q' "$1"
if [[ -f $1/update.sh ]]; then
echo "Switch to subdir $1 and run update.sh"
cd "$1"
git pull
bash -c "./update.sh nobreak"
else
if [[ -f $1/.git ]]
then
echo "Pull $1"
cd "$1"
git pull
else
echo "Checkout master for $1"
git submodule update --init -- "$1"
cd "$1"
git checkout master
fi
fi
}
export -f look_for_update
find . -maxdepth 1 -type d -exec bash -c 'look_for_update "$0"' {} \;
read -p "Press return"
if [ -z $1 ]; then
read -p "Press return"
fi