Khan / pull-request-comment-trigger

A github action for detecting a "trigger" in a pull request description or comment
207 stars 91 forks source link

chore: GitHub upgrades and allow arguments #46

Open shanegenschaw opened 1 year ago

shanegenschaw commented 1 year ago

GitHub upgrades

Upgrades for deprecated GitHub Actions functionality:

This PR basically combines the following PRs, but adds a necessary rebuild of the ./dist/index.js file:

Resolves:

Allow arguments

Contribution from @shpingalet007 to allow parsing arguments from the comment body.

Changes

  1. Added GitHub Actions input - allow_arguments: Boolean. It enables/disables arguments parsing. It is set to false by default.
  2. Arguments parsing via double-asterisk marker - script looks for ** in trigger and considers the marked part of the comment as argument. Output to the steps.check.outputs.arguments. It doesn't do anything if allow_arguments: false.
  3. Add new example - add job that enables debugging #deploy on ** environment comment.

Other changes

  • Replace npm @zeit/ncc to @vercel/ncc as it was deprecated.
  • Upload new action NCC build.
  • Documented everything in Readme.md.

Related PRs:

shanegenschaw commented 1 year ago

The updated action is published in the marketplace if anyone wants to use it until this repo gets patched.

shpingalet007 commented 1 year ago

@shanegenschaw would you like to merge my PR #34 in your fork? Mentioned your fork on https://github.com/Khan/pull-request-comment-trigger/pull/34#issuecomment-1563938896

shanegenschaw commented 1 year ago

@shanegenschaw would you like to merge my PR #34 in your fork? Mentioned your fork on #34 (comment)

@shpingalet007 sure I will try to work on this asap

shanegenschaw commented 1 year ago

@shanegenschaw would you like to merge my PR #34 in your fork? Mentioned your fork on #34 (comment)

PR is ready here if you wouldn't mind having a look @shpingalet007 : https://github.com/shanegenschaw/pull-request-comment-trigger/pull/3

shpingalet007 commented 1 year ago

Okay, done @shanegenschaw! Thanks 🤝 Btw, why is this a PR instead of issue?)

shanegenschaw commented 1 year ago

The work from @shpingalet007 has been merged in with this PR and published as v2 and v2.1.0

shpingalet007 commented 1 year ago

@shanegenschaw this PR is duplicate of #34, #36, #37. If there are no reasons to keep it, the work must be proceeded there.