-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Description
I've been working on Actions CI that leverages both actions/checkout
and Jest for tests.
I am specifically using Jest's changedSince
flag, which compares the current branch with the passed branch and limits the tests it is running to only those that are associated with the files changed. This is particularly useful for only running the relevant tests when compared against master
in a PR.
It would significantly reduce the necessary work for users if there was a way to include multiple branches in the run through a simple YAML property. At present, I need to do this:
steps:
- uses: actions/checkout@v2
- run: |
git fetch --no-tags --depth=1 origin master
git checkout -b master
git checkout ${{ github.event.pull_request.head.sha }}
something like the following would be amazingly useful, where checkout
is an array of branches to checkout on every run while still keeping the PR's branch as the currently checked out branch:
steps:
- uses: actions/checkout@v2
checkout: ['master']
checkout
may not be the most appropriate name, but the idea is more of what I'm going for here ❤️