Lerna Publish: Run single job for multiple tags?

hi there :wave:

i’m building a publish pipeline for a JS monorepo managed by lerna. my publish step looks like:

    - name: Publish npm packages
      env:
        NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
      run: |
        npm config set '//registry.npmjs.org/:_authToken' "${NPM_TOKEN}"
        echo ":::: Publishing as $(npm whoami)"
        npm run package:publish # just `lerna publish from-package --yes --no-verify-access` under the hood

the job itself (2nd of two in the workflow - test → publish) uses:

  publish:
    name: Publish
    if: github.event_name == 'push' && contains(github.ref, 'refs/tags/')
    runs-on: ubuntu-latest
    needs: test
    steps:
      # bunch of setup stuff

my issue is that lerna likes to create a single commit with multiple tags - e.g.:

commit xyzpdq1234567890 (tag: @foo/bar@1.3.3, tag: @foo/baz@1.0.3, tag: @foo/qux@1.0.4, origin/main, origin/HEAD, main)

…and this causes my action to create redundant jobs(?) / runs for each tag / event. my aim is to create a single job whenever any tag is pushed that (assuming tests pass) publishes all packages which have changes (something lerna handles itself).

is there a way to configure a job / step to run only once if one or more new tags are pushed?

thanks in advance :pray: