Repository navigation
Commit d4e34d2
committed
Sync all repositories in a single parallel pass
`composer install` and `composer update` run clone-all-repositories.sh,
which cloned missing repositories in one parallel pass and then refreshed
every repository in a second one. The barrier between the two stages left
cores idle: the refresh pass could not start until the slowest clone
finished, and on a fresh checkout the whole refresh pass was wasted work
because a freshly cloned repository is already up to date.
sync-repository.sh collapses both stages into one task per repository:
clone when the folder is missing, refresh when it is not. That lets the
script run a single continuous parallel pass that keeps every slot busy
until the last repository is done.
The pass now renders through peek.php, so each repository gets its own
line showing what it is doing and how long it has taken, instead of ~90
repositories interleaving their git output into one stream.
Running behind that display means an interactive prompt would be
overdrawn the moment it appeared and would hang the run waiting for input
nobody can see. Git and ssh prompt on /dev/tty rather than stdin, so
prompting is disabled outright and failures surface as visible errors in
the job's own lane instead:
- GIT_TERMINAL_PROMPT=0 stops git asking for credentials.
- BatchMode=yes makes ssh fail instead of asking for a passphrase or host
key confirmation; keys served by an ssh-agent keep working. It is only
applied when GIT_SSH_COMMAND is not already customized.
- GIT_MERGE_AUTOEDIT=no keeps a non-fast-forward pull from opening an
editor.1 parent 18bb9eb commit d4e34d2
2 files changed
Lines changed: 64 additions & 16 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
6 | 29 | | |
7 | 30 | | |
8 | 31 | | |
| |||
80 | 103 | | |
81 | 104 | | |
82 | 105 | | |
83 | | - | |
84 | | - | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
85 | 111 | | |
86 | 112 | | |
87 | 113 | | |
| |||
90 | 116 | | |
91 | 117 | | |
92 | 118 | | |
93 | | - | |
94 | | - | |
95 | | - | |
96 | | - | |
97 | | - | |
98 | | - | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
99 | 123 | | |
100 | | - | |
101 | | - | |
102 | 124 | | |
103 | 125 | | |
104 | | - | |
105 | | - | |
106 | | - | |
107 | | - | |
108 | | - | |
109 | | - | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
110 | 129 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
0 commit comments