Skip to content

Commit

Permalink
new: [config] Added various config files for GitHub.
Browse files Browse the repository at this point in the history
  • Loading branch information
cedricbonhomme committed Dec 11, 2023
1 parent caf3055 commit 8eacb40
Show file tree
Hide file tree
Showing 4 changed files with 106 additions and 0 deletions.
21 changes: 21 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
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
17 changes: 17 additions & 0 deletions .github/workflows/pre-commit.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: pre-commit
on:
pull_request:
push:
branches: [master]
jobs:
pre-commit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v3
- run: |
pip install reorder-python-imports
pip install pyupgrade
pip install black
pip install pip-audit
- uses: pre-commit/[email protected]
52 changes: 52 additions & 0 deletions .github/workflows/pythonapp.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: Python application

on: [push]

jobs:
build:

runs-on: ubuntu-latest

strategy:
matrix:
python-version: [3.10.9, 3.11.0]

steps:
- uses: actions/checkout@v1

- name: Install libxml2-dev and libxslt-dev
run: sudo apt-get install -y libxml2-dev libxslt-dev

- name: Setup PostgreSQL
uses: Harmon758/[email protected]
with:
postgresql db: 'pumpkin'
postgresql user: 'pumpkin'
postgresql password: 'password'

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
pip install poetry
poetry install
- name: Lint with flake8
run: |
# stop the build if there are Python syntax errors or undefined names
poetry run flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
poetry run flake8 . --count --max-complexity=15 --max-line-length=100 --statistics
# - name: Test with pytest
# run: |
# poetry run pytest
# env:
# testing: actions

# - name: Type check with mypy
# run: |
# poetry run mypy .
16 changes: 16 additions & 0 deletions SECURITY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Security Policy

## Supported Versions

Last stable version always provides security updates.
There will be no security patches for other releases (tagged or not).

## Reporting a Vulnerability

In the case of a security vulnerability report, we ask the reporter
to send it directly to [CIRCL](https://www.circl.lu/contact/), if
possible encrypted with the following GnuPG key:
**CA57 2205 C002 4E06 BA70 BE89 EAAD CFFC 22BD 4CD5**.
We usually fix reported and confirmed security vulnerabilities
in less than 48 hours, followed by a software release containing
the fixes within the following days.

0 comments on commit 8eacb40

Please sign in to comment.