Skip to content

Commit 3405848

Browse files
committed
feat: init project
1 parent b96760f commit 3405848

18 files changed

+209
-0
lines changed

.gitignore

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
node_modules
2+
.DS_STORE
3+
lerna-debug.log
4+
yarn-error.log
5+
dist
6+
includes
7+
tsconfig.tsbuildinfo
8+
.env
9+
coverage
10+
yarn.lock
11+
package-lock.json

.prettierignore

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
2+
3+
# Development folders and files #
4+
#################################
5+
.tmp/
6+
node_modules/
7+
package.json
8+
.travis.yml
9+
*.md
10+
dist

.prettierrc

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
{
2+
"parser": "typescript",
3+
"printWidth": 80,
4+
"singleQuote": true,
5+
"trailingComma": "all",
6+
"arrowParens": "always",
7+
"overrides": [
8+
{
9+
"files": "*.json",
10+
"options": {
11+
"parser": "json"
12+
}
13+
}
14+
]
15+
}

lerna.json

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"packages": ["packages/*"],
3+
"version": "independent",
4+
"useWorkspaces": true,
5+
"command": {
6+
"publish": {
7+
"allowBranch": ["master", "dev"],
8+
"message": "chore(release): publish %v"
9+
}
10+
}
11+
}

package.json

+32
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
{
2+
"private": true,
3+
"scripts": {
4+
"bootstrap": "lerna bootstrap",
5+
"build:ts": "tsc -b tsconfig.json",
6+
"clean": "lerna clean --yes && lerna run clean && rimraf includes",
7+
"release": "yarn bootstrap && yarn build:ts && lerna publish --exact",
8+
"format": "prettier --write '**/*.{ts,tsx}' --config .prettierrc"
9+
},
10+
"workspaces": [
11+
"packages/*"
12+
],
13+
"husky": {
14+
"hooks": {
15+
"pre-commit": "pretty-quick --staged"
16+
}
17+
},
18+
"devDependencies": {
19+
"@types/node": "^12.12.6",
20+
"husky": "^3.0.9",
21+
"lerna": "^3.18.3",
22+
"prettier": "^1.18.2",
23+
"pretty-quick": "^2.0.1",
24+
"rimraf": "^3.0.0",
25+
"ts-node": "^8.4.1",
26+
"tslint": "^5.20.1",
27+
"tslint-config-prettier": "^1.18.0",
28+
"typescript": "^3.7.2",
29+
"webpack": "^4.41.2",
30+
"webpack-command": "^0.5.0"
31+
}
32+
}

packages/api-gateway/README.md

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
# Tencent Api Gateway

packages/api-gateway/package.json

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
{
2+
"name": "@tss/api-gw",
3+
"version": "0.0.0",
4+
"description": "Tencent cloud api gateway sdk",
5+
"main": "dist/index.js",
6+
"scripts": {
7+
"test": "echo \"Error: no test specified\" && exit 1"
8+
},
9+
"keywords": [
10+
"tencent-clound",
11+
"api-gateway"
12+
],
13+
"author": "yugasun",
14+
"license": "MIT"
15+
}

packages/api-gateway/src/index.ts

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
export default {};

packages/api-gateway/tsconfig.json

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"extends": "../../tsconfig.base.json",
3+
"compilerOptions": {
4+
"rootDir": "src",
5+
"outDir": "dist"
6+
},
7+
"include": ["src", "../../typings/**/*.d.ts"]
8+
}

packages/cos/package.json

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
{
2+
"name": "@tss/cos",
3+
"version": "0.0.0",
4+
"description": "Tencent cloud cos sdk",
5+
"main": "dist/index.js",
6+
"scripts": {
7+
"test": "echo \"Error: no test specified\" && exit 1"
8+
},
9+
"keywords": [
10+
"tencent-cloud",
11+
"cos"
12+
],
13+
"author": "yugasun",
14+
"license": "MIT"
15+
}

packages/cos/src/index.ts

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
export default {};

packages/cos/tsconfig.json

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"extends": "../../tsconfig.base.json",
3+
"compilerOptions": {
4+
"rootDir": "src",
5+
"outDir": "dist"
6+
},
7+
"include": ["src", "../../typings/**/*.d.ts"]
8+
}

packages/function/package.json

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
{
2+
"name": "@tss/function",
3+
"version": "0.0.0",
4+
"description": "Tencent cloud serverlerss function sdk",
5+
"main": "dist/index.js",
6+
"scripts": {
7+
"test": "echo \"Error: no test specified\" && exit 1"
8+
},
9+
"keywords": [
10+
"tencent-cloud",
11+
"function"
12+
],
13+
"author": "yugasun",
14+
"license": "MIT"
15+
}

packages/function/src/index.ts

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
export default {};

packages/function/tsconfig.json

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"extends": "../../tsconfig.base.json",
3+
"compilerOptions": {
4+
"rootDir": "src",
5+
"outDir": "dist"
6+
},
7+
"include": ["src", "../../typings/**/*.d.ts"]
8+
}

tsconfig.base.json

+26
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
{
2+
"compilerOptions": {
3+
"allowSyntheticDefaultImports": true,
4+
"baseUrl": ".",
5+
"composite": true,
6+
"declaration": true,
7+
"declarationMap": true,
8+
"downlevelIteration": true,
9+
"emitDecoratorMetadata": true,
10+
"esModuleInterop": true,
11+
"experimentalDecorators": true,
12+
"preserveConstEnums": true,
13+
"importHelpers": true,
14+
"lib": ["esnext", "dom"],
15+
"module": "commonjs",
16+
"moduleResolution": "node",
17+
"sourceMap": true,
18+
"paths": {
19+
"*": ["typings/*", "includes/*"]
20+
},
21+
"resolveJsonModule": true,
22+
"noUnusedLocals": true,
23+
"strict": true,
24+
"target": "es5"
25+
}
26+
}

tsconfig.json

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"files": [],
3+
"references": [
4+
{ "path": "packages/api-gateway" },
5+
{ "path": "packages/cos" },
6+
{ "path": "packages/function" }
7+
]
8+
}

tslint.json

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
{
2+
"extends": ["tslint:latest", "tslint-config-prettier"],
3+
"rules": {
4+
"interface-name": [true, "never-prefix"],
5+
"member-access": false,
6+
"no-angle-bracket-type-assertion": false,
7+
"no-bitwise": false,
8+
"no-console": false,
9+
"no-default-export": true,
10+
"no-empty-interface": false,
11+
"no-implicit-dependencies": false,
12+
"no-submodule-imports": false,
13+
"ordered-imports": [false],
14+
"object-literal-sort-keys": false,
15+
"object-literal-key-quotes": [true, "as-needed"],
16+
"quotemark": [true, "single"],
17+
"semicolon": [true, "always", "ignore-bound-class-methods"],
18+
"jsx-boolean-value": false
19+
},
20+
"linterOptions": {
21+
"exclude": ["config/**/*.js", "node_modules/**/*.ts"]
22+
}
23+
}

0 commit comments

Comments
 (0)