-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding live example for github actions (#9)
* Automated markdown-index Documentation Co-authored-by: mmiranda <[email protected]>
- Loading branch information
Showing
3 changed files
with
80 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# This is a live example of using the markdown-index in your Github Actions. | ||
# Simply copy it to your own repo and make sure you change the working-directory | ||
name: live-example | ||
on: | ||
pull_request: | ||
push: | ||
branches: | ||
- main | ||
jobs: | ||
markdown-index: | ||
runs-on: ubuntu-latest | ||
defaults: | ||
run: | ||
working-directory: test | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- uses: satackey/[email protected] | ||
continue-on-error: true | ||
|
||
- name: Generate Markdown Index | ||
id: markdown-index | ||
run: docker run --rm --volume "$(pwd):/data" ghcr.io/mmiranda/markdown-index:latest --output live-example.md | ||
|
||
- uses: stefanzweifel/git-auto-commit-action@v4 | ||
with: | ||
commit_message: Automated markdown-index Documentation | ||
file_pattern: "**/*.md" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
--- | ||
generated-by: markdown-index | ||
--- | ||
# Table of Contents | ||
* [Root Level Markdown](#root-level-markdown) | ||
* [Level 1 Markdown](#level-1-markdown) | ||
* [Level 1.1 Markdown](#level-11-markdown) | ||
* [Level 2 Markdown](#level-2-markdown) | ||
* [this file has a single line](#this-file-has-a-single-line) | ||
* [Level 2 Markdown](#level-2-markdown-1) | ||
|
||
# Root Level Markdown {#root-level-markdown} | ||
|
||
This is a sample paragraph text for test purpose only. This paragraph will be used as an abstract on the global TOC. | ||
|
||
[Read more on the original file...](./README.md) | ||
|
||
# Level 1 Markdown {#level-1-markdown} | ||
|
||
This is a sample paragraph text for test purpose only. This paragraph will be used as an abstract on the global TOC. | ||
|
||
[Read more on the original file...](./folder1/README.md) | ||
|
||
## Level 1.1 Markdown {#level-11-markdown} | ||
|
||
This is a sample paragraph text for test purpose only. This paragraph will be used as an abstract on the global TOC. | ||
|
||
[Read more on the original file...](./folder1/folder11/README.md) | ||
|
||
# Level 2 Markdown {#level-2-markdown} | ||
|
||
This is a sample paragraph text for test purpose only. This paragraph will be used as an abstract on the global TOC. | ||
|
||
[Read more on the original file...](./folder2/README.md) | ||
|
||
# this file has a single line {#this-file-has-a-single-line} | ||
|
||
[Read more on the original file...](./single-line.md) | ||
|
||
# Level 2 Markdown {#level-2-markdown-1} | ||
|
||
This is a sample paragraph text for test purpose only. This paragraph will be ignored because we have an ABSTRACT section in the file | ||
|
||
[Read more on the original file...](./with-abstract/README.md) |