<commit_before>name: CI

on:
  push:
    branches:    
      - master


jobs:
  build:

    runs-on: ubuntu-latest

    steps:
    - uses: actions/checkout@v1

    - name: install_python
      run: |
        sudo apt-get update -qy
        sudo apt-get install -y python3-dev python3-pip libxml2-dev libxslt-dev zlib1g-dev
        sudo pip3 install -r requirements.txt

    - name: build_c
      run: |
        python3 setup.py build
        sudo python3 setup.py install

    # Standard drop-in approach that should work for most people.
    - name: build_doc
      run: |
        cd docs
        make html
        cd ..

    # Publish built docs to gh-pages branch.
    # ===============================
    - name: Commit documentation changes
      run: |
        git clone https://github.com/libAtoms/matscipy.git --branch gh-pages --single-branch gh-pages
        cp -r docs/_build/html/* gh-pages/
        cd gh-pages
        git config --local user.email "<EMAIL>"
        git config --local user.name "<NAME>"
        git add .
        git commit -m "Update documentation" -a || true
        # The above command will fail if no changes were present, so we ignore
        # that.

    - name: Push changes
      uses: ad-m/github-push-action@master
      with:
        branch: gh-pages
        directory: gh-pages
        github_token: ${{ secrets.GITHUB_TOKEN }}
<commit_msg>CI: Added workflow for automatically publishing package on PyPI<commit_after>name: CI

on:
  push:
    branches:    
      - master


jobs:
  build:

    runs-on: ubuntu-latest

    steps:
    - uses: actions/checkout@v1

    - name: install_python
      run: |
        sudo apt-get update -qy
        sudo apt-get install -y python3-dev python3-pip libxml2-dev libxslt-dev zlib1g-dev
        sudo pip3 install -r requirements.txt

    - name: build_c
      run: |
        python3 setup.py build
        sudo python3 setup.py install

    # Standard drop-in approach that should work for most people.
    - name: build_doc
      run: |
        cd docs
        make html
        cd ..

    # Publish built docs to gh-pages branch.
    # ===============================
    - name: Commit documentation changes
      run: |
        git clone https://github.com/libAtoms/matscipy.git --branch gh-pages --single-branch gh-pages
        cp -r docs/_build/html/* gh-pages/
        cd gh-pages
        git config --local user.email "<EMAIL>"
        git config --local user.name "GitHub Action"
        git add .
        git commit -m "Update documentation" -a || true
        # The above command will fail if no changes were present, so we ignore
        # that.

    - name: Push changes
      uses: ad-m/github-push-action@master
      with:
        branch: gh-pages
        directory: gh-pages
        github_token: ${{ secrets.GITHUB_TOKEN }}

    - name: Publish package
      if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
      uses: pypa/gh-action-pypi-publish@master
      with:
        user: __token__
        password: ${{ secrets.pypi_password }}

{'fraction_non_alphanumeric': 0.11074812152891211, 'fraction_numerical': 0.005227049983665469, 'mean_word_length': 1.9161904761904762, 'pattern_counts': {'":': 0, '<': 6, '<?xml version=': 0, '>': 6, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 2}, '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': '3595089', 'n_tokens_mistral': 968, 'n_tokens_neox': 903, 'n_words': 284}