allow nested paths in target-folder
+ add attempt-limit
parameter
#1737
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
--mkpath
flag to the rsync command to allow it to make missing directories. This is useful when many different pages are being deployed, so a deeply nested descriptive path can be specified intarget-folder
. Right now, doing so leads to an error in rsync complaining about missing directories.attempt-limit
parameter to allow more rebase/push attempts than the default of 3. This is useful when many different actions are racing to deploy many different pages.Testing
I built this code (databasedav@ec82a36) and used it (https://github.com/databasedav/haalka/blob/18a199464edc9cf3eb3e04989b30893f970097f0/.github/workflows/preview_deploy.yaml#L21) in this PR databasedav/haalka#6. Note that the
target-folder
is a deeply nested path https://github.com/databasedav/haalka/pull/6/files#diff-05da7bfe214f8a02b4727e2f5970ac5b86684f522864a6917da71a3efa04ba13R27 and pushing is attempted more than 3 times https://github.com/databasedav/haalka/actions/runs/11870171025/job/33082157315#step:5:257.One can see a deployed page here https://databasedav.github.io/haalka/pr_previews/6/webgpu/button/, note it requires a webgpu compatible browser (e.g. chrome, firefox nightly, not firefox stable) to work.