I have a GitLab CI pipeline that looks like this:
image: mambaorg/micromamba
stages:
- test
job-name:
stage: test
variables:
GIT_STRATEGY: clone
script:
- ls -l .git
- id
- micromamba install -c conda-forge git
- git config --global --add safe.directory $CI_PROJECT_DIR
- git branch -r
What gets printed out is only origin/name_of_my_branch
and I cannot see e.g. origin/master
.
The first command is there because otherwise, I cannot use git at all directly.
According to the documentation, I would expect to see all remote branches, though - any idea?
My output is the following (filtering only what I am talking about here)
$ ls -l .git total 52
-rw-rw-rw- 1 root root 240 Aug 28 13:27 FETCH_HEAD
-rw-rw-rw- 1 root root 41 Aug 28 13:27 HEAD
-rw-rw-rw- 1 root root 358 Aug 28 13:27 config
-rw-rw-rw- 1 root root 17572 Aug 28 13:27 index drwxrwxrwx 3 root root 4096 Aug 28 13:27 lfs drwxrwxrwx 3 root root 4096 Aug 28 13:27 logs drwxrwxrwx 4 root root 4096 Aug 28 13:27 objects drwxrwxrwx 6 root root 4096 Aug 28 13:27 refs
-rw-rw-rw- 1 root root 492 Aug 28 13:27 shallow $ id uid=57439(mambauser) gid=57439(mambauser) groups=57439(mambauser)
$ git branch -r origin/test_CI