0

Is there any way to fetch only meta/project.config from gerrit project, instead of cloning the full source.

I.e. is there a way to fetch the meta/config tag, without cloning the complete source using the git command.

or

need a way to fetch only the meta/config in gerrit, without cloning the complete sources.

I want to change project.config file in gerrit.

Brendan Darrer
  • 379
  • 3
  • 12
tej anil
  • 9
  • 3
  • Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking. – Community Aug 05 '23 at 14:14

1 Answers1

0

here is the command:

mkdir myproject
cd myproject
git init .
git remote add origin ssh://gerritserver:29418/projectname
git fetch origin refs/meta/config
git checkout FETCH_HEAD -b meta/config

after modify and commit, you should do push as below:

git push origin HEAD:refs/meta/config

By the way, gerrit support to create repository that "Only serve as parent for other repositories", you shall create this type repository, and then create code repositories inherit from it.

Good luck.

Tycho Chen
  • 11
  • 1