-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chg: Execute ore-commit on all the project.
- Loading branch information
1 parent
cceff81
commit bc88e16
Showing
10 changed files
with
213 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
## Generic requirements in order to contribute: | ||
|
||
* One Pull Request per fix/feature/change/... | ||
* Keep the amount of commits per PR as small as possible: if for any reason, you need to fix your commit after the pull request, please squash the changes in one single commit (or tell us why not) | ||
* Always make sure it is mergeable in the default branch | ||
* Any major changes adding a functionality should be disabled by default in the configuration. | ||
|
||
|
||
#### What does it do? | ||
|
||
If it fixes an existing issue, please use GitHub syntax: `#<IssueID>` | ||
|
||
#### Questions | ||
|
||
- [ ] Does it require a DB change? | ||
- [ ] Are you using it in production? | ||
|
||
#### Release Type: | ||
- [ ] Major | ||
- [ ] Minor | ||
- [X] Patch |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
name: pre-commit | ||
on: | ||
pull_request: | ||
push: | ||
branches: [master] | ||
jobs: | ||
pre-commit: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-python@v5 | ||
with: | ||
python-version: '3.12' | ||
- run: | | ||
pip install reorder-python-imports | ||
pip install pyupgrade | ||
pip install black | ||
pip install pip-audit | ||
- uses: pre-commit/[email protected] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
ci: | ||
autoupdate_schedule: monthly | ||
repos: | ||
- repo: https://github.com/asottile/pyupgrade | ||
rev: v3.3.1 | ||
hooks: | ||
- id: pyupgrade | ||
args: ["--py37-plus"] | ||
- repo: https://github.com/asottile/reorder-python-imports | ||
rev: v3.12.0 | ||
hooks: | ||
- id: reorder-python-imports | ||
- repo: https://github.com/psf/black | ||
rev: 23.9.1 | ||
hooks: | ||
- id: black | ||
- repo: https://github.com/asottile/blacken-docs | ||
rev: 1.13.0 | ||
hooks: | ||
- id: blacken-docs | ||
- repo: https://github.com/PyCQA/flake8 | ||
rev: 6.1.0 | ||
hooks: | ||
- id: flake8 | ||
additional_dependencies: | ||
- flake8-bugbear | ||
- flake8-implicit-str-concat | ||
args: ["--max-line-length=125"] | ||
- repo: https://github.com/pre-commit/pre-commit-hooks | ||
rev: v4.4.0 | ||
hooks: | ||
- id: fix-byte-order-marker | ||
- id: trailing-whitespace | ||
- id: end-of-file-fixer | ||
- id: check-yaml | ||
- id: check-added-large-files | ||
args: ['--maxkb=800'] | ||
- repo: https://github.com/pypa/pip-audit | ||
rev: v2.7.3 | ||
hooks: | ||
- id: pip-audit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,31 +2,29 @@ | |
# | ||
# For the full list of built-in configuration values, see the documentation: | ||
# https://www.sphinx-doc.org/en/master/usage/configuration.html | ||
|
||
# -- Project information ----------------------------------------------------- | ||
# https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information | ||
|
||
project = 'RSTORE' | ||
project = "RSTORE" | ||
copyright = "Computer Incident Response Center Luxembourg (CIRCL) <[email protected]>" | ||
author = "Cédric Bonhomme <[email protected]>" | ||
release = '0.1.0' | ||
release = "0.1.0" | ||
|
||
# -- General configuration --------------------------------------------------- | ||
# https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration | ||
|
||
extensions = [] | ||
|
||
templates_path = ['_templates'] | ||
exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store'] | ||
|
||
templates_path = ["_templates"] | ||
exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] | ||
|
||
|
||
# -- Options for HTML output ------------------------------------------------- | ||
# https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output | ||
|
||
html_theme = 'sphinx_book_theme' | ||
html_static_path = ['_static'] | ||
html_title = 'RSTORE' | ||
html_theme = "sphinx_book_theme" | ||
html_static_path = ["_static"] | ||
html_title = "RSTORE" | ||
html_theme_options = { | ||
"path_to_docs": "docs", | ||
"repository_url": "https://github.com/scandale-project/RSTORE", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +0,0 @@ | ||
import uuid | ||
|
||
from pydantic import BaseModel | ||
|
||
class Payload(BaseModel): | ||
raw: str | ||
|
||
|
||
class Meta(BaseModel): | ||
uuid: str | ||
ts: int | ||
type: str | ||
|
||
|
||
class ScanData(BaseModel): | ||
version: str | ||
format: str | ||
meta: Meta | ||
payload: Payload | ||
|
||
class Config: | ||
from_attributes = True | ||
|
||
class ItemBase(ScanData): | ||
scan_data: ScanData | ||
|
||
class Config: | ||
from_attributes = True | ||