Support relative paths with and without specified filenames #56
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.
Specifying the output directory was not working as expected, as discussed in #34. e.g. "
wp dist-archive . ./scratch/build.zip --create-target-dirsucceeds but the file is not placed in the subdirectory of., rather it's at../scratch/build.zip"Without a specified path or filename, the default output folder is the plugin's parent directory with the generated (versioned) filename.
Without a specified path, the default output folder is the plugin's parent directory with the specified filename.
With a specified path and filename, the archive is saved to that path and filename.
With a specified path and no filename, the archive is saved to that path with the generated (versioned) filename.
Tests added for:
wp dist-archive . hello-world.zip– output filename, no pathwp dist-archive . ./hello-world.zip– output filename, with.for pathwp dist-archive wp-content/plugins/hello-world wp-content– relative output path, no filenamewp dist-archive wp-content/plugins/hello-world ./subdir/hello-world.zip– relative output path, with filenamewp dist-archive . {RUN_DIR}/hello-world.zip– using.as input and absolute output path, with filenamewp dist-archive wp-content/plugins/hello-world .– using.as output path, no filenameNo documentation changed.
Fixes #34