Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Avoid failure when touching up asset names during release build #4433

Merged
merged 1 commit into from
Nov 19, 2023

Conversation

kwvanderlinde
Copy link
Collaborator

@kwvanderlinde kwvanderlinde commented Nov 19, 2023

Identify the Bug or Feature request

Fixes #4432

Description of the Change

jpackage now allows the release sufficx on DEB files to be optional. Since we don't use them, our produced .deb file does not have a release suffix. This makes the name of the generated file identical to the final name we want it to have. Later in the build, when we attempt to cp the file to its final location we get an error since the source and target are the same file. This error prevents subsequent commands from running, in this case, the copying of the .zst file from package/ to releases/. Investigation reveals the same happened on Windows and Mac OS, but we get lucky because all of their packages are already named correctly in the expected location, so the problem happens to not have negative effects there.

This PR changes the use of cp to mv since we don't really need to keep the original name around. All platforms also have decent mv behaviour when the source and target files are the same, though Linux does require an extra flag to exit without error.

Possible Drawbacks

Should be none.

Documentation Notes

N/A

Release Notes

N/A


This change is Reviewable

Instead of `cp`, using `mv` has some nicer behaviour on Windows and Mac OS, while also being decent on Linux too.
@cwisniew cwisniew merged commit 6c24410 into RPTools:release-1.14 Nov 19, 2023
4 checks passed
@kwvanderlinde kwvanderlinde deleted the bugfix/fix-zst-build branch November 19, 2023 11:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants