Update reader.py #21
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
name: readmrz | |
on: | |
pull_request: | |
branches: | |
- develop | |
- master | |
jobs: | |
build: | |
name: "Build on ${{ matrix.platform.name }} with Python ${{ matrix.python.version }}" | |
runs-on: ${{ matrix.platform.os }} | |
strategy: | |
matrix: | |
python: [ | |
{ | |
name: "cp37-cp37m", | |
version: "3.7" | |
}, | |
{ | |
name: "cp38-cp38", | |
version: "3.8" | |
}, | |
{ | |
name: "cp39-cp39", | |
version: "3.9" | |
}, | |
{ | |
name: "cp310-cp310", | |
version: "3.10" | |
}, | |
] | |
platform: [ | |
{ | |
os: "ubuntu-latest", | |
python-architecture: "x64", | |
name: "Linux x64" | |
}, | |
{ | |
os: "macOS-latest", | |
python-architecture: "x64", | |
name: "macOS x64" | |
}, | |
{ | |
os: "windows-latest", | |
python-architecture: "x86", | |
name: "Windows x86" | |
}, | |
{ | |
os: "windows-latest", | |
python-architecture: "x64", | |
name: "Windows x64" | |
} | |
] | |
fail-fast: false | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Install Python | |
uses: actions/setup-python@v2 | |
with: | |
python-version: ${{ matrix.python.version }} | |
architecture: ${{ matrix.platform.python-architecture }} | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install -r requirements.txt | |
- name: Lint with flake8 | |
run: | | |
pip install flake8 | |
flake8 . --count --max-complexity=10 --max-line-length=79 --statistics | |
- name: Lint with pylint | |
run: | | |
pip install pylint | |
pylint $(git ls-files '*.py') | |
- name: Install package | |
run: | | |
python setup.py build | |
python setup.py install | |
- name: Install tesseract on macOS | |
run: brew install tesseract | |
if: runner.os == 'macOS' | |
- name: Install tesseract on Linux | |
run: sudo apt-get install -y tesseract-ocr | |
if: runner.os == 'Linux' | |
- name: Install tesseract on Windows | |
uses: crazy-max/ghaction-chocolatey@v1.6.0 | |
with: | |
args: install --yes tesseract | |
if: runner.os == 'Windows' | |
- name: Set PATH variable on Windows | |
run: echo "C:\Program Files\Tesseract-OCR" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append | |
if: runner.os == 'Windows' | |
- name: Unit testing | |
run: python -m unittest test |