Skip to content

Commit 51686c4

Browse files
authored
feat: Add documentation website with guided tour and dashboard enhancements (#81)
* feat(tour): add guided tour overview page with steps and progress tracking - Implemented the tour overview page with a layout and description. - Added dynamic content for tour steps, including estimated time and completion status. - Integrated local storage to save and resume user progress in the tour. - Styled the tour overview page using Tailwind CSS with a responsive design. - Created global CSS variables for consistent theming across light and dark modes. - Configured Tailwind CSS for custom colors and fonts. - Set up TypeScript configuration for improved type safety and path aliasing. * Refactor CLI documentation and components - Updated command syntax in tour pages for running specific services, exporting logs, and health checks. - Modified styles for the congratulations banner and code block themes in global CSS. - Added a new PlatformInstallTabs component for platform-specific Azure Developer CLI installation commands. - Created new CLI reference pages for `restart`, `start`, and `stop` commands with usage examples and flags. - Introduced a new configuration file for expressive code styling. * fix(tour): update type definitions for previous and next steps to allow undefined values chore(tsconfig): add ignoreDeprecations option to suppress warnings style: improve layout and styling in generate-changelog script refactor(LogsMultiPaneView): clean up checkbox rendering and improve health status filter layout update: refresh dashboard screenshots for consistency * feat: Update styles and configurations for Azure-inspired theme - Refactored the highlights section in the Whats New page to use updated class names. - Enhanced global CSS with Azure-inspired color variables and font families. - Removed the old Tailwind configuration file as styles are now managed through global CSS. - Added a new serve.json file for routing and caching headers. * feat: Enhance documentation and testing processes with Playwright integration and updated guidelines * feat: Update dashboard screenshots for improved visual representation * feat: Add support for 'air' tool in tool registry and installation suggestions * chore: trigger workflow with updated permissions * fix: grant write permissions for gh-pages deployment * fix: deploy production to gh-pages branch to preserve PR previews * fix: update both site and base path for PR previews * fix: add .nojekyll to prevent Jekyll ignoring _astro folder * fix: use import.meta.env.BASE_URL for dynamic path handling in components * fix: improve dark mode styling for CLI Reference tables (v2) * fix: update dark mode table styles in CLI reference generator * chore: remove accidentally committed tmp folder, add to gitignore * revert: restore original CLI reference styles * Enhance CLI documentation and styles - Updated text color for better readability in multiple CLI command pages (mcp, notifications, reqs, restart, run, start, stop, version). - Improved background color and border styles for detailed documentation sections across CLI command pages. - Refactored flags table to use a consistent design and improved accessibility. - Added custom dark mode variant configuration in global CSS for better theme management. * Enhance CLI documentation with additional flags and descriptions - Updated `deps.astro` to include new flags: --verbose, --clean, --no-cache, --force. - Enhanced `health.astro` with detailed flags: --service, --stream, --interval, --output, --endpoint, --timeout, --all, --verbose, --profile, --log-level, --log-format, --save-profiles, --metrics, --metrics-port, --circuit-breaker, --circuit-break-count, --circuit-break-timeout, --rate-limit, --cache-ttl. - Added new flags to `info.astro`: --all, --cwd. - Expanded `logs.astro` with flags: --follow, --service, --tail, --since, --timestamps, --no-color, --level, --format, --file, --exclude, --no-builtins. - Updated `reqs.astro` with flags: --generate, --dry-run, --no-cache, --clear-cache, --fix. - Enhanced `restart.astro` with flags: --service, --all. - Added flags to `run.astro`: --service, --runtime, --env-file, --verbose, --dry-run, --web. - Updated `start.astro` with flags: --service, --all. - Enhanced `stop.astro` with flags: --service, --all. * fix: enhance screenshot tests for CI compatibility and visual regression * feat: add installation step for Azure Developer CLI in CI workflow
1 parent 3f0242c commit 51686c4

File tree

136 files changed

+46557
-381
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

136 files changed

+46557
-381
lines changed

.github/workflows/ci.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,9 @@ jobs:
5252
- name: Install govulncheck
5353
run: go install golang.org/x/vuln/cmd/govulncheck@latest
5454

55+
- name: Install Azure Developer CLI (azd)
56+
run: curl -fsSL https://aka.ms/install-azd.sh | bash
57+
5558
- name: Run preflight checks
5659
run: mage preflight
5760

.github/workflows/pr-build.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -300,12 +300,17 @@ jobs:
300300
SHORT_COMMIT=$(echo $COMMIT | cut -c1-7)
301301
# Use the branch where the scripts actually exist
302302
BRANCH="${{ github.ref_name }}"
303+
WEBSITE_URL="https://jongio.github.io/azd-app/pr/$PR_NUM/"
303304
304305
cat > ../instructions.md <<EOF
305306
## 🚀 Test This PR
306307
307308
A preview build (\`$VERSION\`) is ready for testing!
308309
310+
### 🌐 Website Preview
311+
312+
**Live Preview:** [$WEBSITE_URL]($WEBSITE_URL)
313+
309314
### One-Line Install (Recommended)
310315
311316
**PowerShell (Windows):**
Lines changed: 210 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,210 @@
1+
name: Sync Demo Template
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
paths:
8+
- 'cli/demo/**'
9+
workflow_dispatch:
10+
inputs:
11+
dry_run:
12+
description: 'Dry run (do not push changes)'
13+
required: false
14+
default: false
15+
type: boolean
16+
17+
env:
18+
DEMO_SOURCE_PATH: cli/demo
19+
TARGET_REPO: jongio/azd-app-demo
20+
21+
jobs:
22+
sync:
23+
name: Sync Demo to Target Repository
24+
runs-on: ubuntu-latest
25+
permissions:
26+
contents: read
27+
28+
steps:
29+
- name: Checkout source repository
30+
uses: actions/checkout@v4
31+
with:
32+
path: source
33+
34+
- name: Validate source files exist
35+
run: |
36+
echo "Validating source demo directory exists..."
37+
if [ ! -d "source/${{ env.DEMO_SOURCE_PATH }}" ]; then
38+
echo "ERROR: Demo source directory not found at ${{ env.DEMO_SOURCE_PATH }}"
39+
exit 1
40+
fi
41+
42+
echo "Source directory contents:"
43+
ls -la "source/${{ env.DEMO_SOURCE_PATH }}"
44+
45+
- name: Validate required files
46+
run: |
47+
DEMO_PATH="source/${{ env.DEMO_SOURCE_PATH }}"
48+
MISSING_FILES=""
49+
50+
# Check for required files
51+
REQUIRED_FILES=(
52+
"azure.yaml"
53+
".vscode/mcp.json"
54+
)
55+
56+
for file in "${REQUIRED_FILES[@]}"; do
57+
if [ ! -f "$DEMO_PATH/$file" ]; then
58+
MISSING_FILES="$MISSING_FILES\n - $file"
59+
else
60+
echo "✓ Found: $file"
61+
fi
62+
done
63+
64+
if [ -n "$MISSING_FILES" ]; then
65+
echo "ERROR: Required files missing:$MISSING_FILES"
66+
exit 1
67+
fi
68+
69+
echo ""
70+
echo "All required files present!"
71+
72+
- name: Checkout target repository
73+
uses: actions/checkout@v4
74+
with:
75+
repository: ${{ env.TARGET_REPO }}
76+
token: ${{ secrets.DEMO_REPO_PAT }}
77+
path: target
78+
fetch-depth: 0
79+
80+
- name: Sync demo files to target
81+
run: |
82+
DEMO_PATH="source/${{ env.DEMO_SOURCE_PATH }}"
83+
84+
echo "Syncing files from $DEMO_PATH to target repository..."
85+
86+
# Remove all files from target except .git
87+
cd target
88+
find . -maxdepth 1 -not -name '.git' -not -name '.' -exec rm -rf {} \;
89+
cd ..
90+
91+
# Copy all files from demo source to target root
92+
# Using rsync to handle hidden files properly
93+
rsync -av --exclude='.git' "$DEMO_PATH/" target/
94+
95+
echo ""
96+
echo "Target repository contents after sync:"
97+
ls -la target/
98+
99+
# Show .vscode directory
100+
if [ -d "target/.vscode" ]; then
101+
echo ""
102+
echo ".vscode directory contents:"
103+
ls -la target/.vscode/
104+
fi
105+
106+
- name: Check for changes
107+
id: changes
108+
working-directory: target
109+
run: |
110+
git add -A
111+
if git diff --staged --quiet; then
112+
echo "has_changes=false" >> $GITHUB_OUTPUT
113+
echo "No changes detected"
114+
else
115+
echo "has_changes=true" >> $GITHUB_OUTPUT
116+
echo "Changes detected:"
117+
git diff --staged --stat
118+
fi
119+
120+
- name: Commit and push changes
121+
if: steps.changes.outputs.has_changes == 'true' && (github.event.inputs.dry_run != 'true')
122+
working-directory: target
123+
run: |
124+
git config user.name "github-actions[bot]"
125+
git config user.email "github-actions[bot]@users.noreply.github.com"
126+
127+
# Get the source commit SHA for reference
128+
SOURCE_SHA="${{ github.sha }}"
129+
SHORT_SHA="${SOURCE_SHA:0:7}"
130+
131+
git commit -m "chore: sync demo template from azd-app ($SHORT_SHA)" \
132+
-m "Synced from: https://github.com/${{ github.repository }}/commit/$SOURCE_SHA" \
133+
-m "Workflow run: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}"
134+
135+
git push origin main
136+
137+
echo "✓ Changes pushed to ${{ env.TARGET_REPO }}"
138+
139+
- name: Dry run summary
140+
if: github.event.inputs.dry_run == 'true'
141+
run: |
142+
echo "DRY RUN: Changes were not pushed"
143+
echo "The following changes would have been made:"
144+
cd target
145+
git diff --staged --stat
146+
147+
smoke-test:
148+
name: Smoke Test Demo
149+
runs-on: ubuntu-latest
150+
needs: sync
151+
if: always() && needs.sync.result == 'success'
152+
153+
steps:
154+
- name: Checkout synced demo repository
155+
uses: actions/checkout@v4
156+
with:
157+
repository: ${{ env.TARGET_REPO }}
158+
token: ${{ secrets.DEMO_REPO_PAT }}
159+
160+
- name: Install azd
161+
run: curl -fsSL https://aka.ms/install-azd.sh | bash
162+
163+
- name: Install azd-app extension
164+
run: |
165+
# Add the extension registry and install azd-app
166+
azd extension source add jongio --location https://raw.githubusercontent.com/jongio/azd-app/main/registry.json --type url 2>/dev/null || true
167+
azd extension install jongio.azd.app --source jongio || echo "Extension may not be published yet, continuing..."
168+
169+
- name: Validate azure.yaml exists
170+
run: |
171+
if [ ! -f "azure.yaml" ]; then
172+
echo "ERROR: azure.yaml not found in demo repository"
173+
exit 1
174+
fi
175+
echo "✓ azure.yaml exists"
176+
cat azure.yaml
177+
178+
- name: Validate .vscode/mcp.json exists
179+
run: |
180+
if [ ! -f ".vscode/mcp.json" ]; then
181+
echo "ERROR: .vscode/mcp.json not found in demo repository"
182+
exit 1
183+
fi
184+
echo "✓ .vscode/mcp.json exists"
185+
cat .vscode/mcp.json
186+
187+
- name: Run azd app reqs (smoke test)
188+
continue-on-error: true
189+
run: |
190+
echo "Running: azd app reqs"
191+
azd app reqs || echo "Note: azd app reqs may fail if extension is not yet published"
192+
193+
- name: Run azd app deps (smoke test)
194+
continue-on-error: true
195+
run: |
196+
echo "Running: azd app deps"
197+
azd app deps || echo "Note: azd app deps may fail if extension is not yet published"
198+
199+
- name: Smoke test summary
200+
run: |
201+
echo ""
202+
echo "=========================================="
203+
echo "Smoke Test Summary"
204+
echo "=========================================="
205+
echo "✓ Demo repository structure validated"
206+
echo "✓ Required files present"
207+
echo ""
208+
echo "Note: Full azd app commands may not work until:"
209+
echo " 1. The azd-app extension is published"
210+
echo " 2. The demo project has all required dependencies"

0 commit comments

Comments
 (0)