Skip to content

Commit

Permalink
Update Docc
Browse files Browse the repository at this point in the history
  • Loading branch information
jihoonahn committed Oct 30, 2023
1 parent 3fd199e commit 68b5b75
Showing 1 changed file with 11 additions and 10 deletions.
21 changes: 11 additions & 10 deletions .github/workflows/docc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,19 +36,20 @@ jobs:
run: >
rm -rf docs-out/.git;
rm -rf docs-out/main;
git tag -l --sort=-v:refname | grep -e "\d\+\.\d\+.0" | tail -n +6 | xargs -I {} rm -rf {};
for tag in $(echo "main"; git tag -l --sort=-v:refname | grep -e "\d\+\.\d\+.0" | head -6);
do
if [ -d "docs-out/$tag/data/documentation/tuistui" ]
rm -rf docs-out/latest;
for tag in $(echo "main"; echo "latest"; git tag | tail -n +94);
do
echo "⏳ Generating documentation for "$tag" release.";
if [ -d "docs-out/$tag" ]
then
echo "✅ Documentation for "$tag" already exists.";
else
echo "⏳ Generating documentation for "$tag" release.";
rm -rf "docs-out/$tag";
git checkout .;
git checkout "$tag";
if [ "$tag" == "latest" ]; then
git checkout -f "$(git tag | tail -n 1)";
else
git checkout -f "$tag";
fi
swift package \
--allow-writing-to-directory docs-out/"$tag" \
Expand Down

0 comments on commit 68b5b75

Please sign in to comment.