Skip to content

Commit c321fcb

Browse files
authored
Merge pull request #30 from microsoft/revert-20-dciborow/pyproject
Revert "Create pyproject.toml"
2 parents 83f5dfd + e01c9ce commit c321fcb

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

42 files changed

+655
-713
lines changed

.devcontainer/Dockerfile

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,14 @@ RUN if [ -f "/tmp/conda-tmp/environment.yml" ]; then umask 0002 && /opt/conda/bi
1313
&& rm -rf /tmp/conda-tmp
1414

1515
RUN conda install -y python=3.8 \
16-
&& python3.8 -m pip install --upgrade pip \
17-
&& python3.8 -m pip install \
18-
pytest \
19-
pytest-cov \
20-
flit \
21-
pre-commit
16+
&& python3.8 -m pip install --upgrade pip tox
17+
18+
COPY requirements.test.txt /tmp/
19+
RUN python3.8 -m pip install -r /tmp/requirements.test.txt
2220

23-
COPY .pre-commit-config.yaml .
24-
RUN git init . && pre-commit install-hooks
21+
COPY requirements.txt /tmp/
22+
RUN python3.8 -m pip install -r /tmp/requirements.txt
23+
24+
# [Optional] Uncomment this section to install additional OS packages.
25+
# RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \
26+
# && apt-get -y install --no-install-recommends <your-package-list-here>

.devcontainer/devcontainer.json

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,16 @@
22
// https://github.com/microsoft/vscode-dev-containers/tree/v0.222.0/containers/python-3-miniconda
33
{
44
"name": "Miniconda (Python 3)",
5-
"build": {
5+
"build": {
66
"context": "..",
77
"dockerfile": "Dockerfile",
88
"args": {
99
"NODE_VERSION": "none"
1010
}
1111
},
12+
1213
// Set *default* container specific settings.json values on container create.
13-
"settings": {
14+
"settings": {
1415
"python.defaultInterpreterPath": "/opt/conda/bin/python",
1516
"python.linting.enabled": true,
1617
"python.linting.pylintEnabled": true,
@@ -24,20 +25,19 @@
2425
"python.linting.pydocstylePath": "/usr/local/py-utils/bin/pydocstyle",
2526
"python.linting.pylintPath": "/usr/local/py-utils/bin/pylint"
2627
},
28+
2729
// Add the IDs of extensions you want installed when the container is created.
2830
"extensions": [
2931
"ms-python.python",
30-
"ms-python.vscode-pylance",
31-
"ms-python.pylint",
32-
"ms-python.black-formatter",
33-
"ms-vsliveshare.vsliveshare",
34-
"ryanluker.vscode-coverage-gutters",
35-
"bungcip.better-toml"
32+
"ms-python.vscode-pylance"
3633
],
34+
3735
// Use 'forwardPorts' to make a list of ports inside the container available locally.
3836
// "forwardPorts": [],
37+
3938
// Use 'postCreateCommand' to run commands after the container is created.
4039
// "postCreateCommand": "python --version",
40+
4141
// Comment out to connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
4242
"remoteUser": "vscode",
4343
"features": {

.devcontainer/noop.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
This file is copied into the container along with environment.yml* from the
2-
parent folder. This is done to prevent the Dockerfile COPY instruction from
2+
parent folder. This is done to prevent the Dockerfile COPY instruction from
33
failing if no environment.yml is found.

.flake8

Lines changed: 0 additions & 16 deletions
This file was deleted.

.github/workflows/CI.yml

Lines changed: 0 additions & 31 deletions
This file was deleted.

.github/workflows/black.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
# This is a basic workflow to help you get started with Actions
2+
3+
name: Black
4+
5+
# Controls when the workflow will run
6+
on:
7+
# Triggers the workflow on push or pull request events but only for the main branch
8+
push:
9+
branches: [ main ]
10+
pull_request:
11+
branches: [ main ]
12+
13+
# Allows you to run this workflow manually from the Actions tab
14+
workflow_dispatch:
15+
jobs:
16+
linter_name:
17+
name: runner / black formatter
18+
runs-on: ubuntu-latest
19+
steps:
20+
- uses: actions/checkout@v2
21+
- name: Check files using the black formatter
22+
uses: rickstaa/action-black@v1
23+
id: action_black
24+
with:
25+
black_args: "."
26+
- name: Annotate diff changes using reviewdog
27+
if: steps.action_black.outputs.is_formatted == 'true'
28+
uses: reviewdog/action-suggester@v1
29+
with:
30+
tool_name: blackfmt
31+
fail_on_error: true

.github/workflows/main.yml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
name: wemake-python-styleguide
2+
3+
on:
4+
push:
5+
branches: [ main ]
6+
pull_request:
7+
branches: [ main ]
8+
9+
workflow_dispatch:
10+
jobs:
11+
build:
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v2
15+
16+
- name: wemake-python-styleguide
17+
uses: wemake-services/wemake-python-styleguide@0.15.3
18+
env:
19+
GITHUB_TOKEN: ${{ github.token }}
20+
with:
21+
path: ${{ secrets.PACKAGE }}
22+
reporter: github-pr-review

.github/workflows/mypy.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# This is a basic workflow to help you get started with Actions
2+
3+
name: MyPy
4+
5+
# Controls when the workflow will run
6+
on:
7+
# Triggers the workflow on push or pull request events but only for the main branch
8+
push:
9+
branches: [ main ]
10+
pull_request:
11+
branches: [ main ]
12+
13+
# Allows you to run this workflow manually from the Actions tab
14+
workflow_dispatch:
15+
jobs:
16+
linter_name:
17+
name: runner / black formatter
18+
runs-on: ubuntu-latest
19+
steps:
20+
- uses: actions/checkout@v2
21+
- name: Run mypy with reviewdog
22+
# You may pin to the exact commit or the version.
23+
# uses: tsuyoshicho/action-mypy@2160e947d397ac0be7f02c911c3a5bea3f498575
24+
uses: tsuyoshicho/action-mypy@v3.1.0
25+
with:
26+
reporter: github-pr-review
27+
workdir: ${{ secrets.PACKAGE }}

.github/workflows/publish.yml

Lines changed: 0 additions & 33 deletions
This file was deleted.

.github/workflows/pylint.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: PyLint
2+
on:
3+
# Triggers the workflow on push or pull request events but only for the main branch
4+
push:
5+
branches: [ main ]
6+
pull_request:
7+
branches: [ main ]
8+
9+
# Allows you to run this workflow manually from the Actions tab
10+
workflow_dispatch:
11+
12+
jobs:
13+
pylint:
14+
name: runner / pylint
15+
runs-on: ubuntu-latest
16+
steps:
17+
- uses: actions/checkout@v2
18+
- uses: dciborow/action-pylint@0.0.3
19+
with:
20+
github_token: ${{ secrets.github_token }}
21+
# Change reviewdog reporter if you need [github-pr-check,github-check,github-pr-review].
22+
reporter: github-pr-review
23+
# Change reporter level if you need.
24+
# GitHub Status Check won't become failure with warning.
25+
workdir: ${{ secrets.PACKAGE }}
26+
level: warning

0 commit comments

Comments
 (0)