Skip to content

Bump urllib3 from 1.26.9 to 1.26.18 #43

Bump urllib3 from 1.26.9 to 1.26.18

Bump urllib3 from 1.26.9 to 1.26.18 #43

Workflow file for this run

name: Pylint
on:
workflow_dispatch:
push:
branches:
- main
pull_request:
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.11"]
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pylint anybadge
- name: Download .pylintrc file
uses: suisei-cn/actions-download-file@v1.4.0
id: pylintrc
with:
url: "https://raw.githubusercontent.com/nlp-tlp/badges/main/.pylintrc"
- name: Run Pylint
run: |
pylint ${{ github.event.repository.name }} --output pylint.log --exit-zero
- name: Get Pylint score and create badge
run: |
PYLINT_SCORE=$(sed -n 's/^Your code has been rated at \([-0-9.]*\)\/.*/\1/p' pylint.log)
echo $PYLINT_SCORE
anybadge -l pylint --value=$PYLINT_SCORE -f ${{ github.event.repository.name }}-pylint-badge.svg 2=red 4=orange 8=yellow 10=green
- name: Push badge to badges repo
uses: dmnemec/copy_file_to_another_repo_action@main
env:
API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }}
with:
source_file: "${{ github.event.repository.name }}-pylint-badge.svg"
destination_repo: "nlp-tlp/badges"
user_email: "github-actions[bot]@users.noreply.github.com"
user_name: "github-actions[bot]"
commit_message: "Update ${{ github.event.repository.name }} Pylint badge"