chore: add tests, update docs and actions (#299)

* docs: update documentation

* feat: validate-inputs has it's own pyproject

* security: mask DOCKERHUB_PASSWORD

* chore: add tokens, checkout, recrete docs, integration tests

* fix: add `statuses: write` permission to pr-lint
This commit is contained in:
2025-10-18 13:09:19 +03:00
committed by GitHub
parent d3c2de1bd1
commit 7061aafd35
148 changed files with 5119 additions and 1897 deletions

View File

@@ -8,12 +8,13 @@ Publishes the package to the NPM registry with configurable scope and registry U
### Inputs
| name | description | required | default |
|-------------------|-------------------------------------|----------|----------------------------------------|
| `registry-url` | <p>Registry URL for publishing.</p> | `false` | `https://registry.npmjs.org/` |
| `scope` | <p>Package scope to use.</p> | `false` | `@ivuorinen` |
| `package-version` | <p>The version to publish.</p> | `false` | `${{ github.event.release.tag_name }}` |
| `npm_token` | <p>NPM token.</p> | `true` | `""` |
| name | description | required | default |
|-------------------|----------------------------------------|----------|----------------------------------------|
| `registry-url` | <p>Registry URL for publishing.</p> | `false` | `https://registry.npmjs.org/` |
| `scope` | <p>Package scope to use.</p> | `false` | `@ivuorinen` |
| `package-version` | <p>The version to publish.</p> | `false` | `${{ github.event.release.tag_name }}` |
| `npm_token` | <p>NPM token.</p> | `true` | `""` |
| `token` | <p>GitHub token for authentication</p> | `false` | `""` |
### Outputs
@@ -55,4 +56,10 @@ This action is a `composite` action.
#
# Required: true
# Default: ""
token:
# GitHub token for authentication
#
# Required: false
# Default: ""
```

View File

@@ -28,6 +28,10 @@ inputs:
description: 'NPM token.'
required: true
default: ''
token:
description: 'GitHub token for authentication'
required: false
default: ''
outputs:
registry-url:
@@ -91,6 +95,11 @@ runs:
exit 1
fi
- name: Checkout Repository
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
token: ${{ inputs.token || github.token }}
- name: Setup Node.js
uses: ./node-setup

View File

@@ -2,7 +2,7 @@
# Validation rules for npm-publish action
# Generated by update-validators.py v1.0.0 - DO NOT EDIT MANUALLY
# Schema version: 1.0
# Coverage: 100% (4/4 inputs)
# Coverage: 100% (5/5 inputs)
#
# This file defines validation rules for the npm-publish GitHub Action.
# Rules are automatically applied by validate-inputs action when this
@@ -19,16 +19,18 @@ optional_inputs:
- package-version
- registry-url
- scope
- token
conventions:
npm_token: github_token
package-version: semantic_version
registry-url: url
scope: scope
token: github_token
overrides:
package-version: strict_semantic_version
statistics:
total_inputs: 4
validated_inputs: 4
total_inputs: 5
validated_inputs: 5
skipped_inputs: 0
coverage_percentage: 100
validation_coverage: 100
@@ -36,7 +38,7 @@ auto_detected: true
manual_review_required: false
quality_indicators:
has_required_inputs: true
has_token_validation: false
has_token_validation: true
has_version_validation: true
has_file_validation: false
has_security_validation: true