]> git.ipfire.org Git - thirdparty/snapper.git/commit
Skip placeholder creation when source-config has no snapshots 1132/head
authorAsish Kumar <officialasishkumar@gmail.com>
Thu, 14 May 2026 03:52:20 +0000 (09:22 +0530)
committerAsish Kumar <officialasishkumar@gmail.com>
Mon, 18 May 2026 12:28:28 +0000 (17:58 +0530)
commit05a79e2030f0382815f53a74eed5134f3a0e4c09
tree6f109542294da2b50986b090fffb5cc85f820250
parent4540cdb74f66bdfd43665877e52fa51ea5f2be01
Skip placeholder creation when source-config has no snapshots

scripts/snapper-sync derives the highest snapshot number for each source-config from snbk list and then creates a placeholder named after that number under <subvolume>/.snapshots/. When no snapshots match, jq prints the literal string "null" for the existing max_by query, which previously led to a .snapshots/null directory.

Keep the original jq query unchanged and skip placeholder creation when max_num is "null". Also quote "$outputs" on the line that feeds the JSON list into jq, preserving the existing shellcheck SC2086 fix.

Fixes #1131
scripts/snapper-sync