Skip to content

Cannot use parent specifiers in the ref #61

Description

@mathstuf

I'd like to run an action on a pull_request and check out the actual content of the PR, not a merge with master (because I want it to run even if there is a merge conflict among other reasons). Support for specifying this has been requested on the community forum.

I've tried the following:

with:
  ref: ${{ github.ref }}^2

Which causes a failure because it tries to do:

 git fetch --tags --prune --progress --no-recurse-submodules origin +refs/heads/*:refs/remotes/origin/* +refs/pull/3/merge^2:refs/remotes/pull/3/merge^2

which is an invalid refspec.

Doing this seems to just get completely ignored:

with:
  ref: ${{ github.sha }}^2

I haven't found a way to use $GITHUB_SHA yet either (it seems to be used literally when in a with block).

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions