This repository was archived by the owner on Nov 8, 2022. It is now read-only.
File tree Expand file tree Collapse file tree 9 files changed +50
-92
lines changed Expand file tree Collapse file tree 9 files changed +50
-92
lines changed Original file line number Diff line number Diff line change 11include Makefile.include.mk
22
3+ json_cli :
4+ chmod 755 $(JSON_CLI )
5+
36help :
47 $(call serve.help)
58 $(call gen.help)
1922 npm install # for commitizen
2023
2124# shortcut for serve.local
22- dev :
23- cp config/config.local.json config/config.json
25+ dev : json_cli
26+ $(JSON_CLI ) -s ' .[0] * .[1]' config/config.json config/config.local.json > /tmp/config.json
27+ cp /tmp/config.json ./config/config.json
2428 npm run local
2529
2630build :
2731 npm build
2832
2933build.dev :
30- cp config/config.dev.json config /config.json
34+ $( JSON_CLI ) -s ' .[0] * .[1] ' config/config.json config/config. dev.json > /config.json
3135 npm run build.dev
3236
3337build.prod :
34- cp config/config.prod.json config /config.json
38+ $( JSON_CLI ) -s ' .[0] * .[1] ' config/config.json config/config. prod.json > /config.json
3539 npm run build.prod
3640
3741serve.help :
Original file line number Diff line number Diff line change @@ -27,12 +27,15 @@ GITHUB_APP_LINK = "https://github.com/settings/applications/689577"
2727
2828ifeq ($(OS ) ,Darwin) # Mac OS X
2929 BROWSER_TOOL = open
30+ JSON_CLI=./utils/bin/jq-mac
3031endif
3132ifeq ($(OS ) ,Linux)
3233 BROWSER_TOOL = google-chrome
34+ JSON_CLI=./utils/bin/jq-linux
3335endif
3436ifeq ($(OS ) ,Windows)
3537 BROWSER_TOOL = explorer
38+ JSON_CLI=./utils/bin/jq-win
3639endif
3740
3841define browse
Original file line number Diff line number Diff line change 11{
2- "// endpoint configs //" : " --------------------------------" ,
3- "ASSETS_ENDPOINT" : " https://cps-oss.oss-cn-shanghai.aliyuncs.com" ,
4- "GRAPHQL_ENDPOINT" : " http://localhost:4001/graphiql" ,
5-
6- "// general configs //" : " --------------------------------" ,
7- "DEFAULT_THEME" : " cyan" ,
8- "SENIOR_AMOUNT_THRESHOLD" : 51.2 ,
9- "SPONSOR_AMOUNT_THRESHOLD" : 3999 ,
10- "PAGE_SIZE" : {
11- "S" : 10 ,
12- "D" : 20 ,
13- "M" : 30 ,
14- "L" : 40
15- },
16-
17- "// contact configs //" : " --------------------------------" ,
18- "EMAIL_CLUB" : " club@group.coderplanets.com" ,
19- "EMAIL_SUPPORT" : " support@group.coderplanets.com" ,
20- "EMAIL_HELLO" : " hello@group.coderplanets.com" ,
21- "EMAIL_BUSINESS" : " business@group.coderplanets.com"
2+ "//--- endpoint configs ---//" : " " ,
3+ "GRAPHQL_ENDPOINT" : " http://localhost:4001/graphiql"
224}
Original file line number Diff line number Diff line change 11{
2- "// endpoint configs //" : " --------------------------------" ,
3- "ASSETS_ENDPOINT" : " https://cps-oss.oss-cn-shanghai.aliyuncs.com" ,
4- "GRAPHQL_ENDPOINT" : " https://devapi.coderplanets.com/graphiql" ,
5-
6- "// general configs //" : " --------------------------------" ,
7- "DEFAULT_THEME" : " cyan" ,
8- "SENIOR_AMOUNT_THRESHOLD" : 51.2 ,
9- "SPONSOR_AMOUNT_THRESHOLD" : 3999 ,
10- "PAGE_SIZE" : {
11- "S" : 10 ,
12- "D" : 20 ,
13- "M" : 30 ,
14- "L" : 40
15- },
16-
17- "// contact configs //" : " --------------------------------" ,
18- "EMAIL_CLUB" : " club@group.coderplanets.com" ,
19- "EMAIL_SUPPORT" : " support@group.coderplanets.com" ,
20- "EMAIL_HELLO" : " hello@group.coderplanets.com" ,
21- "EMAIL_BUSINESS" : " business@group.coderplanets.com"
2+ "//--- endpoint configs ---//" : " " ,
3+ "GRAPHQL_ENDPOINT" : " https://devapi.coderplanets.com/graphiql"
224}
Original file line number Diff line number Diff line change 11{
2- "// endpoint configs //" : " -------------------------------- " ,
2+ "//--- endpoint configs --- //" : " " ,
33 "ASSETS_ENDPOINT" : " https://cps-oss.oss-cn-shanghai.aliyuncs.com" ,
44 "GRAPHQL_ENDPOINT" : " https://api.coderplanets.com/graphiql" ,
5- "//GRAPHQL_ENDPOINT" : " http://localhost:4001/graphiql" ,
6-
7- "// general configs //" : " --------------------------------" ,
5+ "//--- general configs ---//" : " " ,
86 "DEFAULT_THEME" : " cyan" ,
97 "SENIOR_AMOUNT_THRESHOLD" : 51.2 ,
108 "SPONSOR_AMOUNT_THRESHOLD" : 3999 ,
1412 "M" : 30 ,
1513 "L" : 40
1614 },
17-
18- "// contact configs //" : " --------------------------------" ,
15+ "//--- contact configs ---//" : " " ,
1916 "EMAIL_CLUB" : " club@group.coderplanets.com" ,
2017 "EMAIL_SUPPORT" : " support@group.coderplanets.com" ,
2118 "EMAIL_HELLO" : " hello@group.coderplanets.com" ,
22- "EMAIL_BUSINESS" : " business@group.coderplanets.com"
19+ "EMAIL_BUSINESS" : " business@group.coderplanets.com" ,
20+ "// GRAPHQL_ENDPOINT" : " http://localhost:4001/graphiql"
2321}
Original file line number Diff line number Diff line change 11{
2- "// endpoint configs //" : " --------------------------------" ,
3- "ASSETS_ENDPOINT" : " https://cps-oss.oss-cn-shanghai.aliyuncs.com" ,
4- "GRAPHQL_ENDPOINT" : " https://api.coderplanets.com/graphiql" ,
5- "//GRAPHQL_ENDPOINT" : " http://localhost:4001/graphiql" ,
6-
7- "// general configs //" : " --------------------------------" ,
8- "DEFAULT_THEME" : " cyan" ,
9- "SENIOR_AMOUNT_THRESHOLD" : 51.2 ,
10- "SPONSOR_AMOUNT_THRESHOLD" : 3999 ,
11- "PAGE_SIZE" : {
12- "S" : 10 ,
13- "D" : 20 ,
14- "M" : 30 ,
15- "L" : 40
16- },
17-
18- "// contact configs //" : " --------------------------------" ,
19- "EMAIL_CLUB" : " club@group.coderplanets.com" ,
20- "EMAIL_SUPPORT" : " support@group.coderplanets.com" ,
21- "EMAIL_HELLO" : " hello@group.coderplanets.com" ,
22- "EMAIL_BUSINESS" : " business@group.coderplanets.com"
2+ "//--- endpoint configs ---//" : " " ,
3+ "// GRAPHQL_ENDPOINT" : " http://localhost:4001/graphiql"
234}
Original file line number Diff line number Diff line change 11{
2- "// endpoint configs //" : " --------------------------------" ,
3- "ASSETS_ENDPOINT" : " https://cps-oss.oss-cn-shanghai.aliyuncs.com" ,
4- "GRAPHQL_ENDPOINT" : " https://api.coderplanets.com/graphiql" ,
5-
6- "// general configs //" : " --------------------------------" ,
7- "DEFAULT_THEME" : " cyan" ,
8- "SENIOR_AMOUNT_THRESHOLD" : 51.2 ,
9- "SPONSOR_AMOUNT_THRESHOLD" : 3999 ,
10- "PAGE_SIZE" : {
11- "S" : 10 ,
12- "D" : 20 ,
13- "M" : 30 ,
14- "L" : 40
15- },
16-
17- "// contact configs //" : " --------------------------------" ,
18- "EMAIL_CLUB" : " club@group.coderplanets.com" ,
19- "EMAIL_SUPPORT" : " support@group.coderplanets.com" ,
20- "EMAIL_HELLO" : " hello@group.coderplanets.com" ,
21- "EMAIL_BUSINESS" : " business@group.coderplanets.com"
2+ "//--- endpoint configs ---//" : " " ,
3+ "GRAPHQL_ENDPOINT" : " https://api.coderplanets.com/graphiql"
224}
Original file line number Diff line number Diff line change 1+ {
2+ "status" : " 1 status" ,
3+ "timestamp" : 1382461861 ,
4+ "value" : {
5+ "aaa" : {
6+ "value3" : " v3" ,
7+ "value4" : 4
8+ },
9+ "bbb" : {
10+ "value3" : " v3"
11+ }
12+ }
13+ }
Original file line number Diff line number Diff line change 1+ {
2+ "status" : " 2 status" ,
3+ "timestamp" : 1382461861 ,
4+ "value" : {
5+ "ccc" : {
6+ "value3" : " v3" ,
7+ "value4" : 4
8+ },
9+ "ddd" : {
10+ "value3" : " v3"
11+ }
12+ }
13+ }
You can’t perform that action at this time.
0 commit comments