Avoid failure when touching up asset names during release build #4433
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.
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 tocp
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 frompackage/
toreleases/
. 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
tomv
since we don't really need to keep the original name around. All platforms also have decentmv
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