<commit_before>name: Package

on:
  release:
    types: [created]

jobs:
  build:

    runs-on: ${{ matrix.os }}
    strategy:
      matrix:
        python-version: [3.6, 3.7, 3.8, 3.9]
        os: [ubuntu-latest, macOS-latest, windows-latest]

    steps:
    - name: Switch branch
      uses: actions/checkout@v2
    - name: Set up Python ${{ matrix.python-version }}
      uses: actions/setup-python@v1
      with:
        python-version: ${{ matrix.python-version }}
    - name: Install Python dependencies
      run: |
        python -m pip install --upgrade pip
        pip install -r requirements.txt
    - name: Build crate
      run: cargo build --verbose
    - name: Test crate
      run: cargo test --verbose
# this needs to be moved to a separate workflow
# here it is run on the whole matrix and this fails
#   - name: Publish crate
#     run: cargo publish --token ${{ secrets.CRATES_TOKEN }}
    - name: Maturin build and publish
      run:
        maturin publish --no-sdist -u __token__ -i python
      env:
        MATURIN_PASSWORD: ${{ secrets.PYPI_TOKEN }}

# notes:
# - for test-pypi: maturin publish --no-sdist -u __token__ -i python -r https://test.pypi.org/legacy/
<commit_msg>update recipe, building manylinux was broken<commit_after>name: Build and publish wheels

on:
  release:
    types: [created]

jobs:
  build:

    runs-on: ${{ matrix.os }}
    strategy:
      matrix:
        os: [ubuntu-latest, macOS-latest, windows-latest]

    steps:
    - name: Checkout
      uses: actions/checkout@v2
    # - name: Build wheels
    #   uses: messense/maturin-action@v1
    #   with:
    #     maturin-version: latest
    #     manylinux: auto
    #     command: build
    #     args: --release
    - name: Publish wheels
      uses: messense/maturin-action@v1
      with:
        maturin-version: latest
        manylinux: auto
        command: publish
        args: --no-sdist -u __token__
      env:
        MATURIN_PASSWORD: ${{ secrets.PYPI_TOKEN }}

#       args: --no-sdist -u __token__ -r https://test.pypi.org/legacy/
#       MATURIN_PASSWORD: ${{ secrets.TEST_PYPI_TOKEN }}

{'fraction_non_alphanumeric': 0.1144349477682811, 'fraction_numerical': 0.006172839506172839, 'mean_word_length': 2.1779788838612366, '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': '1050552', 'n_tokens_mistral': 703, 'n_tokens_neox': 678, 'n_words': 192}