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

Update the secure workflow example, remove extra quotes #70

Merged
merged 2 commits into from
Jan 30, 2024

Conversation

oleg-derevenetz
Copy link
Contributor

To work with values from an untrusted source, it is still better to use github-script instead of bash with all its substitution rules.

@@ -19,7 +19,7 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "${{ env.PYTHON_VERSION }}"
python-version: ${{ env.PYTHON_VERSION }}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See discussion at #66 (comment).

core.exportVariable(varName, val);
}
exportVar("PR_ID", "pr-id.txt", /^[0-9]+$/);
exportVar("PR_HEAD_REPO", "pr-head-repo.txt", /^[-./0-9A-Z_a-z]+$/);
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@platisd platisd merged commit c24cf38 into platisd:master Jan 30, 2024
3 checks passed
@oleg-derevenetz oleg-derevenetz deleted the example-update branch January 30, 2024 16:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants