[FEATURE] Always copy
Is your feature request related to a problem? Please describe.
It would be nice to be able to just always copy the files instead of symlinking.
Describe the solution you'd like
I think that with dotter's current architecture, the most sensible parameter would be a --copy command-line flag
Describe alternatives you've considered
A technically working (well, not even, see #77) solution would be to add the "template" type to all files. It goes without saying this is not a viable solution.
Could you tell more about the use case?
I think this is a basic feature and I don't know if the use case is relevant but sure!
Well in my case it has to do with #77; I have files to put in root directories (sddm config), and symlinking it to a user directory is a bit odd. As mentionned I don't want to add the template type to the file, I'd like to keep the config simple.
Plus, I just don't like having a mix of symlinks and copies on my system, I'd rather just copy all files.
Another use case for this feature would be for people on Windows. While Windows (through Developer Mode) does support symbolic links, these are not well supported by other applications. Most notably here is One Drive which simply hangs indefinitely when it encounters a symbolic link.
I noticed that there's already logic to switch to copy-only mode if symbolic links are disabled:
https://github.com/SuperCuber/dotter/blob/1e649ab8f2cd4103d81e3cbf367cd599ae71e5d1/src/deploy.rs#L66-L78
Would be it possible to leverage that with a --copy command line parameter, or the ability to customise a windows.toml file so that all files are copied over?
Yes that would work. However there are two problems left:
- It's probably annoying to specify
--copyeach time, so it would be better to specify it inlocal.tomlor an include. Maybe a new section for[settings] - If you have non utf8 files then they cannot be templated. The "copy target type" feature would solve that, but I don't have the bandwidth to add it
I agree that using --copy all the time would be annoying.
I note there already are ways of having OS-specific configuration which get imported as part of the local.toml definition. I think using this so that on Windows I can have copy = True would be already great.
To me, both would do the job