Fixed path.
This commit is contained in:
@@ -31,7 +31,12 @@ runs:
|
|||||||
env:
|
env:
|
||||||
NODE_AUTH_TOKEN: ${{ inputs.apiKey }}
|
NODE_AUTH_TOKEN: ${{ inputs.apiKey }}
|
||||||
run: |
|
run: |
|
||||||
echo "Publishing ${{ inputs.tgz }} to ${{ inputs.registry }}"
|
# Ensure path starts with ./ so npm recognizes it as a file path
|
||||||
npm publish ${{ inputs.tgz }} --registry ${{ inputs.registry }} --access ${{ inputs.access }}
|
TGZ_PATH="${{ inputs.tgz }}"
|
||||||
|
if [[ ! "$TGZ_PATH" =~ ^[./~] ]]; then
|
||||||
|
TGZ_PATH="./$TGZ_PATH"
|
||||||
|
fi
|
||||||
|
echo "Publishing $TGZ_PATH to ${{ inputs.registry }}"
|
||||||
|
npm publish "$TGZ_PATH" --registry ${{ inputs.registry }} --access ${{ inputs.access }}
|
||||||
echo "Package published successfully"
|
echo "Package published successfully"
|
||||||
shell: bash
|
shell: bash
|
||||||
|
|||||||
Reference in New Issue
Block a user