From e3a4aa38af4fe3dd00d3f6c6212a332e65e4e7e7 Mon Sep 17 00:00:00 2001 From: vinayak Date: Fri, 15 May 2020 22:43:31 +0530 Subject: [PATCH 1/5] Create black.yml --- .github/black.yml | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 .github/black.yml diff --git a/.github/black.yml b/.github/black.yml new file mode 100644 index 0000000..f803f4e --- /dev/null +++ b/.github/black.yml @@ -0,0 +1,26 @@ +# This is a basic workflow to help you get started with Actions + +name: CI + +# Controls when the action will run. Triggers the workflow on push or pull request +# events but only for the master branch +on: + push: + branches: [ master ] +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v1 + - uses: actions/setup-python@v1 + - run: pip install black + - run: black --check . + - name: If needed, commit black changes to a new pull request + if: failure() + run: | + black . + git config --global user.name github-actions + git config --global user.email '${GITHUB_ACTOR}@users.noreply.github.com' + git remote set-url origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/$GITHUB_REPOSITORY + git commit -am "fixup! Format Python code with psf/black push" + git push --force origin HEAD:$GITHUB_REF From 86a8e1e466d9119ae4954ae80f7b3abe7e072892 Mon Sep 17 00:00:00 2001 From: vinayak Date: Fri, 15 May 2020 22:45:02 +0530 Subject: [PATCH 2/5] Update black.yml --- .github/black.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/black.yml b/.github/black.yml index f803f4e..cae7fe0 100644 --- a/.github/black.yml +++ b/.github/black.yml @@ -1,6 +1,6 @@ # This is a basic workflow to help you get started with Actions -name: CI +name: black # Controls when the action will run. Triggers the workflow on push or pull request # events but only for the master branch From e9cd22901987749c23b1dca19e56952210413fc2 Mon Sep 17 00:00:00 2001 From: vinayak Date: Fri, 15 May 2020 22:47:21 +0530 Subject: [PATCH 3/5] Create black.yml --- .github/workflows/black.yml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 .github/workflows/black.yml diff --git a/.github/workflows/black.yml b/.github/workflows/black.yml new file mode 100644 index 0000000..2f580d3 --- /dev/null +++ b/.github/workflows/black.yml @@ -0,0 +1,19 @@ +name: black +on: [push] +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v1 # Use v1, NOT v2 + - uses: actions/setup-python@v1 + - run: pip install black + - run: black --check . + - name: If needed, commit black changes to a new pull request + if: failure() + run: | + black . + git config --global user.name github-actions + git config --global user.email '${GITHUB_ACTOR}@users.noreply.github.com' + git remote set-url origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/$GITHUB_REPOSITORY + git commit -am "fixup! Format Python code with psf/black push" + git push --force origin HEAD:$GITHUB_REF From c8f4f0eaf35641b39b8f07f71bfc7a3a110814c6 Mon Sep 17 00:00:00 2001 From: vinayak Date: Fri, 15 May 2020 22:48:12 +0530 Subject: [PATCH 4/5] Delete black.yml --- .github/black.yml | 26 -------------------------- 1 file changed, 26 deletions(-) delete mode 100644 .github/black.yml diff --git a/.github/black.yml b/.github/black.yml deleted file mode 100644 index cae7fe0..0000000 --- a/.github/black.yml +++ /dev/null @@ -1,26 +0,0 @@ -# This is a basic workflow to help you get started with Actions - -name: black - -# Controls when the action will run. Triggers the workflow on push or pull request -# events but only for the master branch -on: - push: - branches: [ master ] -jobs: - build: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v1 - - uses: actions/setup-python@v1 - - run: pip install black - - run: black --check . - - name: If needed, commit black changes to a new pull request - if: failure() - run: | - black . - git config --global user.name github-actions - git config --global user.email '${GITHUB_ACTOR}@users.noreply.github.com' - git remote set-url origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/$GITHUB_REPOSITORY - git commit -am "fixup! Format Python code with psf/black push" - git push --force origin HEAD:$GITHUB_REF From e9fb06b00ab7e3e252f65615e612164acacdbb87 Mon Sep 17 00:00:00 2001 From: vinayak Date: Fri, 15 May 2020 22:52:16 +0530 Subject: [PATCH 5/5] Update README.md --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 3dde2a0..742366e 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,8 @@ # GeeksForGeeksScrapper Scrapes [GeeksForGeeks](http://www.geeksforgeeks.org) and creates html & PDF for chosen category along with syntax highlighting for the code. +![black](https://github.com/itsvinayak/GeeksForGeeksScrapper/workflows/black/badge.svg?branch=master&event=push) + ## Screenshots Example of articles of C category as html: