mirror of
https://hub.njuu.cf/TheAlgorithms/Python.git
synced 2023-10-11 13:06:12 +08:00
directory_writer: actions/checkout@v1 # Use v1, NOT v2 (#1799)
* directory_writer: actions/checkout@v1 # Use v1, NOT v2 (#1796 * updating DIRECTORY.md
This commit is contained in:
parent
2da98db4a7
commit
d547d0347b
15
.github/workflows/directory_writer.yml
vendored
15
.github/workflows/directory_writer.yml
vendored
@ -6,17 +6,18 @@ jobs:
|
|||||||
build:
|
build:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v1
|
- uses: actions/checkout@v1 # v1, NOT v2
|
||||||
- uses: actions/setup-python@v1
|
- uses: actions/setup-python@v1
|
||||||
with:
|
with:
|
||||||
python-version: 3.x
|
python-version: 3.x
|
||||||
- name: Write DIRECTORY.md
|
- name: Write DIRECTORY.md
|
||||||
run: |
|
run: |
|
||||||
scripts/build_directory_md.py 2>&1 | tee DIRECTORY.md
|
scripts/build_directory_md.py 2>&1 | tee DIRECTORY.md
|
||||||
git config --global user.name "GitHub Actions"
|
git config --global user.name github-actions
|
||||||
git config --global user.email "actions@github.com"
|
git config --global user.email '${GITHUB_ACTOR}@users.noreply.github.com'
|
||||||
git commit -am "updating DIRECTORY.md" || true
|
git remote set-url origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/$GITHUB_REPOSITORY
|
||||||
- name: Push DIRECTORY.md
|
- name: Update DIRECTORY.md
|
||||||
if: github.ref == 'refs/heads/master'
|
|
||||||
run: |
|
run: |
|
||||||
git push "https://${GITHUB_ACTOR}:${{secrets.GITHUB_TOKEN}}@github.com/$GITHUB_REPOSITORY.git" ${master} --force
|
git add DIRECTORY.md
|
||||||
|
git commit -am "updating DIRECTORY.md" || true
|
||||||
|
git push --force origin HEAD:$GITHUB_REF || true
|
Loading…
x
Reference in New Issue
Block a user