forked from packit/packit-service
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.pre-commit-config.yaml
77 lines (76 loc) · 3.17 KB
/
.pre-commit-config.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
# HOWTO: https://pre-commit.com/#usage
# pip3 install pre-commit
# pre-commit install -t pre-commit -t pre-push
repos:
- repo: https://github.com/psf/black
rev: 20.8b1
hooks:
- id: black
- repo: https://github.com/asottile/pyupgrade
rev: v2.11.0
hooks:
- id: pyupgrade
- repo: https://github.com/pre-commit/mirrors-prettier
rev: v2.2.1
hooks:
- id: prettier
exclude: tests_requre/openshift_integration/test_data/*
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v3.4.0
hooks:
- id: check-added-large-files
- id: check-ast
- id: check-merge-conflict
- id: check-yaml
exclude: zuul.d
- id: detect-private-key
exclude: tests/conftest.py
- id: detect-aws-credentials
args:
- --allow-missing-credentials
- id: end-of-file-fixer
- id: trailing-whitespace
- repo: https://gitlab.com/pycqa/flake8
rev: 3.9.0
hooks:
- id: flake8
args:
- --max-line-length=100
- --per-file-ignores=files/packit.wsgi:F401,E402
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v0.812
hooks:
- id: mypy
args: [--no-strict-optional, --ignore-missing-imports]
- repo: https://github.com/packit/pre-commit-hooks
rev: bec7c9ff9a985ececa53ac8078dc60ca9603f9d7
hooks:
- id: check-rebase
args:
- git://github.com/packit-service/packit-service.git
stages: [manual, push]
- repo: https://github.com/packit/requre
rev: 0.7.0
hooks:
- id: requre-purge
name: Requre response files cleanup
description: Replace the sensitive/time-based values in the requre response files
entry: >
requre-patch purge
--replaces 'requests.sessions%send:Date:str:Fri, 01 Nov 2019 13-36-03 GMT'
--replaces 'requests.sessions%send:ETag:str:W/"1e51b8e1c48787a433405211e9e0fe61"'
--replaces 'requests.sessions%send:X-Fedora-RequestID:str:XcFVKMi@EiqyqRlV7q32fgBBBkM'
--replaces 'requests.sessions%send:X-RateLimit-Remaining:str:4972'
--replaces 'requests.sessions%send:X-RateLimit-Reset:str:1572953901'
--replaces 'requests.sessions%send:X-GitHub-Request-Id:str:18FB:AA1A:99616C4:B8092CB:5CC15425'
--replaces 'requests.sessions%send:AppTime:str:D=4081'
--replaces 'requests.sessions%send:X-Fedora-AppServer:str:koji01.phx2.fedoraproject.org'
--replaces 'requests.sessions%send:X-Fedora-ProxyServer:str:proxy01.phx2.fedoraproject.org'
--replaces "requests.sessions%send:Content-Security-Policy:str:default-src 'self';script-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne' https://apps.fedoraproject.org; style-src 'self' 'nonce-YqLDC0BS8d7iY8mKO7VtBbIne'; object-src 'none';base-uri 'self';img-src 'self' https:;"
--replaces "requests.sessions%_content:expires_at:str:2019-11-01T14:35:53Z"
--replaces "requests.sessions%send:elapsed:float:0.2"
--replaces "requests.sessions%_content:token:str:v1.1cd89d399b8c70f8b88e22cbdaa72abbe5e390db"
language: python
types: [yaml]
files: /tests_requre.*\.yaml$
stages: [manual, push]