Skip to content

Commit 33169ea

Browse files
Copilothmottestad
andcommitted
Create copilot-setup-steps.yml workflow with caching and offline support
Co-authored-by: hmottestad <797185+hmottestad@users.noreply.github.com>
1 parent 4dc0dce commit 33169ea

1 file changed

Lines changed: 55 additions & 0 deletions

File tree

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
name: Copilot Setup Steps
2+
3+
on:
4+
workflow_dispatch: # Allow manual triggering
5+
workflow_call: # Allow being called by other workflows
6+
7+
permissions:
8+
contents: read
9+
10+
jobs:
11+
copilot-setup:
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v4
15+
16+
- name: Set up JDK
17+
uses: actions/setup-java@v4
18+
with:
19+
java-version: 11
20+
distribution: 'temurin'
21+
cache: maven
22+
23+
- name: Download all dependencies for offline work
24+
run: |
25+
# Download all runtime and test dependencies
26+
mvn -B --quiet dependency:go-offline
27+
28+
- name: Quick compile and install all modules
29+
run: |
30+
# Clean and install all modules to local repository for offline work
31+
mvn --quiet clean && mvn -B --quiet -T 2C install -Pquick
32+
33+
- name: Download additional test dependencies
34+
run: |
35+
# Download source dependencies for better IDE experience
36+
mvn -B --quiet dependency:resolve-sources
37+
38+
- name: Verify offline mode works
39+
run: |
40+
# Test that we can build offline after downloading dependencies
41+
echo "Testing offline build capability..."
42+
mvn -o -Pquick install | tail -50
43+
44+
- name: Setup complete - Ready for Copilot development
45+
run: |
46+
echo "✅ Repository setup complete!"
47+
echo "✅ JDK 11 installed and configured"
48+
echo "✅ Maven dependencies cached and available offline"
49+
echo "✅ Project built successfully with quick profile"
50+
echo ""
51+
echo "The environment is now ready for AI-assisted development with:"
52+
echo "- All Maven dependencies cached in ~/.m2/repository"
53+
echo "- Project successfully built and installable offline"
54+
echo "- Maven can run with '-o' flag for offline development"
55+
echo "- Use 'mvn -o -Pquick install' for fast offline builds"

0 commit comments

Comments
 (0)