Docs (#16682)
**Description** <!-- Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change. --> ⚒️ Fixes # <!--(issue)--> **⚙️ Type of change** - [ ] ⚙️ Feature/App addition - [ ] 🪛 Bugfix - [ ] ⚠️ Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] 🔃 Refactor of current code **🧪 How Has This Been Tested?** <!-- Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration --> **📃 Notes:** <!-- Please enter any other relevant information here --> **✔️ Checklist:** - [ ] ⚖️ My code follows the style guidelines of this project - [ ] 👀 I have performed a self-review of my own code - [ ] #️⃣ I have commented my code, particularly in hard-to-understand areas - [ ] 📄 I have made corresponding changes to the documentation - [ ] ⚠️ My changes generate no new warnings - [ ] 🧪 I have added tests to this description that prove my fix is effective or that my feature works - [ ] ⬆️ I increased versions for any altered app according to semantic versioning **➕ App addition** If this PR is an app addition please make sure you have done the following. - [ ] 🪞 I have opened a PR on [truecharts/containers](https://github.com/truecharts/containers) adding the container to TrueCharts mirror repo. - [ ] 🖼️ I have added an icon in the Chart's root directory called `icon.png` --- _Please don't blindly check all the boxes. Read them and only check those that apply. Those checkboxes are there for the reviewer to see what is this all about and the status of this PR with a quick glance._
This commit is contained in:
@@ -186,11 +186,14 @@ jobs:
|
||||
echo "---"
|
||||
) > website/docs/charts/${train}/${chart}/container-security.md
|
||||
fi
|
||||
|
||||
echo "Keeping some docs safe..."
|
||||
# keep some docs safe
|
||||
mv -f website/docs/charts/${train}/${chart}/CHANGELOG.md tmp/website/docs/charts/${train}/${chart}/CHANGELOG.md || :
|
||||
mv -f website/docs/charts/${train}/${chart}/helm-security.md tmp/website/docs/charts/${train}/${chart}/helm-security.md || :
|
||||
mv -f website/docs/charts/${train}/${chart}/container-security.md tmp/website/docs/charts/${train}/${chart}/container-security.md || :
|
||||
|
||||
echo "Removing old docs and recreating based on charts repo..."
|
||||
# remove old docs everywhere and recreate based on charts repo
|
||||
rm -rf website/docs/charts/*/${chart} || :
|
||||
mkdir -p website/docs/charts/${train}/${chart} || echo "chart path already exists, continuing..."
|
||||
@@ -198,16 +201,19 @@ jobs:
|
||||
yes | cp -rf charts/${train}/${chart}/icon.png website/static/img/hotlink-ok/chart-icons/${chart}.png 2>/dev/null || :
|
||||
yes | cp -rf charts/${train}/${chart}/screenshots/* website/static/img/hotlink-ok/chart-screenshots/${chart}/ 2>/dev/null || :
|
||||
|
||||
echo "Copying back kept docs..."
|
||||
# Copy over kept documents
|
||||
mv -f tmp/website/docs/charts/${train}/${chart}/CHANGELOG.md website/docs/charts/${train}/${chart}/CHANGELOG.md 2>/dev/null || :
|
||||
mv -f tmp/website/docs/charts/${train}/${chart}/helm-security.md website/docs/charts/${train}/${chart}/helm-security.md 2>/dev/null || :
|
||||
mv -f tmp/website/docs/charts/${train}/${chart}/container-security.md website/docs/charts/${train}/${chart}/container-security.md 2>/dev/null || :
|
||||
|
||||
echo "Appending SCALE changelog to actual changelog..."
|
||||
# Append SCALE changelog to actual changelog
|
||||
sed -i '1d' "website/docs/charts/${train}/${chart}/CHANGELOG.md" || echo "failed to sed 1d changelog..."
|
||||
cat "charts/${train}/${chart}/app-changelog.md" | cat - "website/docs/charts/${train}/${chart}/CHANGELOG.md" > temp && mv temp "website/docs/charts/${train}/${chart}/CHANGELOG.md"
|
||||
sed -i '1s/^/---\ntitle: Changelog\n---\n\n/' "website/docs/charts/${train}/${chart}/CHANGELOG.md" || echo "failed to add changelog header..."
|
||||
|
||||
echo "Creating index.md..."
|
||||
touch website/docs/charts/${train}/${chart}/index.md
|
||||
(
|
||||
echo "---"
|
||||
@@ -228,6 +234,7 @@ jobs:
|
||||
echo "## Available Documentation" >> website/docs/charts/${train}/${chart}/index.md
|
||||
echo "" >> website/docs/charts/${train}/${chart}/index.md
|
||||
|
||||
echo "Iterating over all files in the docs directory..."
|
||||
# Iterate over all files in the docs directory
|
||||
for file in website/docs/charts/${train}/${chart}/*.md; do
|
||||
# Extract the file name and first line from each file
|
||||
|
||||
Reference in New Issue
Block a user