Fix YAML syntax and update DB format in workflow
This commit is contained in:
15
.github/workflows/update-repo.yml
vendored
15
.github/workflows/update-repo.yml
vendored
@@ -37,9 +37,8 @@ jobs:
|
|||||||
cp hyprarch-repo.db.tar.gz hyprarch-repo.db
|
cp hyprarch-repo.db.tar.gz hyprarch-repo.db
|
||||||
cp hyprarch-repo.files.tar.gz hyprarch-repo.files
|
cp hyprarch-repo.files.tar.gz hyprarch-repo.files
|
||||||
|
|
||||||
- name: Generate Indices
|
- name: Generate Subfolder Index
|
||||||
run: |
|
run: |
|
||||||
# 1. Create the BASIC PYTHON-STYLE index for the x86_64 folder
|
|
||||||
cd x86_64
|
cd x86_64
|
||||||
echo "<html><head><title>Index of /x86_64/</title></head><body style='font-family: monospace;'>" > index.html
|
echo "<html><head><title>Index of /x86_64/</title></head><body style='font-family: monospace;'>" > index.html
|
||||||
echo "<h1>Index of /x86_64/</h1><hr><pre>" >> index.html
|
echo "<h1>Index of /x86_64/</h1><hr><pre>" >> index.html
|
||||||
@@ -53,10 +52,9 @@ jobs:
|
|||||||
done
|
done
|
||||||
echo "</pre><hr></body></html>" >> index.html
|
echo "</pre><hr></body></html>" >> index.html
|
||||||
|
|
||||||
# 2. Create YOUR SPECIFIC LANDING PAGE for the Root folder
|
- name: Generate Root Landing Page
|
||||||
cd ..
|
run: |
|
||||||
cat <<'EOF' > index.html
|
echo '<!DOCTYPE html>
|
||||||
<!DOCTYPE html>
|
|
||||||
<html>
|
<html>
|
||||||
<head>
|
<head>
|
||||||
<title>HyprArch Repository</title>
|
<title>HyprArch Repository</title>
|
||||||
@@ -85,8 +83,7 @@ Server = https://hyprarch-repo.stuple.net/$arch</pre>
|
|||||||
<p><small>Automated by GitHub Actions</small></p>
|
<p><small>Automated by GitHub Actions</small></p>
|
||||||
</div>
|
</div>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>' > index.html
|
||||||
EOF
|
|
||||||
|
|
||||||
- name: Commit and Push changes
|
- name: Commit and Push changes
|
||||||
run: |
|
run: |
|
||||||
@@ -94,7 +91,7 @@ EOF
|
|||||||
git config --global user.email "github-actions[bot]@users.noreply.github.com"
|
git config --global user.email "github-actions[bot]@users.noreply.github.com"
|
||||||
git add .
|
git add .
|
||||||
if ! git diff-index --quiet HEAD; then
|
if ! git diff-index --quiet HEAD; then
|
||||||
git commit -m "Fixed DB format and index indentation"
|
git commit -m "Fixed YAML syntax and DB format"
|
||||||
git push
|
git push
|
||||||
else
|
else
|
||||||
echo "Nothing to change."
|
echo "Nothing to change."
|
||||||
|
|||||||
Reference in New Issue
Block a user