new config helpers: use $() instead of backticks

Co-authored-by: Kayou <pierre@kayou.io>
This commit is contained in:
Alexandre Aubin 2021-09-13 01:55:57 +02:00 committed by GitHub
parent 380321a6eb
commit 968cac32d1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -4,7 +4,7 @@
_ynh_app_config_get() { _ynh_app_config_get() {
# From settings # From settings
local lines local lines
lines=`python3 << EOL lines=$(python3 << EOL
import toml import toml
from collections import OrderedDict from collections import OrderedDict
with open("../config_panel.toml", "r") as f: with open("../config_panel.toml", "r") as f:
@ -24,7 +24,7 @@ for panel_name, panel in loaded_toml.items():
param.get('bind', 'settings' if param.get('type', 'string') != 'file' else 'null') param.get('bind', 'settings' if param.get('type', 'string') != 'file' else 'null')
])) ]))
EOL EOL
` )
for line in $lines for line in $lines
do do
# Split line into short_setting, type and bind # Split line into short_setting, type and bind