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

Fix workflow input wiring for deprecate_release and restore_release workflows #1311

Merged
merged 3 commits into from
Apr 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .github/workflows/deprecate_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,11 @@ jobs:
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

# mapping the inputs to these environment variables allows the @actions/core toolkit to pick up the inputs
INPUT_DEPRECATIONMESSAGE: ${{ inputs.deprecationMessage }}
INPUT_USENPMREGISTRY: ${{ inputs.useNpmRegistry }}
INPUT_SEARCHFORRELEASESTARTINGFROM: ${{ inputs.searchForReleaseStartingFrom }}
steps:
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # version 3.6.0
with:
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/restore_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,10 @@ jobs:
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

# mapping the inputs to these environment variables allows the @actions/core toolkit to pick up the inputs
INPUT_USENPMREGISTRY: ${{ inputs.useNpmRegistry }}
INPUT_SEARCHFORRELEASESTARTINGFROM: ${{ inputs.searchForReleaseStartingFrom }}
steps:
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # version 3.6.0
with:
Expand Down
3 changes: 2 additions & 1 deletion scripts/restore_release.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@ import { DistTagMover } from './components/dist_tag_mover.js';
const searchForReleaseStartingFrom = getInput('searchForReleaseStartingFrom', {
required: true,
});
const useNpmRegistry = getInput('useNpmRegistry', { required: true });
const useNpmRegistry =
getInput('useNpmRegistry', { required: true }) === 'true';

if (useNpmRegistry) {
console.log(
Expand Down
Loading