mirror of
https://github.com/hasura/graphql-engine.git
synced 2024-12-15 09:22:43 +03:00
bc999d8353
fixes https://github.com/hasura/lux/issues/3686 PR-URL: https://github.com/hasura/graphql-engine-mono/pull/3732 Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Divya Bhushan <11659160+divyabhushan@users.noreply.github.com> Co-authored-by: Rikin Kachhia <54616969+rikinsk@users.noreply.github.com> GitOrigin-RevId: b1bbd2d6bff206d7fae511629a9ef7a86a402891
35 lines
1.4 KiB
Bash
Executable File
35 lines
1.4 KiB
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
# Run this from root of repo - graphql-engine-mono
|
|
# ./docs/scripts/pandoc-auto-transform.sh "docs/docs"
|
|
|
|
# Make sure globstar is enabled
|
|
# shopt -s globstar
|
|
# cd docs
|
|
# for f in **/*.rst; do # Whitespace-safe and recursive
|
|
# # echo "../$1/${f%.*}"
|
|
# mkdir -pv -- "../$1/${f%/*}" && touch -- "../$1/${f%}.txt";
|
|
# pandoc "$f" -f rst -t gfm -s -o "../$1/${f%}.txt";
|
|
# done
|
|
# cd ..
|
|
|
|
|
|
# wc -l graphql/**/* > files.txt
|
|
# tree -f
|
|
|
|
# run on only one file
|
|
# ./docs/scripts/pandoc-auto-transform.sh "graphql/core/actions/create.rst"
|
|
# pandoc "docs-old/$1" -f rst -t gfm -s -o "docs/docs/${1%}.txt";
|
|
|
|
# run on list of files
|
|
# Ref: https://stackoverflow.com/a/424142/10208226 to get list of changed files in a commit
|
|
# git diff-tree --no-commit-id --name-only -r 90c8f75
|
|
# ./docs/scripts/pandoc-auto-transform.sh
|
|
# files=( "graphql/core/databases/ms-sql-server/index.rst" "graphql/core/databases/ms-sql-server/mutations/index.rst" "graphql/core/databases/ms-sql-server/mutations/insert.rst" "graphql/core/databases/ms-sql-server/mutations/upsert.rst" "graphql/core/databases/postgres/mutations/upsert.rst" )
|
|
# for f in "${files[@]}"; do
|
|
# mkdir -pv -- "docs/${f%/*}" && touch -- "docs/docs/${f%}.txt";
|
|
# pandoc "docs-old/$f" -f rst -t gfm -s -o "docs/docs/${f%}.txt";
|
|
# done
|
|
|
|
# mkdir -pv -- "$1/${f%/*}" && touch -- "$1/${f%}.txt";
|
|
# pandoc "$f" -f rst -t gfm -s -o "$1/${f%}.txt"; |