#!/bin/sh find content/docs/helm-charts -iname "*.md" -not -path "content/docs/helm-charts/_index*.md" -delete for p in "../helm-charts/"* ; do if [ ! -d $p ] ||[ ! -f $p/Chart.yaml ] ; then continue; fi name=$(basename "${p}") echo "== helm-charts/${name}:" if [ ! -f $p/README.md ]; then echo "not yet in markdown" else ln -s "../../../${p}/README.md" "content/docs/helm-charts/${name}.md" fi done