Added script for launching nextcloud with kwallet
Source: https://github.com/nextcloud/desktop/issues/1011#issuecomment-510153674
This commit is contained in:
parent
905ad5cc27
commit
86e4952f6c
1 changed files with 19 additions and 0 deletions
19
scripts/nextcloud-kwallet.sh
Executable file
19
scripts/nextcloud-kwallet.sh
Executable file
|
@ -0,0 +1,19 @@
|
|||
#!/bin/bash
|
||||
#
|
||||
# See https://github.com/nextcloud/desktop/issues/1011
|
||||
#
|
||||
############################################
|
||||
# Adjust the following to suit your needs
|
||||
WALLET="kdewallet" # Name of wallet storing nextcloud client password
|
||||
MAX_TRIES=2 # Max. number of tries to ask for password
|
||||
############################################
|
||||
i=0
|
||||
while [ $i -lt $MAX_TRIES ]; do
|
||||
((i++))
|
||||
open=`qdbus org.kde.kwalletd5 /modules/kwalletd5 isOpen "$WALLET"`
|
||||
if [ "$open" = "true" ]; then
|
||||
break
|
||||
fi
|
||||
qdbus org.kde.kwalletd5 /modules/kwalletd5 open "$WALLET" 0 "nextcloud-client-starter" > /dev/null
|
||||
done
|
||||
nohup nextcloud >> /dev/null 2>&1
|
Loading…
Reference in a new issue