Skip to content

Use .local/state/syncthing#17

Merged
serl merged 2 commits intoserl:masterfrom
sstark:use-localstate
Aug 17, 2025
Merged

Use .local/state/syncthing#17
serl merged 2 commits intoserl:masterfrom
sstark:use-localstate

Conversation

@sstark
Copy link
Copy Markdown
Contributor

@sstark sstark commented Aug 14, 2025

If SYNCTHING_CONFIG_FILE is not set and default config not found, look for config.xml in localstate directory:

SYNCTHING_DEFAULT_STATEDIR="$HOME/.local/state/syncthing"

At least in my environment (manjaro linux) this is where a working config.xml is located by default.

sstark and others added 2 commits August 14, 2025 17:21
If SYNCTHING_CONFIG_FILE is not set and default config not found, look
for config.xml in localstate directory:

    SYNCTHING_DEFAULT_STATEDIR="$HOME/.local/state/syncthing"

At least in my environment (manjaro linux) this is where a working
config.xml is located by default.
Copy link
Copy Markdown
Owner

@serl serl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hello, thanks for your contribution!

I did a little edit to make sure that SYNCTHING_DEFAULT_CONFIG_FILE is never empty, as that might happen with your diff.

I mean, for sure if no config file exist this would break, but I'm willing not to change how it breaks :trollface:

Anyways, if you could try if it still works as expected with my edit, that would be fantastic 🙂

Thanks again!

@sstark
Copy link
Copy Markdown
Contributor Author

sstark commented Aug 16, 2025

Still works for me as expected, thanks! And it's cleaner without an extra variable $SYNCTHING_DEFAULT_STATEDIR

@serl
Copy link
Copy Markdown
Owner

serl commented Aug 17, 2025

Perfect, thanks!

@serl serl merged commit 1966ac6 into serl:master Aug 17, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants