Skip to content

Commit 67ccb62

Browse files
Modernize GitHub Action to auto-generate DIRECTORY.md (TheAlgorithms#6308)
1 parent 981d73d commit 67ccb62

File tree

2 files changed

+33
-92
lines changed

2 files changed

+33
-92
lines changed
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: Generate Directory Markdown
2+
3+
on:
4+
push:
5+
branches: [master]
6+
workflow_dispatch:
7+
8+
permissions:
9+
contents: write
10+
11+
jobs:
12+
generate-directory:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- name: Checkout Repository
16+
uses: actions/checkout@v4
17+
18+
- name: Run Directory Tree Generator
19+
uses: DenizAltunkapan/directory-tree-generator@v2
20+
with:
21+
path: src
22+
extensions: .java
23+
show-extensions: false
24+
25+
- name: Commit and Push DIRECTORY.md
26+
run: |
27+
cat DIRECTORY.md
28+
git config --global user.name "$GITHUB_ACTOR"
29+
git config --global user.email "$GITHUB_ACTOR@users.noreply.github.com"
30+
git remote set-url origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/$GITHUB_REPOSITORY
31+
git add DIRECTORY.md
32+
git commit -am "Update directory" || true
33+
git push origin HEAD:$GITHUB_REF

.github/workflows/update_directory.yml

Lines changed: 0 additions & 92 deletions
This file was deleted.

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy