There is a A
project and the A project has a submodule S
A
|-S
|-B
|-C
A repo: git@github.com:benjamin/A.git
S repo: git@github.com:owner/S.git
To contribute some bug fix, I forked the A
repository and cloned it.
$ git clone git@github.com:benjamin/A.git
and then to download a submodule S
I commanded
$ git submodule init
$ git submodule update
Okay, the code tree are made well, and I fixed the bug at a file in A
and a file in S
.
To commit and push the two files,
$ cd S
$ git add modified_file
$ git commit -a -m 'submodule commit'
$ git push
But the push is not work.
ERROR: Permission to owner/S.git denied to benjamin.
fatal: The remote end hung up unexpectedly
Should I also fork S
repository either? How do you do in this case?