Skip to content

Commit 4e88bd7

Browse files
committed
🎉 Initial
0 parents  commit 4e88bd7

File tree

27 files changed

+1528
-0
lines changed

27 files changed

+1528
-0
lines changed

.deepsource.toml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
version = 1
2+
exclude_patterns = []
3+
# https://github.com/deepsourcelabs/cli/issues/198
4+
test_patterns = ["tests/*_test.py", "tests/test_*.py"]
5+
6+
[[analyzers]]
7+
name = "python"
8+
enabled = true
9+
10+
[[transformers]]
11+
name = "black"
12+
enabled = true

.github/FUNDING.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
custom:
3+
- "https://user-images.githubusercontent.com/32936898/199681341-1c5cfa61-4411-4b67-b268-7cd87c5867bb.png"
4+
- "https://user-images.githubusercontent.com/32936898/199681363-1094a0be-85ca-49cf-a410-19b3d7965120.png"
5+
- "https://user-images.githubusercontent.com/32936898/199681368-c34c2be7-e0d8-43ea-8c2c-d3e865da6aeb.png"

.github/workflows/main.yml

Lines changed: 99 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,99 @@
1+
---
2+
"on":
3+
push:
4+
paths-ignore:
5+
- "**.md"
6+
- docs/*
7+
pull_request:
8+
paths-ignore:
9+
- "**.md"
10+
- docs/*
11+
workflow_dispatch:
12+
13+
# https://github.com/softprops/action-gh-release/issues/236
14+
permissions:
15+
contents: write
16+
17+
env:
18+
PYTHONUTF8: "1"
19+
python-version: 3.x
20+
cache: pip
21+
22+
jobs:
23+
# test:
24+
# strategy:
25+
# fail-fast: false
26+
# matrix:
27+
# runs-on:
28+
# - ubuntu-latest
29+
# - macos-latest
30+
# - windows-latest
31+
# runs-on: ${{matrix.runs-on}}
32+
# steps:
33+
# - uses: actions/checkout@v3
34+
# - uses: actions/setup-python@v4
35+
# with:
36+
# python-version: ${{ env.python-version }}
37+
# cache: ${{env.cache}}
38+
# cache-dependency-path: |-
39+
# requirements.txt
40+
# requirements/dev.txt
41+
# - name: Install dependencies
42+
# run: |
43+
# pip install -e '.[dev]'
44+
# - name: Test
45+
# run: |
46+
# pytest --cov
47+
# - uses: codecov/codecov-action@v3
48+
49+
build:
50+
# needs: test
51+
strategy:
52+
fail-fast: false
53+
matrix:
54+
runs-on:
55+
- ubuntu-latest
56+
- macos-latest
57+
- windows-latest
58+
runs-on: ${{matrix.runs-on}}
59+
steps:
60+
- uses: actions/checkout@v3
61+
- uses: actions/setup-python@v4
62+
with:
63+
python-version: ${{ env.python-version }}
64+
cache: ${{env.cache}}
65+
cache-dependency-path: |-
66+
requirements.txt
67+
requirements/dev.txt
68+
- name: Install dependencies
69+
run: |
70+
pip install build
71+
- name: Build
72+
run: |
73+
python -m build
74+
- uses: pypa/gh-action-pypi-publish@release/v1
75+
if: runner.os == 'Linux' && startsWith(github.ref, 'refs/tags/')
76+
with:
77+
password: ${{secrets.PYPI_API_TOKEN}}
78+
- uses: actions/upload-artifact@v3
79+
if: runner.os == 'Linux' && ! startsWith(github.ref, 'refs/tags/')
80+
with:
81+
path: |
82+
dist/*
83+
- uses: softprops/action-gh-release@v1
84+
if: runner.os == 'Linux' && startsWith(github.ref, 'refs/tags/')
85+
with:
86+
# body_path: build/CHANGELOG.md
87+
files: |
88+
dist/*
89+
90+
deploy-aur:
91+
needs: build
92+
runs-on: ubuntu-latest
93+
if: startsWith(github.ref, 'refs/tags/')
94+
steps:
95+
- uses: Freed-Wu/[email protected]
96+
if: startsWith(github.ref, 'refs/tags/')
97+
with:
98+
package_name: python-sphinxcontrib-autofile
99+
ssh_private_key: ${{secrets.AUR_SSH_PRIVATE_KEY}}

.gitignore

Lines changed: 129 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,129 @@
1+
_version.py
2+
_metainfo.py
3+
4+
# create by https://github.com/iamcco/coc-gitignore (Fri Dec 09 2022 23:38:38 GMT+0800 (China Standard Time))
5+
# Python.gitignore:
6+
# Byte-compiled / optimized / DLL files
7+
__pycache__/
8+
*.py[cod]
9+
*$py.class
10+
11+
# C extensions
12+
*.so
13+
14+
# Distribution / packaging
15+
.Python
16+
build/
17+
develop-eggs/
18+
dist/
19+
downloads/
20+
eggs/
21+
.eggs/
22+
lib/
23+
lib64/
24+
parts/
25+
sdist/
26+
var/
27+
wheels/
28+
pip-wheel-metadata/
29+
share/python-wheels/
30+
*.egg-info/
31+
.installed.cfg
32+
*.egg
33+
MANIFEST
34+
35+
# PyInstaller
36+
# Usually these files are written by a python script from a template
37+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
38+
*.manifest
39+
*.spec
40+
41+
# Installer logs
42+
pip-log.txt
43+
pip-delete-this-directory.txt
44+
45+
# Unit test / coverage reports
46+
htmlcov/
47+
.tox/
48+
.nox/
49+
.coverage
50+
.coverage.*
51+
.cache
52+
nosetests.xml
53+
coverage.xml
54+
*.cover
55+
.hypothesis/
56+
.pytest_cache/
57+
58+
# Translations
59+
*.mo
60+
*.pot
61+
62+
# Django stuff:
63+
*.log
64+
local_settings.py
65+
db.sqlite3
66+
db.sqlite3-journal
67+
68+
# Flask stuff:
69+
instance/
70+
.webassets-cache
71+
72+
# Scrapy stuff:
73+
.scrapy
74+
75+
# Sphinx documentation
76+
docs/_build/
77+
78+
# PyBuilder
79+
target/
80+
81+
# Jupyter Notebook
82+
.ipynb_checkpoints
83+
84+
# IPython
85+
profile_default/
86+
ipython_config.py
87+
88+
# pyenv
89+
.python-version
90+
91+
# pipenv
92+
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
93+
# However, in case of collaboration, if having platform-specific dependencies or dependencies
94+
# having no cross-platform support, pipenv may install dependencies that don't work, or not
95+
# install all needed dependencies.
96+
#Pipfile.lock
97+
98+
# celery beat schedule file
99+
celerybeat-schedule
100+
101+
# SageMath parsed files
102+
*.sage.py
103+
104+
# Environments
105+
.env
106+
.venv
107+
env/
108+
venv/
109+
ENV/
110+
env.bak/
111+
venv.bak/
112+
113+
# Spyder project settings
114+
.spyderproject
115+
.spyproject
116+
117+
# Rope project settings
118+
.ropeproject
119+
120+
# mkdocs documentation
121+
/site
122+
123+
# mypy
124+
.mypy_cache/
125+
.dmypy.json
126+
dmypy.json
127+
128+
# Pyre type checker
129+
.pyre/

.gitlint

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
#!/usr/bin/env -S gitlint -C
2+
[ignore-by-title]
3+
regex=.*
4+
ignore=body-is-missing
5+
# ex: filetype=dosini

.pre-commit-config.yaml

Lines changed: 116 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,116 @@
1+
---
2+
repos:
3+
- repo: https://github.com/pre-commit/pre-commit-hooks
4+
rev: v4.4.0
5+
hooks:
6+
- id: check-added-large-files
7+
- id: fix-byte-order-marker
8+
- id: check-case-conflict
9+
- id: check-shebang-scripts-are-executable
10+
- id: check-merge-conflict
11+
- id: trailing-whitespace
12+
- id: mixed-line-ending
13+
- id: end-of-file-fixer
14+
exclude: ^templates/class\.txt$
15+
- id: detect-private-key
16+
- id: check-symlinks
17+
- id: check-ast
18+
- id: debug-statements
19+
- id: requirements-txt-fixer
20+
- id: check-xml
21+
- id: check-yaml
22+
- id: check-toml
23+
- id: check-json
24+
- repo: https://github.com/Lucas-C/pre-commit-hooks
25+
rev: v1.5.4
26+
hooks:
27+
- id: remove-crlf
28+
- repo: https://github.com/codespell-project/codespell
29+
rev: v2.2.5
30+
hooks:
31+
- id: codespell
32+
additional_dependencies:
33+
- tomli
34+
- repo: https://github.com/jorisroovers/gitlint
35+
rev: v0.19.1
36+
hooks:
37+
- id: gitlint
38+
args:
39+
- --msg-filename
40+
- repo: https://github.com/editorconfig-checker/editorconfig-checker.python
41+
rev: 2.7.2
42+
hooks:
43+
- id: editorconfig-checker
44+
- repo: https://github.com/jumanjihouse/pre-commit-hooks
45+
rev: 3.0.0
46+
hooks:
47+
- id: check-mailmap
48+
- repo: https://github.com/rhysd/actionlint
49+
rev: v1.6.25
50+
hooks:
51+
- id: actionlint
52+
- repo: https://github.com/adrienverge/yamllint
53+
rev: v1.32.0
54+
hooks:
55+
- id: yamllint
56+
- repo: https://github.com/executablebooks/mdformat
57+
rev: 0.7.16
58+
hooks:
59+
- id: mdformat
60+
additional_dependencies:
61+
- mdformat-pyproject
62+
- mdformat-gfm
63+
- mdformat-myst
64+
- mdformat-toc
65+
- mdformat-deflist
66+
- mdformat-beautysh
67+
- mdformat-black
68+
- mdformat-config
69+
- repo: https://github.com/DavidAnson/markdownlint-cli2
70+
rev: v0.8.1
71+
hooks:
72+
- id: markdownlint-cli2
73+
additional_dependencies:
74+
75+
- repo: https://github.com/Freed-Wu/pre-commit-hooks
76+
rev: 0.0.11
77+
hooks:
78+
- id: update-pyproject.toml
79+
- repo: https://github.com/perltidy/perltidy
80+
rev: "20230701.02"
81+
hooks:
82+
- id: perltidy
83+
- repo: https://github.com/psf/black
84+
rev: 23.7.0
85+
hooks:
86+
- id: black
87+
- repo: https://github.com/PyCQA/isort
88+
rev: 5.12.0
89+
hooks:
90+
- id: isort
91+
- repo: https://github.com/pycqa/pydocstyle
92+
rev: 6.3.0
93+
hooks:
94+
- id: pydocstyle
95+
additional_dependencies:
96+
- tomli
97+
- repo: https://github.com/kumaraditya303/mirrors-pyright
98+
rev: v1.1.322
99+
hooks:
100+
- id: pyright
101+
- repo: https://github.com/PyCQA/bandit
102+
rev: 1.7.5
103+
hooks:
104+
- id: bandit
105+
args:
106+
- -cpyproject.toml
107+
additional_dependencies:
108+
- tomli
109+
- repo: https://github.com/nix-community/nixpkgs-fmt
110+
rev: v1.3.0
111+
hooks:
112+
- id: nixpkgs-fmt
113+
114+
ci:
115+
skip:
116+
- pyright

.readthedocs.yaml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# https://docs.readthedocs.io/en/stable/config-file/v2.html
2+
---
3+
version: 2
4+
5+
build:
6+
os: ubuntu-22.04
7+
apt_packages:
8+
- perl
9+
tools:
10+
python: "3"
11+
12+
formats: all
13+
14+
python:
15+
install:
16+
- requirements: docs/requirements.txt

.yamllint.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
#!/usr/bin/env -S yamllint -c
2+
---
3+
extends: default
4+
5+
rules:
6+
comments:
7+
# https://github.com/prettier/prettier/issues/6780
8+
min-spaces-from-content: 1

0 commit comments

Comments
 (0)