<commit_before>name: Python package

on: [push]

jobs:
  tests:
    strategy:
      max-parallel: 4
      matrix:
        platform: [ubuntu-latest, windows-latest]
        python-version: [3.5, 3.6, 3.7]

    runs-on: ${{ matrix.platform }}

    steps:
    - uses: actions/checkout@master
    - name: Set up Python ${{ matrix.python-version }}
      uses: actions/setup-python@v1
      with:
        version: ${{ matrix.python-version }}
    - name: Install dependencies
      run: |
        python -m pip install --upgrade pip setuptools tox coverage
        python -m pip install -r requirements/test.txt
        python -m pip install -r requirements/setup.txt
    - name: Test with pytest
      run: |
        python -m pytest --cov wcmatch --cov-append tests
        python -m coverage html -d coverage
        python -m coverage report --show-missing

  lint:
    strategy:
      max-parallel: 4
      matrix:
        python-version: [3.7]

    runs-on: ubuntu-latest

    steps:
    - uses: actions/checkout@master
    - name: Set up Python ${{ matrix.python-version }}
      uses: actions/setup-python@v1
      with:
        version: ${{ matrix.python-version }}
    - name: Install dependencies
      run: |
        python -m pip install --upgrade pip setuptools
        python -m pip install -r requirements/lint.txt
    - name: Lint
      run: |
        python -m flake8 .

  documents:
    strategy:
      max-parallel: 4
      matrix:
        python-version: [3.7]

    runs-on: ubuntu-latest

    steps:
    - uses: actions/checkout@master
    - name: Set up Python ${{ matrix.python-version }}
      uses: actions/setup-python@v1
      with:
        version: ${{ matrix.python-version }}
    - name: Install dependencies
      run: |
        python -m pip install --upgrade pip setuptools
        python -m pip install -r requirements/docs.txt
    - name: Install Aspell
      run: |
        sudo apt-get install aspell aspell-en
    - name: Build documents
      run: |
        python -m mkdocs build --clean --verbose --strict
        python -m pyspelling
    - name: Deploy documents
      env:
        GH_TOKEN: ${{ secrets.GH_DEPLOY_KEY }}
        GH_USER: ${{ secrets.GH_USER }}
        GH_EMAIL: ${{ secrets.GH_EMAIL }}
      run: |
        git config user.name ${GH_USER}
        git config user.email "${GH_EMAIL}"
        git remote add gh-token "https://${GH_TOKEN}@github.com/facelessuser/wcmatch.git"
        git fetch gh-token && git fetch gh-token gh-pages:gh-pages
        python -m mkdocs gh-deploy -v --clean --remote-name gh-token
        git push gh-token gh-pages
<commit_msg>Dump context<commit_after>name: Python package

on: [push]

jobs:
  tests:
    strategy:
      max-parallel: 4
      matrix:
        platform: [ubuntu-latest, windows-latest]
        python-version: [3.5, 3.6, 3.7]

    runs-on: ${{ matrix.platform }}

    steps:
    - uses: actions/checkout@master
    - name: Set up Python ${{ matrix.python-version }}
      uses: actions/setup-python@v1
      with:
        version: ${{ matrix.python-version }}
    - name: Install dependencies
      run: |
        python -m pip install --upgrade pip setuptools tox coverage
        python -m pip install -r requirements/test.txt
        python -m pip install -r requirements/setup.txt
    - name: Test with pytest
      run: |
        python -m pytest --cov wcmatch --cov-append tests
        python -m coverage html -d coverage
        python -m coverage report --show-missing

  lint:
    strategy:
      max-parallel: 4
      matrix:
        python-version: [3.7]

    runs-on: ubuntu-latest

    steps:
    - uses: actions/checkout@master
    - name: Set up Python ${{ matrix.python-version }}
      uses: actions/setup-python@v1
      with:
        version: ${{ matrix.python-version }}
    - name: Install dependencies
      run: |
        python -m pip install --upgrade pip setuptools
        python -m pip install -r requirements/lint.txt
    - name: Lint
      run: |
        python -m flake8 .

  documents:
    strategy:
      max-parallel: 4
      matrix:
        python-version: [3.7]

    runs-on: ubuntu-latest

    steps:
    - uses: actions/checkout@master
    - name: Set up Python ${{ matrix.python-version }}
      uses: actions/setup-python@v1
      with:
        version: ${{ matrix.python-version }}
    - name: Install dependencies
      run: |
        python -m pip install --upgrade pip setuptools
        python -m pip install -r requirements/docs.txt
    - name: Install Aspell
      run: |
        sudo apt-get install aspell aspell-en
    - name: Build documents
      run: |
        python -m mkdocs build --clean --verbose --strict
        python -m pyspelling
    - name: Deploy documents
      env:
        GH_TOKEN: ${{ secrets.GH_DEPLOY_KEY }}
        GH_USER: ${{ secrets.GH_USER }}
        GH_EMAIL: ${{ secrets.GH_EMAIL }}
        CONTEXT: ${{ toJson(strategy) }}
      run: |
        echo "${CONTEXT}"
        git config user.name ${GH_USER}
        git config user.email "${GH_EMAIL}"
        git remote add gh-token "https://${GH_TOKEN}@github.com/facelessuser/wcmatch.git"
        git fetch gh-token && git fetch gh-token gh-pages:gh-pages
        python -m mkdocs gh-deploy -v --clean --remote-name gh-token
        git push gh-token gh-pages

{'fraction_non_alphanumeric': 0.11138426626323752, 'fraction_numerical': 0.006429652042360061, 'mean_word_length': 1.968013468013468, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2213272', 'n_tokens_mistral': 1675, 'n_tokens_neox': 1584, 'n_words': 467}