Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

submodule files are not available for pipeline after git submodule update executed successfully


Hello, community!


In a nutshell i have a following test pipeline that drives me crazy:

image: atlassian/default-image:2

- step:
name: 'Init submodule'
- git submodule update --init --recursive
- git submodule status
- step:
name: 'Do something with submodule'
- ls test-lib -al
- step:
name: 'do just clone'
- git clone
- ls submobule-test-lib/*

 What im facing is that first step is executed correctly and has an output like:

+ git submodule update --init --recursive
Submodule 'test-lib' ( registered for path 'test-lib'

Cloning into 'test-lib'...

Warning: Permanently added the RSA host key for IP address '' to the list of known hosts.

Submodule path 'test-lib': checked out '15755730500ea84a78ef065621ed899f550df6cb'

The commit hash is valid and submodule has some files pushed on it..

But the 2nd step returns empty list of files.

At the same time if i do just a git clone of the same submodule repo (at step 3) it works just fine.  My assumption is that all ssh keys and repo access are just fine.. the problem happens with submodule file tree only.

Am i doing something wrong? Does anyone faced something similar?


Update: actually this is how steps are defined in bitbucket pipelines. Submodules are not fetched automatically for each step. My bad =(

0 answers

Suggest an answer

Log in or Sign up to answer
Community showcase
Published in Bitbucket

New improvements to user management in Bitbucket Cloud 👥

Hey Community! We’re willing to wager that quite a few of you not only use Bitbucket, but administer it too. Our team is excited to share that we’ll be releasing improvements throughout this month of...

3,826 views 10 16
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you