We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 0358a93 + 15cce48 commit 7fa105eCopy full SHA for 7fa105e
1 file changed
.maintenance/clone-all-repositories.php
@@ -11,6 +11,10 @@
11
'wp-cli-roadmap',
12
);
13
14
+$clone_destination_map = array(
15
+ '.github' => 'dot-github',
16
+);
17
+
18
$request = 'https://api.github.com/orgs/wp-cli/repos?per_page=100';
19
$headers = '';
20
$token = getenv( 'GITHUB_TOKEN' );
@@ -37,9 +41,10 @@
37
41
}
38
42
39
43
if ( ! is_dir( $repository->name ) ) {
44
+ $destination = isset( $clone_destination_map[ $repository->name ] ) ? $clone_destination_map[ $repository->name ] : '';
40
45
printf( "Fetching \033[32mwp-cli/{$repository->name}\033[0m...\n" );
46
$clone_url = getenv( 'GITHUB_ACTION' ) ? $repository->clone_url : $repository->ssh_url;
- system( "git clone {$clone_url}" );
47
+ system( "git clone {$clone_url} {$destination}" );
48
49
50
$update_folders[] = $repository->name;
0 commit comments