Skip to content

Commit 63eb387

Browse files
[ADD] dotfiles
1 parent 6d088cd commit 63eb387

15 files changed

+1515
-127
lines changed

.copier-answers.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# Do NOT update manually; changes here will be overwritten by Copier
2+
_commit: v1.32
3+
_src_path: https://github.com/OCA/oca-addons-repo-template.git
4+
additional_ruff_rules: []
5+
ci: GitHub
6+
convert_readme_fragments_to_markdown: true
7+
enable_checklog_odoo: false
8+
generate_requirements_txt: true
9+
github_check_license: true
10+
github_ci_extra_env: {}
11+
github_enable_codecov: false
12+
github_enable_makepot: false
13+
github_enable_stale_action: false
14+
github_enforce_dev_status_compatibility: false
15+
include_wkhtmltopdf: false
16+
odoo_test_flavor: OCB
17+
odoo_version: 18.0
18+
org_name: Odoo Community Association (OCA)
19+
org_slug: qrtl
20+
rebel_module_groups: []
21+
repo_description: ''
22+
repo_name: SMI OCA
23+
repo_slug: smi-oca
24+
repo_website: ''
25+
use_pyproject_toml: false
26+
use_ruff: true
27+

.editorconfig

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# Configuration for known file extensions
2+
[*.{css,js,json,less,md,py,rst,sass,scss,xml,yaml,yml}]
3+
charset = utf-8
4+
end_of_line = lf
5+
indent_size = 4
6+
indent_style = space
7+
insert_final_newline = true
8+
trim_trailing_whitespace = true
9+
10+
[*.{json,yml,yaml,rst,md}]
11+
indent_size = 2
12+
13+
# Do not configure editor for libs and autogenerated content
14+
[{*/static/{lib,src/lib}/**,*/static/description/index.html,*/readme/../README.rst}]
15+
charset = unset
16+
end_of_line = unset
17+
indent_size = unset
18+
indent_style = unset
19+
insert_final_newline = false
20+
trim_trailing_whitespace = false

.github/workflows/pre-commit.yml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: pre-commit
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- "18.0*"
7+
push:
8+
branches:
9+
- "18.0"
10+
- "18.0-ocabot-*"
11+
12+
jobs:
13+
pre-commit:
14+
runs-on: ubuntu-22.04
15+
steps:
16+
- uses: actions/checkout@v4
17+
- uses: actions/setup-python@v5
18+
with:
19+
python-version: "3.11"
20+
- name: Get python version
21+
run: echo "PY=$(python -VV | sha256sum | cut -d' ' -f1)" >> $GITHUB_ENV
22+
- uses: actions/cache@v4
23+
with:
24+
path: ~/.cache/pre-commit
25+
key: pre-commit|${{ env.PY }}|${{ hashFiles('.pre-commit-config.yaml') }}
26+
- name: Install pre-commit
27+
run: pip install pre-commit
28+
- name: Run pre-commit
29+
run: pre-commit run --all-files --show-diff-on-failure --color=always
30+
env:
31+
# Consider valid a PR that changes README fragments but doesn't
32+
# change the README.rst file itself. It's not really a problem
33+
# because the bot will update it anyway after merge. This way, we
34+
# lower the barrier for functional contributors that want to fix the
35+
# readme fragments, while still letting developers get README
36+
# auto-generated (which also helps functionals when using runboat).
37+
# DOCS https://pre-commit.com/#temporarily-disabling-hooks
38+
SKIP: oca-gen-addon-readme
39+
- name: Check that all files generated by pre-commit are in git
40+
run: |
41+
newfiles="$(git ls-files --others --exclude-from=.gitignore)"
42+
if [ "$newfiles" != "" ] ; then
43+
echo "Please check-in the following files:"
44+
echo "$newfiles"
45+
exit 1
46+
fi

.github/workflows/test.yml

Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
name: tests
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- "18.0*"
7+
push:
8+
branches:
9+
- "18.0"
10+
- "18.0-ocabot-*"
11+
12+
jobs:
13+
# unreleased-deps:
14+
# runs-on: ubuntu-latest
15+
# name: Detect unreleased dependencies
16+
# steps:
17+
# - uses: actions/checkout@v4
18+
# - run: |
19+
# for reqfile in requirements.txt test-requirements.txt ; do
20+
# if [ -f ${reqfile} ] ; then
21+
# result=0
22+
# # reject non-comment lines that contain a / (i.e. URLs, relative paths)
23+
# grep "^[^#].*/" ${reqfile} || result=$?
24+
# if [ $result -eq 0 ] ; then
25+
# echo "Unreleased dependencies found in ${reqfile}."
26+
# exit 1
27+
# fi
28+
# fi
29+
# done
30+
test:
31+
runs-on: ubuntu-22.04
32+
container: ${{ matrix.container }}
33+
name: ${{ matrix.name }}
34+
strategy:
35+
fail-fast: false
36+
matrix:
37+
include:
38+
- container: ghcr.io/oca/oca-ci/py3.10-ocb18.0:latest
39+
name: test with OCB
40+
makepot: "false"
41+
services:
42+
postgres:
43+
image: postgres:12.0
44+
env:
45+
POSTGRES_USER: odoo
46+
POSTGRES_PASSWORD: odoo
47+
POSTGRES_DB: odoo
48+
ports:
49+
- 5432:5432
50+
steps:
51+
- uses: actions/checkout@v4
52+
with:
53+
persist-credentials: false
54+
- name: Install addons and dependencies
55+
run: oca_install_addons
56+
- name: Check licenses
57+
run: manifestoo -d . check-licenses
58+
- name: Check development status
59+
run: manifestoo -d . check-dev-status --default-dev-status=Beta
60+
continue-on-error: true
61+
- name: Initialize test db
62+
run: oca_init_test_database
63+
- name: Run tests
64+
run: oca_run_tests
65+
- name: Update .pot files
66+
run: oca_export_and_push_pot https://x-access-token:${{ secrets.GIT_PUSH_TOKEN }}@github.com/${{ github.repository }}
67+
if: ${{ matrix.makepot == 'true' && github.event_name == 'push' && github.repository_owner == 'qrtl' }}

