The Open Source kanban (built with Meteor). Keep variable/table/field names camelCase. For translations, only add Pull Request changes to wekan/i18n/en.i18n.json , other translations are done at https://transifex.com/wekan/wekan only.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
wekan/snap-src/wekan-read-settings

36 lines
992 B

#!/bin/sh
# read wekan config
source $SNAP/bin/config
# TODO: uncomment following, once snapctl can be called from outside the hooks
# for key in ${keys[@]}
# do
# # snappy is picky about key syntax, using mapping
# MAP_KEY="KEY_$key"
# SNAPPY_KEY=
# if value=$(snapctl get ${!MAP_KEY}); then
# echo "$key='$value'"
# export $key=$value
# else
# # use default value
# default_value="DEFAULT_$key"
# echo "using default value: $key='${!default_value}'"
# export $key=${!default_value}
# fi
# done
# TODO: get rid of this workaround once above can be used
# loop through all values, and if not defined, use default value
for key in ${keys[@]}
do
if [ "x" == "x${!key}" ]; then
# use default value
default_value="DEFAULT_$key"
echo "using default value: $key='${!default_value}'"
export $key=${!default_value}
# echo "export $key='${!def_value}'" >> $SETTINGS_FILE
else
echo "$key='${!key}'"
fi
done