creativeprojects / resticprofile

Configuration profiles manager and scheduler for restic backup
https://creativeprojects.github.io/resticprofile/
GNU General Public License v3.0
732 stars 33 forks source link

`group-by` not working #304

Open ghost opened 9 months ago

ghost commented 9 months ago

Using PowerShell 5.1.

# profiles.toml

[default]
repository = 'repo'

[default.env]
RESTIC_PASSWORD = 'password'

[default.forget]
group-by = ''
keep-last = 2
D:\***> resticprofile.exe forget
2024/02/02 13:28:28 using configuration file: profiles.toml
2024/02/02 13:28:28 profile 'default': starting 'forget'
invalid argument "\"\"" for "-g, --group-by" flag: unknown grouping option: "\"\""
2024/02/02 13:28:28 forget on profile 'default': exit status 1

Using group-by = "" in TOML file produces the same output:

D:\***> resticprofile.exe forget
2024/02/02 13:33:44 using configuration file: profiles.toml
2024/02/02 13:33:44 profile 'default': starting 'forget'
invalid argument "\"\"" for "-g, --group-by" flag: unknown grouping option: "\"\""
2024/02/02 13:33:44 forget on profile 'default': exit status 1
resticprofile version
resticprofile version 0.24.0 commit bcfaaa7cacfa7f88a94d5dc62ca69b2d89205d89
creativeprojects commented 9 months ago

Yes it looks like empty string is not recognised by the shell escaper 🤦🏻