You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was wondering if this concept is possible with ast-grep as there arent many example with Github Action. I was kind of able to detect the run with
rule:
pattern: |
run: $RUN
but the concept of changing the code with new line doesnt seem to be present much. Was wondering if the expect think it is flasible, I can current testing it with tree-sitter but because of so many variable interpolation from shell it is a bit of a tricky as well so ast-grep is built on it I dont know if it is able to determine it easily.
name: Say Hello
run: echo "Hello ${{ inputs.name }}"
name: Example step
env:
NAME: ${{ inputs.name }} # <- Assign the expression to an environment variable
run: |
echo "Hello $NAME"
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
I was wondering if this concept is possible with ast-grep as there arent many example with Github Action. I was kind of able to detect the run with
rule:
pattern: |
run: $RUN
but the concept of changing the code with new line doesnt seem to be present much. Was wondering if the expect think it is flasible, I can current testing it with tree-sitter but because of so many variable interpolation from shell it is a bit of a tricky as well so ast-grep is built on it I dont know if it is able to determine it easily.
name: Say Hello
run: echo "Hello ${{ inputs.name }}"
name: Example step
env:
NAME: ${{ inputs.name }} # <- Assign the expression to an environment variable
run: |
echo "Hello $NAME"
Beta Was this translation helpful? Give feedback.
All reactions