File tree Expand file tree Collapse file tree 2 files changed +36
-0
lines changed Expand file tree Collapse file tree 2 files changed +36
-0
lines changed Original file line number Diff line number Diff line change
1
+ // @ts -check
2
+ // This will trigger the evergreen build in the react-native-windows repo to update to the latest build of react-native
3
+
4
+ const request = require ( 'request' ) ;
5
+
6
+ const url =
7
+ 'https://api.github.com/repos/microsoft/react-native-windows/dispatches' ;
8
+ request . post (
9
+ {
10
+ url : url ,
11
+ json : true ,
12
+ headers : {
13
+ Authorization : 'Basic ' + new Buffer ( ":" + process . env . GIT_TOKEN ) . toString ( "base64" ) ,
14
+ 'Content-Type' : 'application/json' ,
15
+ 'User-Agent' : 'RNW-Evergreen Script' ,
16
+ Accept : 'application/vnd.github.everest-preview+json' ,
17
+ } ,
18
+ body : {
19
+ event_type : 'evergreen' ,
20
+ } ,
21
+ } ,
22
+ function ( err , httpResponse , _body ) {
23
+ if ( err ) {
24
+ throw new Error ( err ) ;
25
+ }
26
+
27
+ if ( httpResponse . statusCode != 204 ) {
28
+ throw new Error ( 'Failed to trigger build.' ) ;
29
+ }
30
+ } ,
31
+ ) ;
Original file line number Diff line number Diff line change 63
63
- name : Publish NuGet
64
64
run : |
65
65
for %%i in (${{ runner.temp }}\final\*.nupkg) do nuget push %%i -Source ${{ secrets.NUGET_FEED }} -ApiKey msrnpublish
66
+
67
+ - name : Update react-native-windows
68
+ run : node .ado/updateRNW.js
69
+ env :
70
+ GIT_TOKEN : ${{ secrets.GIT_TOKEN }}
You can’t perform that action at this time.
0 commit comments