Replace find / cp with rsync
Resolves #2
rsync is more capable than the current approach of looping over find results and cp-ing files over. With this change, all files — not just ones ending in .md — are copied, and any existing files that aren't present in the specified path input are deleted.
It's unclear to me how the behavior of rsync would best be configured through the action interface. Among the options currently being considered:
- Conditionalizing the presence of only the
--deleteflag with adeleteinput argument. - Allowing the user pass arbitrary options through an
rsync_optionsinput argument.
Shouldn't docker install rsync (by just appending rsync to RUN apk add --no-cache bash findutils) for this to work?
I used that rsync branch for a project of mine, and it works smoothly.
The only problem I had is linked to the June comments: I expected that giving path: docs would synchronize the contents of docs with the contents of the equivalent directory in the wiki repo, but instead I had to make it path: docs/ for it to work.
Great job nonethless, that's a small but useful tool, tahnks for the great job :)
Thanks, this branch works for me as well, see https://github.com/FH-Inway/d365fo.tools/runs/3736161296?check_suite_focus=true for a sample run. This allows us to also publish our wiki images.
Kudos to @Morwenn for pointing out the path: docs/ detail 👍