Skip to content

Commit 886af36

Browse files
committed
chore: packegae.jsonを分離
1 parent fbde30e commit 886af36

File tree

9 files changed

+3999
-507
lines changed

9 files changed

+3999
-507
lines changed

.github/workflows/github-actions.yaml

+11-4
Original file line numberDiff line numberDiff line change
@@ -28,12 +28,16 @@ jobs:
2828
restore-keys: ${{ runner.os }}-yarn-
2929

3030
- run: yarn install
31+
working-directory: ./app
3132

32-
- run: yarn app:type-check
33+
- run: yarn type-check
34+
working-directory: ./app
3335

34-
- run: yarn app:lint
36+
- run: yarn lint
37+
working-directory: ./app
3538

3639
- run: yarn app:build
40+
working-directory: ./app
3741
env:
3842
FIREBASE_API_KEY: ${{ secrets.FIREBASE_API_KEY }}
3943
FIREBASE_AUTH_DOMAIN: ${{ secrets.FIREBASE_AUTH_DOMAIN }}
@@ -71,7 +75,10 @@ jobs:
7175
restore-keys: ${{ runner.os }}-yarn-
7276

7377
- run: yarn install
78+
working-directory: ./functions
7479

75-
- run: yarn functions:lint
80+
- run: yarn lint
81+
working-directory: ./functions
7682

77-
- run: yarn functions:build
83+
- run: yarn build
84+
working-directory: ./functions

.eslintrc.json app/.eslintrc.json

File renamed without changes.

Dockerfile app/Dockerfile

File renamed without changes.

package.json app/package.json

+7-18
Original file line numberDiff line numberDiff line change
@@ -2,39 +2,28 @@
22
"name": "commitly-next-web",
33
"version": "1.0.0",
44
"scripts": {
5-
"app:dev": "next dev app/",
6-
"app:build": "next build app/",
7-
"app:start": "next start app/",
8-
"app:type-check": "tsc -p app/tsconfig.json --noEmit",
9-
"app:lint": "eslint app",
10-
"functions:build": "tsc -p functions/tsconfig.json",
11-
"functions:serve": "yarn functions:build && firebase emulators:start --only functions",
12-
"functions:shell": "yarn functions:build && firebase functions:shell",
13-
"functions:start": "yarn shell",
14-
"functions:deploy": "firebase deploy --only functions",
15-
"functions:logs": "firebase functions:log",
16-
"functions:lint": "eslint functions",
5+
"dev": "next dev",
6+
"build": "next build",
7+
"start": "next start",
8+
"type-check": "tsc --noEmit",
9+
"lint": "eslint .",
1710
"lint:fix": "yarn lint --fix"
1811
},
1912
"dependencies": {
2013
"@emotion/babel-preset-css-prop": "10.0.27",
2114
"@emotion/core": "10.0.28",
22-
"@google-cloud/pubsub": "2.3.0",
23-
"axios": "0.19.2",
2415
"dayjs": "1.8.31",
2516
"dotenv": "8.2.0",
2617
"firebase": "7.17.1",
2718
"firebase-admin": "8.13.0",
2819
"firebase-functions": "3.8.0",
2920
"immer": "7.0.7",
30-
"jsonwebtoken": "8.5.1",
3121
"next": "9.5.1",
3222
"react": "16.13.1",
3323
"react-dom": "16.13.1",
3424
"react-semantic-toasts": "0.6.5",
3525
"semantic-ui-css": "2.4.1",
36-
"semantic-ui-react": "1.1.0",
37-
"twitter": "1.7.1"
26+
"semantic-ui-react": "1.1.0"
3827
},
3928
"devDependencies": {
4029
"@types/node": "14.0.27",
@@ -54,7 +43,7 @@
5443
"typescript": "3.9.7"
5544
},
5645
"engines": {
57-
"node": "12"
46+
"node": "12.x"
5847
},
5948
"license": "MIT"
6049
}

yarn.lock app/yarn.lock

+80-483
Large diffs are not rendered by default.

docker-compose.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@ version: "3"
22
services:
33
app:
44
build:
5-
context: .
5+
context: ./app
66
tty: true
77
ports:
88
- "3000:3000"
99
volumes:
10-
- .:/app
10+
- ./app:/app
1111
- /app/node_modules

functions/.eslintrc.json

+41
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
{
2+
"extends": [
3+
"eslint:recommended",
4+
"plugin:@typescript-eslint/recommended",
5+
"prettier/@typescript-eslint",
6+
"plugin:prettier/recommended",
7+
"plugin:import/errors",
8+
"plugin:import/warnings",
9+
"plugin:import/typescript"
10+
],
11+
"plugins": ["@typescript-eslint", "prettier"],
12+
"env": {
13+
"node": true,
14+
"browser": true,
15+
"jest": true,
16+
"es6": true
17+
},
18+
"rules": {
19+
"@typescript-eslint/no-unused-vars": ["warn", { "args": "none" }],
20+
"@typescript-eslint/explicit-function-return-type": ["off"],
21+
"@typescript-eslint/explicit-module-boundary-types": ["off"],
22+
"sort-imports": ["error", { "ignoreDeclarationSort": true }],
23+
"import/order": ["error", { "newlines-between": "always" }],
24+
"prettier/prettier": [
25+
"error",
26+
{
27+
"semi": true,
28+
"printWidth": 120,
29+
"trailingComma": "all"
30+
}
31+
]
32+
},
33+
"parser": "@typescript-eslint/parser",
34+
"settings": {
35+
"react": {
36+
"version": "detect"
37+
},
38+
"import/ignore": ["node_modules", "lib"]
39+
},
40+
"ignorePatterns": ["node_modules", "lib"]
41+
}

functions/package.json

+40
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
{
2+
"name": "functions",
3+
"scripts": {
4+
"build": "tsc",
5+
"serve": "npm run build && firebase emulators:start --only functions",
6+
"shell": "npm run build && firebase functions:shell",
7+
"start": "npm run shell",
8+
"deploy": "firebase deploy --only functions",
9+
"logs": "firebase functions:log",
10+
"lint": "eslint .",
11+
"lint:fix": "yarn lint --fix"
12+
},
13+
"engines": {
14+
"node": "12"
15+
},
16+
"main": "lib/index.js",
17+
"dependencies": {
18+
"@google-cloud/pubsub": "1.7.3",
19+
"@types/twitter": "1.7.0",
20+
"axios": "0.19.2",
21+
"dayjs": "1.8.30",
22+
"firebase-admin": "8.13.0",
23+
"firebase-functions": "3.8.0",
24+
"jsonwebtoken": "8.5.1",
25+
"twitter": "1.7.1"
26+
},
27+
"devDependencies": {
28+
"@typescript-eslint/eslint-plugin": "3.7.1",
29+
"@typescript-eslint/parser": "3.7.1",
30+
"eslint": "7.5.0",
31+
"eslint-config-prettier": "6.11.0",
32+
"eslint-import-resolver-webpack": "0.12.2",
33+
"eslint-loader": "4.0.2",
34+
"eslint-plugin-import": "2.22.0",
35+
"eslint-plugin-prettier": "3.1.4",
36+
"prettier": "2.0.5",
37+
"typescript": "3.9.7",
38+
"firebase-functions-test": "0.2.1"
39+
}
40+
}

0 commit comments

Comments
 (0)