Skip to content

Commit 08c82e6

Browse files
Add code examples
0 parents  commit 08c82e6

283 files changed

Lines changed: 8728 additions & 0 deletions

File tree

Some content is hidden

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

.github/workflows/build-linux.yml

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
name: Build Examples (Linux)
2+
3+
on:
4+
push:
5+
branches: [ main, dev ]
6+
pull_request:
7+
branches: [ main, dev ]
8+
9+
jobs:
10+
build:
11+
name: Build Code Examples
12+
runs-on: ubuntu-latest
13+
14+
steps:
15+
- name: Checkout code
16+
uses: actions/checkout@v4
17+
18+
- name: Setup .NET 6.0
19+
uses: actions/setup-dotnet@v4
20+
with:
21+
dotnet-version: '6.0.x'
22+
23+
- name: Install Linux dependencies
24+
run: |
25+
sudo apt-get update
26+
sudo apt-get install -y ttf-mscorefonts-installer libgdiplus fontconfig
27+
sudo fc-cache -fv
28+
29+
- name: Restore dependencies
30+
run: dotnet restore GroupDocs.Conversion.LowCode.Examples.sln
31+
32+
- name: Build individual projects
33+
run: |
34+
echo "=== Building Individual Projects ==="
35+
find Examples -name "*.fsproj" -type f | sort | while read project; do
36+
echo "Building: $project"
37+
dotnet build "$project" --configuration Release --no-restore
38+
if [ $? -eq 0 ]; then
39+
echo "✓ Successfully built: $project"
40+
# Clean up bin and obj folders to save space
41+
project_dir=$(dirname "$project")
42+
rm -rf "$project_dir/bin" "$project_dir/obj"
43+
echo "✓ Cleaned up: $project_dir"
44+
else
45+
echo "✗ Failed to build: $project"
46+
exit 1
47+
fi
48+
done
49+
50+
- name: List all projects
51+
run: |
52+
echo "=== All Projects in Solution ==="
53+
find Examples -name "*.fsproj" -type f | sort
54+
echo "=== Total Projects ==="
55+
find Examples -name "*.fsproj" -type f | wc -l
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
name: Build Examples (Windows)
2+
3+
on:
4+
push:
5+
branches: [ main, dev ]
6+
pull_request:
7+
branches: [ main, dev ]
8+
9+
jobs:
10+
build-windows:
11+
name: Build Code Examples
12+
runs-on: windows-latest
13+
14+
steps:
15+
- name: Checkout code
16+
uses: actions/checkout@v4
17+
18+
- name: Setup .NET 6.0
19+
uses: actions/setup-dotnet@v4
20+
with:
21+
dotnet-version: '6.0.x'
22+
23+
- name: Restore dependencies
24+
run: dotnet restore GroupDocs.Conversion.LowCode.Examples.sln
25+
26+
- name: Build individual projects
27+
run: |
28+
echo "=== Building Individual Projects ==="
29+
Get-ChildItem -Path "Examples" -Recurse -Filter "*.fsproj" | Sort-Object FullName | ForEach-Object {
30+
$project = $_.FullName
31+
echo "Building: $project"
32+
dotnet build "$project" --configuration Release --no-restore
33+
if ($LASTEXITCODE -eq 0) {
34+
echo "✓ Successfully built: $project"
35+
# Clean up bin and obj folders to save space
36+
$projectDir = Split-Path -Parent $project
37+
if (Test-Path "$projectDir\bin") { Remove-Item "$projectDir\bin" -Recurse -Force }
38+
if (Test-Path "$projectDir\obj") { Remove-Item "$projectDir\obj" -Recurse -Force }
39+
echo "✓ Cleaned up: $projectDir"
40+
} else {
41+
echo "✗ Failed to build: $project"
42+
exit 1
43+
}
44+
}
45+
46+
- name: List all projects
47+
run: |
48+
echo "=== All Projects in Solution ==="
49+
Get-ChildItem -Path "Examples" -Recurse -Filter "*.fsproj" | ForEach-Object { $_.FullName } | Sort-Object
50+
echo "=== Total Projects ==="
51+
(Get-ChildItem -Path "Examples" -Recurse -Filter "*.fsproj").Count

0 commit comments

Comments
 (0)