Skip to content

create TREE structure in README by Zheng-Bote #2

create TREE structure in README by Zheng-Bote

create TREE structure in README by Zheng-Bote #2

name: Repo - Tree README.md
# description: document file-strcuture of repo
# README.md: <!-- readme-tree start --><!-- readme-tree end -->
# https://github.com/RavelloH/readme-tree
run-name: create TREE structure in README by ${{ github.actor }}
on:
workflow_dispatch:
push:
branches:
- main
paths:
- "README.md"
permissions:
checks: write
contents: write
jobs:
sync-assets:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Tree
uses: RavelloH/[email protected]
- name: Run test
uses: tj-actions/remark@v3
- name: Verify Changed files
uses: tj-actions/verify-changed-files@v20
id: verify_changed_files
with:
files: |
README.md
- name: README.md changed
if: steps.verify_changed_files.outputs.files_changed == 'true'
run: |
echo "README.md has uncommitted changes"
#exit 1
- name: commit and push
if: steps.verify_changed_files.outputs.files_changed == 'true'
uses: github-actions-x/[email protected]
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
push-branch: "main"
commit-message: "appended by Github Actions"
force-add: "true"
files: README.md
name: "github-actions[bot]"
email: "github-actions[bot]@users.noreply.github.com"