1
0
Fork 0
gitea/contrib
wxiaoguang d0a9456c4f
Make environment-to-ini work with INSTALL_LOCK=true (#25926)
Regression of #25648, fix #25924

Test:

```bash
rm -f /tmp/example.ini /tmp/out.ini && \
echo "[security]" > /tmp/example.ini && \
echo "INSTALL_LOCK = true" >> /tmp/example.ini && \
GITEA__foo__bar=1 go run contrib/environment-to-ini/environment-to-ini.go --config=/tmp/example.ini --out=/tmp/out.ini && \
echo "==== example:" && \
cat /tmp/example.ini && \
echo "==== out:" && \
cat /tmp/out.ini
```

Output:

```
2023/07/17 17:40:51 ...nvironment-to-ini.go:99:runEnvironmentToIni() [I] Settings saved to: "/tmp/out.ini"
==== example:
[security]
INSTALL_LOCK = true
==== out:
[security]
INSTALL_LOCK = true

[foo]
bar = 1

```
2023-07-17 17:56:06 +00:00
..
autocompletion
backport
environment-to-ini Make environment-to-ini work with INSTALL_LOCK=true (#25926) 2023-07-17 17:56:06 +00:00
fhs-compliant-script
fixtures
gitea-monitoring-mixin
ide
init
launchd
legal
options/label
supervisor
systemd
README
update_dependencies.sh
upgrade.sh

README

All files in subdirectories are templates, do modifications based on your environment first.