File tree Expand file tree Collapse file tree 4 files changed +63
-4
lines changed Expand file tree Collapse file tree 4 files changed +63
-4
lines changed Original file line number Diff line number Diff line change 1+ # This workflow will install Deno then run Deno lint and test.
2+ # For more information see: https://github.com/denoland/setup-deno
3+
4+ name : Release CLI
5+
6+ on :
7+ push :
8+ tags :
9+ - " graphgen-cli-v*"
10+
11+ permissions :
12+ contents : write
13+
14+ jobs :
15+ release :
16+ runs-on : ubuntu-latest
17+
18+ steps :
19+ - name : checkout
20+ uses : actions/checkout@v3
21+
22+ - name : setup deno
23+ # uses: denoland/setup-deno@v1
24+ uses : denoland/setup-deno@004814556e37c54a2f6e31384c9e18e983317366
25+ with :
26+ deno-version : v1.25.x
27+
28+ - name : Get Version
29+ id : vars
30+ run : echo ::set-output name=version::$(echo ${{github.ref_name}} | sed 's/^v//')
31+
32+
33+ - name : Setup Node
34+ uses : actions/setup-node@v2
35+ with :
36+ node-version : 14.x
37+ registry-url : https://registry.npmjs.com
38+
39+ - name : Build
40+ run : deno task build:cli
41+ env :
42+ VERSION : ${{steps.vars.outputs.version}}
43+
44+ - name : Release
45+ uses : softprops/action-gh-release@v1
46+ with :
47+ # note you'll typically need to create a personal access token
48+ # with permissions to create releases in the other repo
49+ token : ${{ secrets.FRONTSIDEJACK_GITHUB_TOKEN }}
50+ files : build/cli/*
51+ fail_on_unmatched_files : true
52+ env :
53+ GITHUB_REPOSITORY : thefrontside/graphgen
Original file line number Diff line number Diff line change 1+ console . log ( "Hello World" ) ;
Original file line number Diff line number Diff line change 11{
22 "tasks" : {
3- "build:npm" : " deno run -A tasks/build-npm.ts"
3+ "build:npm" : " deno run -A tasks/build-npm.ts" ,
4+ "build:cli:windows" : " deno compile -o build/cli/graphgen-x86_64-pc-windows-msvc.exe --target x86_64-pc-windows-msvc --allow-read --allow-net cli/main.ts" ,
5+ "build:cli:linux" : " deno compile -o build/cli/graphgen-x86_64-unknown-linux-gnu --target x86_64-unknown-linux-gnu --allow-read --allow-net cli/main.ts" ,
6+ "build:cli:macos-m1" : " deno compile -o build/cli/graphgen-aarch64-apple-darwin --target aarch64-apple-darwin --allow-read --allow-net cli/main.ts" ,
7+ "build:cli:macos-intel" : " deno compile -o build/cli/graphgen-x86_64-apple-darwin --target x86_64-apple-darwin --allow-read --allow-net cli/main.ts" ,
8+ "build:cli" : " deno task build:cli:windows && deno task build:cli:linux && deno task build:cli:macos-m1 && deno task build:cli:macos-intel"
49 },
510 "lint" : {
611 "rules" : {
Original file line number Diff line number Diff line change @@ -309,11 +309,11 @@ function sizeOf(field: GQLField): Size {
309309 if ( directive ) {
310310 assert ( directive . arguments , "@size must have arguments" ) ;
311311 let meanArg = directive . arguments ?. find ( ( arg ) => arg . name . value === "mean" ) ;
312- let mean = parseInt ( ( meanArg ?. value as graphql . IntValueNode ) . value ?? 5 ) ;
312+ let mean = parseInt ( ( meanArg ?. value as graphql . IntValueNode ) ? .value ?? 5 ) ;
313313 let minArg = directive . arguments ?. find ( ( { name } ) => name . value === "min" ) ;
314- let min = parseInt ( ( minArg ?. value as graphql . IntValueNode ) . value ?? 0 ) ;
314+ let min = parseInt ( ( minArg ?. value as graphql . IntValueNode ) ? .value ?? 0 ) ;
315315 let maxArg = directive . arguments ?. find ( ( { name } ) => name . value === "max" ) ;
316- let max = parseInt ( ( maxArg ?. value as graphql . IntValueNode ) . value ?? 10 ) ;
316+ let max = parseInt ( ( maxArg ?. value as graphql . IntValueNode ) ? .value ?? 10 ) ;
317317 let standardDeviationArg = directive . arguments ?. find ( ( { name } ) =>
318318 name . value === "standardDeviation"
319319 ) ;
You can’t perform that action at this time.
0 commit comments