Skip to content

Commit 298faee

Browse files
authored
Merge pull request #187 from TaleLin/dev
Dev
2 parents 6c9e9b0 + 22697c3 commit 298faee

77 files changed

Lines changed: 1138 additions & 927 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.dockerignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
.venv

.editorconfig

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
root = true
2+
3+
[*]
4+
indent_style = space
5+
indent_size = 4
6+
insert_final_newline = true
7+
trim_trailing_whitespace = true
8+
end_of_line = lf
9+
charset = utf-8
10+
max_line_length = 100
11+
12+
[*.{yml,yaml,json,js,css,html}]
13+
indent_size = 2

.flake8

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
[flake8]
2+
max-line-length = 120
3+
select = C,E,F,W,B,B9
4+
ignore = E203, E501, W503, E712, E711
5+
per-file-ignores =
6+
__init__.py: F401
7+
app/core/exception.py: F811
8+
app/cli/plugin/init.py: W605
9+
exclude =
10+
.git,
11+
__pycache__,
12+
build,
13+
dist,
14+
tests,
15+
.venv

.github/ISSUE_TEMPLATE/bug_report.md

Lines changed: 0 additions & 27 deletions
This file was deleted.

.github/ISSUE_TEMPLATE/feature_request.md

Lines changed: 0 additions & 20 deletions
This file was deleted.

.github/ISSUE_TEMPLATE/question.md

Lines changed: 0 additions & 6 deletions
This file was deleted.

.gitignore

Lines changed: 23 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,8 @@
1-
# .env 中记录了私密配置
2-
# *.env
3-
1+
# OS
42
.DS_Store
5-
.idea
6-
.vscode
7-
*.pytest_cache/
8-
*.pyc
9-
assets
10-
logs
11-
12-
# Created by https://www.toptal.com/developers/gitignore/api/python
13-
# Edit at https://www.toptal.com/developers/gitignore?templates=python
143

15-
### Python ###
164
# Byte-compiled / optimized / DLL files
175
__pycache__/
18-
*/__pycache__/
196
*.py[cod]
207
*$py.class
218

@@ -30,6 +17,7 @@ dist/
3017
downloads/
3118
eggs/
3219
.eggs/
20+
lib/
3321
lib64/
3422
parts/
3523
sdist/
@@ -54,7 +42,9 @@ pip-delete-this-directory.txt
5442

5543
# Unit test / coverage reports
5644
htmlcov/
57-
test.json
45+
.tox/
46+
.nox/
47+
.coverage
5848
.coverage.*
5949
.cache
6050
nosetests.xml
@@ -63,7 +53,6 @@ coverage.xml
6353
*.py,cover
6454
.hypothesis/
6555
.pytest_cache/
66-
pytestdebug.log
6756

6857
# Translations
6958
*.mo
@@ -74,7 +63,6 @@ pytestdebug.log
7463
local_settings.py
7564
db.sqlite3
7665
db.sqlite3-journal
77-
*.db
7866

7967
# Flask stuff:
8068
instance/
@@ -85,7 +73,6 @@ instance/
8573

8674
# Sphinx documentation
8775
docs/_build/
88-
doc/_build/
8976

9077
# PyBuilder
9178
target/
@@ -118,6 +105,7 @@ celerybeat.pid
118105
*.sage.py
119106

120107
# Environments
108+
.env
121109
.venv
122110
env/
123111
venv/
@@ -143,8 +131,22 @@ dmypy.json
143131
# Pyre type checker
144132
.pyre/
145133

146-
# pytype static type analyzer
147-
.pytype/
134+
# IDE
135+
.vscode/
136+
.idea/
137+
.vim/
148138

149-
# End of https://www.toptal.com/developers/gitignore/api/python
139+
# custom
140+
assets
141+
logs
142+
143+
*.pyc
144+
# poetry lock
145+
poetry.lock
146+
# db
147+
lincmsdev.db
148+
lincmsprod.db
149+
lincms.db
150150

151+
# .env 中记录了私密配置
152+
# *.env

.pre-commit-config.yaml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
repos:
2+
- repo: https://github.com/PyCQA/flake8
3+
rev: 4.0.1
4+
hooks:
5+
- id: flake8
6+
exclude: tests
7+
- repo: https://github.com/psf/black
8+
rev: 21.10b0
9+
hooks:
10+
- id: black
11+
- repo: https://github.com/pre-commit/pre-commit-hooks
12+
rev: v4.0.1
13+
hooks:
14+
- id: fix-byte-order-marker
15+
- id: trailing-whitespace
16+
- id: end-of-file-fixer
17+
- id: check-added-large-files

Dockerfile

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
FROM python:3.9
2+
# 拷贝依赖
3+
COPY requirements-prod.txt .
4+
# 安装依赖
5+
# RUN pip install -r requirements-prod.txt -i http://mirrors.aliyun.com/pypi/simple/ --trusted-host=mirrors.aliyun.com >/dev/null 2>&1
6+
RUN pip install -r requirements-prod.txt >/dev/null 2>&1
7+
# 拷贝项目
8+
COPY . /app

LICENSE

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,20 @@
1+
ISC License
2+
3+
Copyright (c) 2016, Kenneth Reitz <me@kennethreitz.org>
4+
5+
Permission to use, copy, modify, and/or distribute this software for any
6+
purpose with or without fee is hereby granted, provided that the above
7+
copyright notice and this permission notice appear in all copies.
8+
9+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
10+
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
11+
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
12+
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
13+
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
14+
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
15+
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
16+
=== https://github.com/kennethreitz/records(v0.5.3) ===
17+
118
MIT License
219

320
Copyright (c) 2019 TaleLin
@@ -18,4 +35,4 @@ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
1835
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
1936
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
2037
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21-
SOFTWARE.
38+
SOFTWARE.

0 commit comments

Comments
 (0)