Skip to content

updated the workflow #30

updated the workflow

updated the workflow #30

Workflow file for this run

name: Deploy Combined Docs
on:
push:
branches: [ main ]
workflow_dispatch:
permissions:
contents: write
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Create site directory and clear cache
run: |
mkdir -p build/site
# Force clear any cached files
rm -rf aas-specifications idta-submodel-templates
- name: Create updated index.html
run: |
cat > build/site/index.html << 'EOF'
<!DOCTYPE html>

Check failure on line 28 in .github/workflows/deploy.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/deploy.yml

Invalid workflow file

You have an error in your yaml syntax on line 28
<html>
<head>
<meta charset="utf-8">
<title>Industrial Digital Twin Documentation</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<!-- Add cache control headers -->
<meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate">
<meta http-equiv="Pragma" content="no-cache">
<meta http-equiv="Expires" content="0">
<style>
body {
font-family: Arial, sans-serif;
line-height: 1.6;
max-width: 800px;
margin: 0 auto;
padding: 20px;
color: #333;
}
h1 {
border-bottom: 2px solid #0366d6;
padding-bottom: 10px;
color: #0d2f4f;
}
ul {
padding-left: 20px;
list-style-type: disc;
}
li {
margin-bottom: 15px;
font-size: 18px;
}
a {
color: #0366d6;
text-decoration: none;
font-weight: bold;
}
a:hover {
text-decoration: underline;
}
.test-banner {
background-color: #ffebee;
color: #c62828;
padding: 10px 15px;
border-radius: 4px;
margin: 20px 0;
font-weight: bold;
border-left: 5px solid #c62828;
}
.version-info {
font-size: 12px;
color: #666;
margin-top: 40px;
font-style: italic;
}
</style>
</head>
<body>
<h1>Industrial Digital Twin Documentation</h1>
<div class="test-banner">
THIS IS A TEST - UPDATED VERSION - DEPLOYED AT $(date)
</div>
<ul>
<li><a href="./aas-specifications/">AAS Specifications</a></li>
<li><a href="./idta-submodel-templates/">Submodel Templates</a></li>
</ul>
<div class="version-info">
Last updated: $(date)
</div>
</body>
</html>
EOF
echo "Created new index.html:"
cat build/site/index.html
- name: Copy other required files
run: |
touch build/site/.nojekyll
echo "industrialdigitaltwin.io" > build/site/CNAME
ls -la build/site/
- name: Download AAS Specifications site
run: |
mkdir -p build/site/aas-specifications
wget -q --no-check-certificate -r -np -nH --cut-dirs=1 --reject="index.html*" -P aas-specifications/ https://admin-shell-io.github.io/aas-specifications/
cp -r aas-specifications/* build/site/aas-specifications/ || echo "No files copied for aas-specifications"
echo "Contents of aas-specifications directory:"
ls -la aas-specifications/ || echo "No files found"
- name: Download Submodel Templates site
run: |
mkdir -p build/site/idta-submodel-templates
wget -q --no-check-certificate -r -np -nH --cut-dirs=1 --reject="index.html*" -P idta-submodel-templates/ https://admin-shell-io.github.io/idta-submodel-templates/
cp -r idta-submodel-templates/* build/site/idta-submodel-templates/ || echo "No files copied for idta-submodel-templates"
echo "Contents of idta-submodel-templates directory:"
ls -la idta-submodel-templates/ || echo "No files found"
- name: List deployed files
run: |
echo "Contents of build/site root:"
ls -la build/site/
echo "Contents of aas-specifications directory:"
ls -la build/site/aas-specifications/ || echo "Directory empty or not found"
echo "Contents of idta-submodel-templates directory:"
ls -la build/site/idta-submodel-templates/ || echo "Directory empty or not found"
- name: Deploy to GitHub Pages
uses: JamesIves/github-pages-deploy-action@v4
with:
folder: build/site
branch: gh-pages
clean: true
clean-exclude: |
.nojekyll
CNAME
force: true