Compare commits

..

No commits in common. "53c6e8c70e79990c8e479cfbd0ef09f6e19ad888" and "0597bf34b3c0ef6b25a391313264360b89f8e8f4" have entirely different histories.

7 changed files with 51 additions and 6 deletions

2
rm.sh Normal file
View File

@ -0,0 +1,2 @@
rm -f /tmp/tobias.herre.txz
rm -rf /home/tobias.herre

8
test.sh Normal file
View File

@ -0,0 +1,8 @@
CONFIGDIRS="\
-path .config \
-path .local/share/backgrounds \
-path testdir1 \
-path testdir2"
echo $CONFIGDIRS

View File

@ -1,6 +1,7 @@
#!/bin/sh
HOMEDIR=$(getent passwd "$PAM_USER" | cut -d: -f6)
WMDERPDIRNAME=".wmde-osync"
WMDERPDIR="$HOMEDIR/$WMDERPDIRNAME"
LOGFILE=$WMDERPDIR/usersync.log

View File

@ -32,6 +32,24 @@ echo $$ > $PIDFILE
create_knonw_hosts_and_nfshomedir
iiiiiireplace_keys_values() {
outfile="$1"
shift # Entfernt outfile aus den Argumenten
infile="$PREFIX/osync.conf.template" # Kannst du bei Bedarf ebenfalls als Parameter machen
tmpfile="$(mktemp)"
cp "$infile" "$tmpfile"
for pair in "$@"; do
key="${pair%%=*}"
value="${pair#*=}"
escaped_key=$(printf '%s\n' "$key" | sed 's/[][\/.^$*]/\\&/g')
sed -i "s/^$escaped_key=.*/$key=$value/" "$tmpfile"
done
mv "$tmpfile" "$outfile"
}
replace_keys_values() {
outfile="$1"
@ -83,8 +101,6 @@ generate_config()
"MIN_WAIT=30" \
"MAX_WAIT=300" \
"FORCE_STRANGER_LOCK_RESUME=true" \
"LOGFILE=\"$WMDERPDIR/wmde-rp-sync.log\"" \

11
wmde-rp-progress.sh Executable file
View File

@ -0,0 +1,11 @@
#!/bin/sh
while true; do
size=$(du -sh $1 | cut -f1)
echo "Loading roaming profile: $size of $2."
sleep 3
done

11
wmde-rp-start-usersync.sh Executable file
View File

@ -0,0 +1,11 @@
#!/bin/sh
echo "hallo" >> /tmp/tobias
sleep 60
echo "sart hallo" >> /tmp/tobias
systemctl --user daemon-reload
systemctl --user enable wmde-rp-usersync-nfs.service
systemctl --user start wmde-rp-usersync-nfs.service
echo "end hallo" >> /tmp/tobias

View File

@ -15,13 +15,11 @@ NETGROUPS="wmde-rp-general"
WAIT_FOR_CONFIG=always # always, first or never
WAIT_FOR_FULLSYNC=never # always, first or never
WMDERPDIRNAME=".wmde-rp"
CONFIG_DIRS=" \
--exclude='$WMDERPDIRNAME' \
--exclude='.osync_workdir' \
--exclude='Local' \
--include='*.kdbx' \
--include='.ssh/***' \
--include='.cache/' \
@ -47,7 +45,6 @@ CONFIG_DIRS=" \
FULL_DIRS=" \
--exclude='$WMDERPDIRNAME' \
--exclude='.osync_workdir' \
--exclude='Local' \
--include='*.kdbx' \
--include='.ssh/***' \
--include='.cache/' \
@ -75,7 +72,6 @@ FULL_DIRS=" \
PERM_DIRS=" \
--exclude='$WMDERPDIRNAME' \
--exclude='.osync_workdir' \
--exclude='Local' \
--include='*.kdbx' \
--include='.ssh/***' \
--include='.cache/' \