Skip to content

Commit

Permalink
add autoblack action (#352)
Browse files Browse the repository at this point in the history
  • Loading branch information
j08lue committed Mar 11, 2020
1 parent 5f0d198 commit 9ba09c9
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 1 deletion.
24 changes: 24 additions & 0 deletions .github/workflows/autoblack.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# GitHub Action that uses Black to reformat Python code (if needed) when doing a git push.
# If all Python code in the repo is compliant with Black then this Action does nothing.
# Otherwise, Black is run and its changes are committed to the repo.
# https://github.com/cclauss/autoblack

name: autoblack_push
on: [push]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v1
- run: pip install black
- run: black --check .
- name: If needed, commit black changes to a new pull request
if: failure()
run: |
black .
git config --global user.name github-actions
git config --global user.email '${GITHUB_ACTOR}@users.noreply.github.com'
git remote set-url origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/$GITHUB_REPOSITORY
git commit -am "fixup! Format Python code with psf/black push"
git push --force origin HEAD:$GITHUB_REF
2 changes: 1 addition & 1 deletion sentinelsat/sentinel.py
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ def query(
Ranges with no bounds (`orbitnumber=(None, None)`) will not be included in the query.
Multiple values for the same query parameter can be provided as sets and will be handled as
logical OR, e.g. `orbitnumber={16302, 1206}`.
logical OR, e.g. `orbitnumber={16302, 1206}`.
The time interval formats accepted by the `date` parameter can also be used with
any other parameters that expect time intervals (that is: 'beginposition', 'endposition',
Expand Down

0 comments on commit 9ba09c9

Please sign in to comment.