summaryrefslogtreecommitdiffstats
path: root/modules/assetfs
diff options
context:
space:
mode:
authorwxiaoguang <wxiaoguang@gmail.com>2023-07-10 19:51:05 +0800
committerGitHub <noreply@github.com>2023-07-10 11:51:05 +0000
commitb4460cf54147e22c3f0657fbfdb680aec52a0210 (patch)
treef084a8858ab91ef29058c9fe67ce7bd710c5a065 /modules/assetfs
parenta1bc2aa05ef67eecce355f237b165567ef6e07e2 (diff)
downloadgitea-b4460cf54147e22c3f0657fbfdb680aec52a0210.tar.gz
gitea-b4460cf54147e22c3f0657fbfdb680aec52a0210.zip
Make "install page" respect environment config (#25648) (#25799)
Backport #25648 Replace #25580 Fix #19453 The problem was: when users set "GITEA__XXX__YYY" , the "install page" doesn't respect it. So, to make the result consistent and avoid surprising end users, now the "install page" also writes the environment variables to the config file. And, to make things clear, there are enough messages on the UI to tell users what will happen. There are some necessary/related changes to `environment-to-ini.go`: * The "--clear" flag is removed and it was incorrectly written there. The "clear" operation should be done if INSTALL_LOCK=true * The "--prefix" flag is removed because it's never used, never documented and it only causes inconsistent behavior. The only conflict during backport is "ui divider" in templates/install.tmpl
Diffstat (limited to 'modules/assetfs')
-rw-r--r--modules/assetfs/layered.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/modules/assetfs/layered.go b/modules/assetfs/layered.go
index d032160a6f..e18a13e4aa 100644
--- a/modules/assetfs/layered.go
+++ b/modules/assetfs/layered.go
@@ -215,6 +215,7 @@ func (l *LayeredFS) WatchLocalChanges(ctx context.Context, callback func()) {
log.Error("Unable to list directories for asset local file-system %q: %v", layer.localPath, err)
continue
}
+ layerDirs = append(layerDirs, ".")
for _, dir := range layerDirs {
if err = watcher.Add(util.FilePathJoinAbs(layer.localPath, dir)); err != nil {
log.Error("Unable to watch directory %s: %v", dir, err)