.gitignore

Lines changed: 41 additions & 127 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,42 @@
11
# Byte-compiled / optimized / DLL files
22
__pycache__/
33
*.py[cod]
4-
*$py.class
4+
/.venv
5+
/.pytest_cache
6+
/.ruff_cache
57

68
# C extensions
79
*.so
810

911
# Distribution / packaging
1012
.Python
13+
env/
14+
bin/
1115
build/
1216
develop-eggs/
1317
dist/
14-
downloads/
1518
eggs/
16-
.eggs/
17-
lib/
1819
lib64/
1920
parts/
2021
sdist/
2122
var/
22-
wheels/
23-
share/python-wheels/
2423
*.egg-info/
2524
.installed.cfg
2625
*.egg
27-
MANIFEST
26+
*.eggs
27+
28+
# Windows installers
29+
*.msi
30+
31+
# Debian packages
32+
*.deb
2833

29-
# PyInstaller
30-
# Usually these files are written by a python script from a template
31-
# before PyInstaller builds the exe, so as to inject date/other infos into it.
32-
*.manifest
33-
*.spec
34+
# Redhat packages
35+
*.rpm
36+
37+
# MacOS packages
38+
*.dmg
39+
*.pkg
3440

3541
# Installer logs
3642
pip-log.txt
@@ -39,136 +45,44 @@ pip-delete-this-directory.txt
3945
# Unit test / coverage reports
4046
htmlcov/
4147
.tox/
42-
.nox/
4348
.coverage
44-
.coverage.*
4549
.cache
4650
nosetests.xml
4751
coverage.xml
48-
*.cover
49-
*.py,cover
50-
.hypothesis/
51-
.pytest_cache/
52-
cover/
5352

5453
# Translations
5554
*.mo
56-
*.pot
5755

58-
# Django stuff:
59-
*.log
60-
local_settings.py
61-
db.sqlite3
62-
db.sqlite3-journal
56+
# Pycharm
57+
.idea
6358

64-
# Flask stuff:
65-
instance/
66-
.webassets-cache
59+
# Eclipse
60+
.settings
6761

68-
# Scrapy stuff:
69-
.scrapy
62+
# Visual Studio cache/options directory
63+
.vs/
64+
.vscode
7065

71-
# Sphinx documentation
72-
docs/_build/
66+
# OSX Files
67+
.DS_Store
7368

74-
# PyBuilder
75-
.pybuilder/
76-
target/
77-
78-
# Jupyter Notebook
79-
.ipynb_checkpoints
80-
81-
# IPython
82-
profile_default/
83-
ipython_config.py
84-
85-
# pyenv
86-
# For a library or package, you might want to ignore these files since the code is
87-
# intended to run in multiple environments; otherwise, check them in:
88-
# .python-version
89-
90-
# pipenv
91-
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
92-
# However, in case of collaboration, if having platform-specific dependencies or dependencies
93-
# having no cross-platform support, pipenv may install dependencies that don't work, or not
94-
# install all needed dependencies.
95-
#Pipfile.lock
96-
97-
# UV
98-
# Similar to Pipfile.lock, it is generally recommended to include uv.lock in version control.
99-
# This is especially recommended for binary packages to ensure reproducibility, and is more
100-
# commonly ignored for libraries.
101-
#uv.lock
102-
103-
# poetry
104-
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
105-
# This is especially recommended for binary packages to ensure reproducibility, and is more
106-
# commonly ignored for libraries.
107-
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
108-
#poetry.lock
109-
110-
# pdm
111-
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
112-
#pdm.lock
113-
# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
114-
# in version control.
115-
# https://pdm.fming.dev/latest/usage/project/#working-with-version-control
116-
.pdm.toml
117-
.pdm-python
118-
.pdm-build/
119-
120-
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
121-
__pypackages__/
122-
123-
# Celery stuff
124-
celerybeat-schedule
125-
celerybeat.pid
126-
127-
# SageMath parsed files
128-
*.sage.py
129-
130-
# Environments
131-
.env
132-
.venv
133-
env/
134-
venv/
135-
ENV/
136-
env.bak/
137-
venv.bak/
69+
# Django stuff:
70+
*.log
13871

139-
# Spyder project settings
140-
.spyderproject
141-
.spyproject
72+
# Mr Developer
73+
.mr.developer.cfg
74+
.project
75+
.pydevproject
14276

143-
# Rope project settings
77+
# Rope
14478
.ropeproject
14579

146-
# mkdocs documentation
147-
/site
148-
149-
# mypy
150-
.mypy_cache/
151-
.dmypy.json
152-
dmypy.json
153-
154-
# Pyre type checker
155-
.pyre/
156-
157-
# pytype static type analyzer
158-
.pytype/
159-
160-
# Cython debug symbols
161-
cython_debug/
162-
163-
# PyCharm
164-
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
165-
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
166-
# and can be added to the global gitignore or merged into this file. For a more nuclear
167-
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
168-
#.idea/
80+
# Sphinx documentation
81+
docs/_build/
16982

170-
# Ruff stuff:
171-
.ruff_cache/
83+
# Backup files
84+
*~
85+
*.swp
17286

173-
# PyPI configuration file
174-
.pypirc
87+
# OCA rules
88+
!static/lib/

0 commit comments

Comments
 (0)