ansible: Add mirror Ubuntu noble kernel sources to git-mirror
[lttng-ci.git] / automation / ansible / roles / gitmirror / files / update.sh
CommitLineData
09bc9215
KS
1#!/usr/bin/env bash
2
3set -eu
4
5# sudo -u gitdaemon git clone --mirror git://git.kernel.org/pub/scm/linux/kernel/git/rt/linux-rt-devel.git
6
7update_git() {
8 local repodir="$1"
9 local origin="$2"
10
11 if [ ! -d "${repodir}" ] ; then
c16adb7d 12 git clone --mirror "${origin}" "${repodir}"
09bc9215
KS
13 fi
14
15 pushd "$repodir"
16
17 git remote update
18 #git gc
19 mkdir -p info/web
20 git for-each-ref --sort=-committerdate --format='%(committerdate:iso8601)' --count=1 >info/web/last-modified
21
22 popd
23}
24
25##
26# Vanilla composite repo
27##
28
29update_git linux-all.git/ https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
30
31pushd linux-all.git/
32## Add stable if needed
33if ! git remote | grep -q stable ; then
34 git remote add stable https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
35 git fetch stable
36fi
37## Delete broken tree tags
38git tag -d v2.6.11 || true
39git tag -d v2.6.11-tree || true
40popd
41
42##
43# Ubuntu kernels
44##
45
09bc9215
KS
46update_git ubuntu-focal.git/ git://git.launchpad.net/~ubuntu-kernel/ubuntu/+source/linux/+git/focal
47
48update_git ubuntu-jammy.git/ git://git.launchpad.net/~ubuntu-kernel/ubuntu/+source/linux/+git/jammy
49
97ec8412
KS
50update_git ubuntu-noble.git/ git://git.launchpad.net/~ubuntu-kernel/ubuntu/+source/linux/+git/noble
51
09bc9215
KS
52##
53# GDB repos
54##
55
56update_git binutils-gdb.git/ git://sourceware.org/git/binutils-gdb.git
This page took 0.024653 seconds and 4 git commands to generate.