Project

General

Profile

SourceCodeRepositories » History » Version 5

Joonas Kylmälä, 09/26/2018 09:02 PM
Add instructions how to add new repository

1 1 Wolfgang Wiedmeyer
h1. LineageOS Mirror
2
3
h2. Initial setup
4
5
Initialize the repository and sync:
6
<pre>
7
mkdir lineage_mirror
8
cd lineage_mirror
9
repo init -u https://git.replicant.us/replicant/manifest.git -b LineageOS-mirror
10
repo sync
11
</pre>
12
13
h2. Updating
14
15
# Check the LineageOS manifest for newly added repos
16 3 Wolfgang Wiedmeyer
# If there are any, add them in the LineageOS-mirror manifest and push the changes to git.replicant.us
17
# If there are any, create the newly added repos in the LineageOS-mirror group (using the exact same names the repos have in LineageOS)
18 5 Joonas Kylmälä
<pre>
19
sudo -iu git
20
mkdir repositories/LineageOS-mirror/<repo-name>.git
21
cd repositories/LineageOS-mirror/<repo-name>.git
22
git --bare init
23
touch git-daemon-export-ok
24
</pre>
25 1 Wolfgang Wiedmeyer
# Update the local mirror with @repo sync@
26 3 Wolfgang Wiedmeyer
# If there are newly added repos, you need to manually push them the first time in order to create the branch on the remote:
27
<pre>
28
cd path/to/new/repo
29
git push git@git.replicant.us:LineageOS-mirror/REPO_NAME HEAD:refs/heads/cm-13.0
30
</pre>
31 4 Wolfgang Wiedmeyer
32 3 Wolfgang Wiedmeyer
  Repeat these steps for all newly added repos.
33 1 Wolfgang Wiedmeyer
# Push the updated branches to git.replicant.us:
34 2 Wolfgang Wiedmeyer
<pre>
35
repo forall -c ' echo "Pushing $REPO_PROJECT"; git push git@git.replicant.us:LineageOS-mirror/$( echo $REPO_PROJECT | cut -c11- ).git HEAD:cm-13.0 '
36 1 Wolfgang Wiedmeyer
</pre>
37 4 Wolfgang Wiedmeyer
  Check for errors during the push and fix them!
38 1 Wolfgang Wiedmeyer
39
h2. Notes
40
41
h3. Bundles
42
43
It's worth to check if all mirror repos have bundles in place.
44
45
h3. CAF variants
46
47
If we ever add support for a device that uses CAF branches of Qualcomm repos, we need to figure out how the mirror can still be updated and how releases can be tagged.
48
49
CAF branches are in the same repos as the default branches. So two or more local repos are created for one remote repo when the default branch and the CAF branches are checked out. The current setup for tagging a new release and updating the mirror assumes that there is one local repo for one remote repo.