Submodules and ci.skip vs [ci skip]

We have a repository containing submodules. A Gitlab-CI job that auto commits to master when a submodule is updated is configured on this repository like so:

script:
    - DIFFS=$(git diff)
    - DIRTY=$(git diff | { grep "dirty" || true; })
    - if [ "$DIRTY" != "" ]; then echo "ERROR, DIRTY COMMITS"; exit 1; fi # this should never happen
    - if [ "$DIFFS" != "" ]; then git add .; git commit -m '[AUTO] Submodules Updated'; git push -o ci.skip; fi
  rules:
    - if: '$CI_COMMIT_REF_NAME == "master"'

As I understand it a commit pipeline skipped with “ci skip” will cause all pipelines for that commit to be skipped but we are seeing the first commit is skipped as expected but subsequent pipelines for that commit are triggered.

Is there any difference in the behaviour of the git push option git push -o ci.skip and the commit message version git commit -m "[ci skip]"?

Can anyone shed light on why these second pipelines are triggered despite the prescence of the “ci.skip” option?

  • What version are you on? Are you using self-managed or GitLab.com?

Cheers.