Skip to content

Commit 25b1b72

Browse files
authored
Merge branch 'main' into feat/prioritize-view-attribute-process-function
2 parents ca657bf + bb9a24d commit 25b1b72

File tree

1,229 files changed

+1648
-223852
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,229 files changed

+1648
-223852
lines changed

.github/workflows/compiler_rust.yml

Lines changed: 0 additions & 77 deletions
This file was deleted.

.github/workflows/shared_check_maintainer.yml

Lines changed: 34 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,10 @@ on:
66
actor:
77
required: true
88
type: string
9+
is_remote:
10+
required: false
11+
type: boolean
12+
default: false
913
outputs:
1014
is_core_team:
1115
value: ${{ jobs.check_maintainer.outputs.is_core_team }}
@@ -29,8 +33,36 @@ jobs:
2933
script: |
3034
const fs = require('fs');
3135
const actor = '${{ inputs.actor }}';
32-
const data = await fs.readFileSync('./MAINTAINERS', { encoding: 'utf8' });
33-
const maintainers = new Set(data.split('\n'));
36+
let isRemote = ${{ inputs.is_remote }};
37+
if (typeof isRemote === 'string') {
38+
isRemote = isRemote === 'true';
39+
}
40+
if (typeof isRemote !== 'boolean') {
41+
throw new Error(`Invalid \`isRemote\` input. Expected a boolean, got: ${isRemote}`);
42+
}
43+
44+
let content = null;
45+
if (isRemote === true) {
46+
const res = await github.rest.repos.getContent({
47+
owner: 'facebook',
48+
repo: 'react',
49+
path: 'MAINTAINERS',
50+
ref: 'main',
51+
headers: { Accept: 'application/vnd.github+json' }
52+
});
53+
if (res.status !== 200) {
54+
console.error(res);
55+
throw new Error('Unable to fetch MAINTAINERS file');
56+
}
57+
content = Buffer.from(res.data.content, 'base64').toString();
58+
} else {
59+
content = await fs.readFileSync('./MAINTAINERS', { encoding: 'utf8' });
60+
}
61+
if (content === null) {
62+
throw new Error('Unable to retrieve local or http MAINTAINERS file');
63+
}
64+
65+
const maintainers = new Set(content.split('\n'));
3466
if (maintainers.has(actor)) {
3567
console.log(`🟢 ${actor} is a maintainer`);
3668
return true;

MAINTAINERS

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,24 +2,21 @@ acdlite
22
eps1lon
33
gaearon
44
gnoff
5-
gsathya
5+
unstubbable
66
hoxyq
77
jackpope
88
jbonta
99
jbrown215
1010
josephsavona
1111
kassens
12-
lunaleaps
1312
mattcarrollcode
1413
mofeiZ
1514
mvitousek
16-
noahlemen
1715
pieterv
1816
poteto
1917
rickhanlonii
2018
sebmarkbage
2119
sethwebster
2220
sophiebits
23-
TheSavior
24-
tyao1
21+
elicwhite
2522
yuzhi

0 commit comments

Comments
 (0)