-
Notifications
You must be signed in to change notification settings - Fork 177
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1134 from Nytelife26/chore/update
chore: modernize proselint
- Loading branch information
Showing
23 changed files
with
1,525 additions
and
208 deletions.
There are no files selected for viewing
This file was deleted.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
name: "CD: PyPI" | ||
on: | ||
release: | ||
types: [created] | ||
jobs: | ||
release: | ||
name: Release | ||
runs-on: ubuntu-latest | ||
defaults: | ||
run: | ||
shell: bash | ||
strategy: | ||
matrix: | ||
python: [3.9] | ||
steps: | ||
- name: "[INIT] Checkout repository" | ||
uses: actions/checkout@v2 | ||
- name: "[INIT] Install Python ${{ matrix.python }}" | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: ${{ matrix.python }} | ||
- name: "[INIT] Restore dependency cache" | ||
id: cache-restore | ||
uses: actions/cache@v2 | ||
with: | ||
path: ~/.cache/pip | ||
key: ${{ runner.os }}-py${{ matrix.python }}-${{ hashFiles('**/poetry.lock') }} | ||
- name: "[INIT] Install dependencies" | ||
if: ${{ !steps.cache-restore.outputs.cache-hit }} | ||
run: pip install poetry && poetry install | ||
- name: "[EXEC] Build" | ||
run: poetry build | ||
- name: "[EXEC] Publish to PyPI" | ||
run: poetry run twine upload dist/* | ||
env: | ||
TWINE_USERNAME: ${{ secrets.PYPI_USER }} | ||
TWINE_PASSWORD: ${{ secrets.PYPI_PASS }} |
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,35 @@ | ||
name: "CD: Site" | ||
on: | ||
release: | ||
types: [created] | ||
jobs: | ||
build-site: | ||
name: Build Site | ||
runs-on: ubuntu-latest | ||
defaults: | ||
run: | ||
shell: bash | ||
strategy: | ||
matrix: | ||
python: [3.9] | ||
ruby: [3.0.0] | ||
steps: | ||
- name: "[INIT] Checkout repository" | ||
uses: actions/checkout@v2 | ||
- name: "[INIT] Install Python ${{ matrix.python }}" | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: ${{ matrix.python }} | ||
- name: "[INIT] Install Ruby ${{ matrix.ruby }}" | ||
uses: ruby/setup-ruby@v1.70.1 | ||
with: | ||
ruby-version: ${{ matrix.ruby }} | ||
bundler-cache: true | ||
- name: "[EXEC] Insert demo" | ||
run: python scripts/insert_demo.py | ||
- name: "[EXEC] Build site" | ||
run: cd site && jekyll build | ||
- name: "[EXEC] Push to s3" | ||
run: s3_website push | ||
- name: "[POST] Verify crawl" | ||
run: "cd .. && wget --spider -e robots=off -w 1 -r -p http://www.proselint.com" |
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,23 @@ | ||
name: "CI: Danger" | ||
on: [pull_request] | ||
jobs: | ||
danger: | ||
name: Danger | ||
if: "!(contains(github.event.head_commit.message, '[skip_ci]'))" | ||
runs-on: ubuntu-latest | ||
defaults: | ||
run: | ||
shell: bash | ||
strategy: | ||
matrix: | ||
ruby: [3.0.0] | ||
steps: | ||
- name: "[INIT] Checkout repository" | ||
uses: actions/checkout@v2 | ||
- name: "[INIT] Install Ruby ${{ matrix.ruby }}" | ||
uses: ruby/setup-ruby@v1.70.1 | ||
with: | ||
ruby-version: ${{ matrix.ruby }} | ||
bundler-cache: true | ||
- name: "[EXEC] Run Danger" | ||
run: bundle exec danger |
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,79 @@ | ||
name: "CI: Lint & Test" | ||
on: [push, pull_request] | ||
jobs: | ||
lint: | ||
name: Lint | ||
if: "!(contains(github.event.head_commit.message, '[skip_ci]'))" | ||
runs-on: ubuntu-latest | ||
defaults: | ||
run: | ||
shell: bash | ||
strategy: | ||
matrix: | ||
python: [3.9] | ||
steps: | ||
- name: "[INIT] Checkout repository" | ||
uses: actions/checkout@v2 | ||
- name: "[INIT] Install Python ${{ matrix.python }}" | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: ${{ matrix.python }} | ||
- name: "[INIT] Restore dependency cache" | ||
id: cache-restore | ||
uses: actions/cache@v2 | ||
with: | ||
path: ~/.cache/pip | ||
key: ${{ runner.os }}-py${{ matrix.python }}-${{ hashFiles('**/poetry.lock') }} | ||
- name: "[INIT] Install dependencies" | ||
if: ${{ !steps.cache-restore.outputs.cache-hit }} | ||
run: pip install poetry && poetry install | ||
- name: "[EXEC] Lint" | ||
run: poetry run pycodestyle --config pyproject.toml && poetry run pydocstyle | ||
test-cover: | ||
name: Test & Cover | ||
if: "!(contains(github.event.head_commit.message, '[skip_ci]'))" | ||
runs-on: ubuntu-latest | ||
defaults: | ||
run: | ||
shell: bash | ||
strategy: | ||
matrix: | ||
python: [3.6, 3.7, 3.8, 3.9, pypy3] | ||
os: [ubuntu-latest, macos-latest, windows-latest] | ||
steps: | ||
- name: "[INIT] Checkout repository" | ||
uses: actions/checkout@v2 | ||
- name: "[INIT] Install Python ${{ matrix.python }}" | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: ${{ matrix.python }} | ||
- name: "[INIT] Restore dependency cache" | ||
id: cache-restore | ||
uses: actions/cache@v2 | ||
with: | ||
path: ~/.cache/pip | ||
key: ${{ runner.os }}-py${{ matrix.python }}-${{ hashFiles('**/poetry.lock') }} | ||
- name: "[INIT] Install dependencies" | ||
if: ${{ !steps.cache-restore.outputs.cache-hit }} | ||
run: pip install poetry && poetry install | ||
- name: "[EXEC] Test" | ||
run: poetry run coverage run -m pytest --continue-on-collection-errors | ||
- name: "[EXEC] Upload coverage to Coveralls" | ||
run: poetry run coveralls --service=github | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_TOKEN }} | ||
COVERALLS_FLAG_NAME: run-${{ matrix.os }}-py${{ matrix.python }} | ||
COVERALLS_PARALLEL: true | ||
cover: | ||
name: Finalize Coverage Report | ||
if: "!(contains(github.event.head_commit.message, '[skip_ci]'))" | ||
needs: test-cover | ||
runs-on: ubuntu-latest | ||
container: python:3-slim | ||
steps: | ||
- name: "[POST] Finalize Coveralls collection" | ||
run: pip3 install coveralls && coveralls --finish --service=github | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_TOKEN }} |
This file was deleted.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,11 @@ | ||
A guide to how you can contribute to proselint can be found at http://proselint.com/contributing. | ||
A guide to how you can contribute to proselint can be found on [our website]. | ||
|
||
Work on proselint happens over at http://github.com/amperser/proselint. To contribute, create a new branch off master and then open a pull request. Your code should run cleanly through pep8 and pep257 linters. Comments, bug reports, and other feedback can be provided through GitHub issues. | ||
Work on proselint happens over at [our GitHub]. To contribute, create a new | ||
branch off master and then open a pull request. Your code should run cleanly | ||
through `pycodestyle` and `pydocstyle` linters (pro tip \- outside of CI, | ||
use `pycodestyle --config=pyproject.toml && pydocstyle -se` for more | ||
descriptive information on what's causing your lint failures). Comments, | ||
bug reports, and other feedback can be provided through GitHub issues. | ||
|
||
[our website]: http://proselint.com/contributing | ||
[our GitHub]: http://github.com/amperser/proselint |
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 was deleted.
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
Oops, something went wrong.