ai-flow-dev 2.7.0 → 2.8.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -21
- package/README.md +573 -570
- package/package.json +74 -74
- package/prompts/backend/flow-build-phase-0.md +535 -535
- package/prompts/backend/flow-build-phase-1.md +626 -626
- package/prompts/backend/flow-build-phase-10.md +340 -340
- package/prompts/backend/flow-build-phase-2.md +573 -573
- package/prompts/backend/flow-build-phase-3.md +834 -834
- package/prompts/backend/flow-build-phase-4.md +554 -554
- package/prompts/backend/flow-build-phase-5.md +703 -703
- package/prompts/backend/flow-build-phase-6.md +524 -524
- package/prompts/backend/flow-build-phase-7.md +1001 -1001
- package/prompts/backend/flow-build-phase-8.md +1407 -1407
- package/prompts/backend/flow-build-phase-9.md +477 -477
- package/prompts/backend/flow-build.md +137 -137
- package/prompts/backend/flow-check-review.md +656 -20
- package/prompts/backend/flow-check-test.md +526 -14
- package/prompts/backend/flow-check.md +717 -67
- package/prompts/backend/flow-commit.md +88 -119
- package/prompts/backend/flow-docs-sync.md +354 -354
- package/prompts/backend/flow-finish.md +919 -0
- package/prompts/backend/flow-release.md +949 -0
- package/prompts/backend/flow-work-feature.md +61 -61
- package/prompts/backend/flow-work-fix.md +46 -46
- package/prompts/backend/flow-work-refactor.md +48 -48
- package/prompts/backend/flow-work-resume.md +34 -34
- package/prompts/backend/flow-work.md +1098 -1286
- package/prompts/desktop/flow-build-phase-0.md +359 -359
- package/prompts/desktop/flow-build-phase-1.md +295 -295
- package/prompts/desktop/flow-build-phase-10.md +357 -357
- package/prompts/desktop/flow-build-phase-2.md +282 -282
- package/prompts/desktop/flow-build-phase-3.md +291 -291
- package/prompts/desktop/flow-build-phase-4.md +308 -308
- package/prompts/desktop/flow-build-phase-5.md +269 -269
- package/prompts/desktop/flow-build-phase-6.md +350 -350
- package/prompts/desktop/flow-build-phase-7.md +297 -297
- package/prompts/desktop/flow-build-phase-8.md +541 -541
- package/prompts/desktop/flow-build-phase-9.md +439 -439
- package/prompts/desktop/flow-build.md +156 -156
- package/prompts/desktop/flow-check-review.md +656 -20
- package/prompts/desktop/flow-check-test.md +526 -14
- package/prompts/desktop/flow-check.md +717 -67
- package/prompts/desktop/flow-commit.md +88 -119
- package/prompts/desktop/flow-docs-sync.md +354 -354
- package/prompts/desktop/flow-finish.md +919 -0
- package/prompts/desktop/flow-release.md +662 -0
- package/prompts/desktop/flow-work-feature.md +61 -61
- package/prompts/desktop/flow-work-fix.md +46 -46
- package/prompts/desktop/flow-work-refactor.md +48 -48
- package/prompts/desktop/flow-work-resume.md +34 -34
- package/prompts/desktop/flow-work.md +1202 -1390
- package/prompts/frontend/flow-build-phase-0.md +425 -425
- package/prompts/frontend/flow-build-phase-1.md +626 -626
- package/prompts/frontend/flow-build-phase-10.md +33 -33
- package/prompts/frontend/flow-build-phase-2.md +573 -573
- package/prompts/frontend/flow-build-phase-3.md +782 -782
- package/prompts/frontend/flow-build-phase-4.md +554 -554
- package/prompts/frontend/flow-build-phase-5.md +703 -703
- package/prompts/frontend/flow-build-phase-6.md +524 -524
- package/prompts/frontend/flow-build-phase-7.md +1001 -1001
- package/prompts/frontend/flow-build-phase-8.md +872 -872
- package/prompts/frontend/flow-build-phase-9.md +94 -94
- package/prompts/frontend/flow-build.md +137 -137
- package/prompts/frontend/flow-check-review.md +656 -20
- package/prompts/frontend/flow-check-test.md +526 -14
- package/prompts/frontend/flow-check.md +717 -67
- package/prompts/frontend/flow-commit.md +88 -119
- package/prompts/frontend/flow-docs-sync.md +550 -550
- package/prompts/frontend/flow-finish.md +919 -0
- package/prompts/frontend/flow-release.md +519 -0
- package/prompts/frontend/flow-work-api.md +1547 -0
- package/prompts/frontend/flow-work-feature.md +61 -61
- package/prompts/frontend/flow-work-fix.md +38 -38
- package/prompts/frontend/flow-work-refactor.md +48 -48
- package/prompts/frontend/flow-work-resume.md +34 -34
- package/prompts/frontend/flow-work.md +1595 -1320
- package/prompts/mobile/flow-build-phase-0.md +425 -425
- package/prompts/mobile/flow-build-phase-1.md +626 -626
- package/prompts/mobile/flow-build-phase-10.md +32 -32
- package/prompts/mobile/flow-build-phase-2.md +573 -573
- package/prompts/mobile/flow-build-phase-3.md +782 -782
- package/prompts/mobile/flow-build-phase-4.md +554 -554
- package/prompts/mobile/flow-build-phase-5.md +703 -703
- package/prompts/mobile/flow-build-phase-6.md +524 -524
- package/prompts/mobile/flow-build-phase-7.md +1001 -1001
- package/prompts/mobile/flow-build-phase-8.md +888 -888
- package/prompts/mobile/flow-build-phase-9.md +90 -90
- package/prompts/mobile/flow-build.md +135 -135
- package/prompts/mobile/flow-check-review.md +656 -20
- package/prompts/mobile/flow-check-test.md +526 -14
- package/prompts/mobile/flow-check.md +717 -67
- package/prompts/mobile/flow-commit.md +88 -119
- package/prompts/mobile/flow-docs-sync.md +620 -620
- package/prompts/mobile/flow-finish.md +919 -0
- package/prompts/mobile/flow-release.md +751 -0
- package/prompts/mobile/flow-work-api.md +1500 -0
- package/prompts/mobile/flow-work-feature.md +61 -61
- package/prompts/mobile/flow-work-fix.md +46 -46
- package/prompts/mobile/flow-work-refactor.md +48 -48
- package/prompts/mobile/flow-work-resume.md +34 -34
- package/prompts/mobile/flow-work.md +1605 -1329
- package/prompts/shared/mermaid-guidelines.md +102 -102
- package/prompts/shared/scope-levels.md +114 -114
- package/prompts/shared/smart-skip-preflight.md +214 -214
- package/prompts/shared/story-points.md +55 -55
- package/prompts/shared/task-format.md +74 -74
- package/prompts/shared/task-summary-template.md +277 -277
- package/templates/AGENT.template.md +443 -443
- package/templates/backend/.clauderules.template +112 -112
- package/templates/backend/.cursorrules.template +102 -102
- package/templates/backend/README.template.md +2 -2
- package/templates/backend/ai-instructions.template.md +2 -2
- package/templates/backend/copilot-instructions.template.md +2 -2
- package/templates/backend/docs/api.template.md +320 -320
- package/templates/backend/docs/business-flows.template.md +97 -97
- package/templates/backend/docs/code-standards.template.md +2 -2
- package/templates/backend/docs/contributing.template.md +3 -3
- package/templates/backend/docs/data-model.template.md +520 -520
- package/templates/backend/docs/testing.template.md +2 -2
- package/templates/backend/project-brief.template.md +2 -2
- package/templates/backend/specs/configuration.template.md +2 -2
- package/templates/backend/specs/security.template.md +2 -2
- package/templates/desktop/.clauderules.template +112 -112
- package/templates/desktop/.cursorrules.template +102 -102
- package/templates/desktop/README.template.md +170 -170
- package/templates/desktop/ai-instructions.template.md +366 -366
- package/templates/desktop/copilot-instructions.template.md +140 -140
- package/templates/desktop/docs/docs/api.template.md +320 -320
- package/templates/desktop/docs/docs/architecture.template.md +724 -724
- package/templates/desktop/docs/docs/business-flows.template.md +102 -102
- package/templates/desktop/docs/docs/code-standards.template.md +792 -792
- package/templates/desktop/docs/docs/contributing.template.md +149 -149
- package/templates/desktop/docs/docs/data-model.template.md +520 -520
- package/templates/desktop/docs/docs/operations.template.md +720 -720
- package/templates/desktop/docs/docs/testing.template.md +722 -722
- package/templates/desktop/project-brief.template.md +150 -150
- package/templates/desktop/specs/specs/configuration.template.md +121 -121
- package/templates/desktop/specs/specs/security.template.md +392 -392
- package/templates/frontend/README.template.md +2 -2
- package/templates/frontend/ai-instructions.template.md +2 -2
- package/templates/frontend/docs/api-integration.template.md +362 -362
- package/templates/frontend/docs/components.template.md +2 -2
- package/templates/frontend/docs/error-handling.template.md +360 -360
- package/templates/frontend/docs/operations.template.md +107 -107
- package/templates/frontend/docs/performance.template.md +124 -124
- package/templates/frontend/docs/pwa.template.md +119 -119
- package/templates/frontend/docs/state-management.template.md +2 -2
- package/templates/frontend/docs/styling.template.md +2 -2
- package/templates/frontend/docs/testing.template.md +2 -2
- package/templates/frontend/project-brief.template.md +2 -2
- package/templates/frontend/specs/accessibility.template.md +95 -95
- package/templates/frontend/specs/configuration.template.md +2 -2
- package/templates/frontend/specs/security.template.md +175 -175
- package/templates/fullstack/README.template.md +252 -252
- package/templates/fullstack/ai-instructions.template.md +444 -444
- package/templates/fullstack/project-brief.template.md +157 -157
- package/templates/fullstack/specs/configuration.template.md +340 -340
- package/templates/mobile/README.template.md +167 -167
- package/templates/mobile/ai-instructions.template.md +196 -196
- package/templates/mobile/docs/app-store.template.md +135 -135
- package/templates/mobile/docs/architecture.template.md +63 -63
- package/templates/mobile/docs/native-features.template.md +94 -94
- package/templates/mobile/docs/navigation.template.md +59 -59
- package/templates/mobile/docs/offline-strategy.template.md +65 -65
- package/templates/mobile/docs/permissions.template.md +56 -56
- package/templates/mobile/docs/state-management.template.md +85 -85
- package/templates/mobile/docs/testing.template.md +109 -109
- package/templates/mobile/project-brief.template.md +69 -69
- package/templates/mobile/specs/build-configuration.template.md +91 -91
- package/templates/mobile/specs/deployment.template.md +92 -92
- package/templates/work.template.md +61 -47
|
@@ -1,297 +1,297 @@
|
|
|
1
|
-
## PHASE 7: Packaging & Deployment (15-20 min)
|
|
2
|
-
|
|
3
|
-
> **Order for this phase:** 7.1 → 7.2 → 7.3 → 7.4 → 7.5
|
|
4
|
-
|
|
5
|
-
### Objective
|
|
6
|
-
|
|
7
|
-
Define how the desktop application will be packaged, distributed, and deployed to end users.
|
|
8
|
-
|
|
9
|
-
---
|
|
10
|
-
|
|
11
|
-
## 7.1 Packaging Format
|
|
12
|
-
|
|
13
|
-
```
|
|
14
|
-
How will you package your application?
|
|
15
|
-
|
|
16
|
-
A) ☕ Executable JAR - Simple distribution
|
|
17
|
-
- java -jar myapp.jar
|
|
18
|
-
- Requires JRE installed
|
|
19
|
-
- Cross-platform
|
|
20
|
-
- Best for: Developers, technical users
|
|
21
|
-
|
|
22
|
-
B) 🚀 Native Executable - Platform-specific
|
|
23
|
-
- Windows: .exe
|
|
24
|
-
- macOS: .app
|
|
25
|
-
- Linux: binary
|
|
26
|
-
- Includes JRE (self-contained)
|
|
27
|
-
- Tools: jpackage (Java 14+), GraalVM native-image
|
|
28
|
-
|
|
29
|
-
C) 💼 Installer Package - Professional distribution
|
|
30
|
-
- Windows: .msi, .exe (NSIS, Inno Setup, WiX)
|
|
31
|
-
- macOS: .dmg, .pkg
|
|
32
|
-
- Linux: .deb, .rpm, AppImage, Snap, Flatpak
|
|
33
|
-
- Includes JRE, auto-updates, shortcuts
|
|
34
|
-
|
|
35
|
-
D) ☁️ Java Web Start (deprecated) - Legacy
|
|
36
|
-
- JNLP files
|
|
37
|
-
- Not recommended for new apps
|
|
38
|
-
|
|
39
|
-
Your primary packaging: __
|
|
40
|
-
Your secondary packaging: __
|
|
41
|
-
```
|
|
42
|
-
|
|
43
|
-
---
|
|
44
|
-
|
|
45
|
-
## 7.2 Build Configuration
|
|
46
|
-
|
|
47
|
-
**For Maven:**
|
|
48
|
-
|
|
49
|
-
```xml
|
|
50
|
-
<!-- Maven Assembly Plugin - Fat JAR -->
|
|
51
|
-
<plugin>
|
|
52
|
-
<artifactId>maven-assembly-plugin</artifactId>
|
|
53
|
-
<configuration>
|
|
54
|
-
<archive>
|
|
55
|
-
<manifest>
|
|
56
|
-
<mainClass>com.company.app.Main</mainClass>
|
|
57
|
-
</manifest>
|
|
58
|
-
</archive>
|
|
59
|
-
<descriptorRefs>
|
|
60
|
-
<descriptorRef>jar-with-dependencies</descriptorRef>
|
|
61
|
-
</descriptorRefs>
|
|
62
|
-
</configuration>
|
|
63
|
-
</plugin>
|
|
64
|
-
|
|
65
|
-
<!-- Maven Shade Plugin - Fat JAR (alternative) -->
|
|
66
|
-
<plugin>
|
|
67
|
-
<groupId>org.apache.maven.plugins</groupId>
|
|
68
|
-
<artifactId>maven-shade-plugin</artifactId>
|
|
69
|
-
<executions>
|
|
70
|
-
<execution>
|
|
71
|
-
<phase>package</phase>
|
|
72
|
-
<goals>
|
|
73
|
-
<goal>shade</goal>
|
|
74
|
-
</goals>
|
|
75
|
-
</execution>
|
|
76
|
-
</executions>
|
|
77
|
-
</plugin>
|
|
78
|
-
```
|
|
79
|
-
|
|
80
|
-
**For Gradle:**
|
|
81
|
-
|
|
82
|
-
```groovy
|
|
83
|
-
// Fat JAR
|
|
84
|
-
jar {
|
|
85
|
-
manifest {
|
|
86
|
-
attributes 'Main-Class': 'com.company.app.Main'
|
|
87
|
-
}
|
|
88
|
-
from {
|
|
89
|
-
configurations.runtimeClasspath.collect {
|
|
90
|
-
it.isDirectory() ? it : zipTree(it)
|
|
91
|
-
}
|
|
92
|
-
}
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
// Or use Shadow plugin
|
|
96
|
-
plugins {
|
|
97
|
-
id 'com.github.johnrengelman.shadow' version '8.1.1'
|
|
98
|
-
}
|
|
99
|
-
```
|
|
100
|
-
|
|
101
|
-
**For Ant (NetBeans):**
|
|
102
|
-
|
|
103
|
-
```xml
|
|
104
|
-
<target name="jar" depends="compile">
|
|
105
|
-
<jar destfile="dist/myapp.jar" basedir="build/classes">
|
|
106
|
-
<manifest>
|
|
107
|
-
<attribute name="Main-Class" value="com.company.app.Main"/>
|
|
108
|
-
<attribute name="Class-Path" value="lib/dependency.jar"/>
|
|
109
|
-
</manifest>
|
|
110
|
-
</jar>
|
|
111
|
-
</target>
|
|
112
|
-
```
|
|
113
|
-
|
|
114
|
-
---
|
|
115
|
-
|
|
116
|
-
## 7.3 Native Packaging
|
|
117
|
-
|
|
118
|
-
**Using jpackage (Java 14+):**
|
|
119
|
-
|
|
120
|
-
```
|
|
121
|
-
jpackage --input target/ \
|
|
122
|
-
--name MyApp \
|
|
123
|
-
--main-jar myapp.jar \
|
|
124
|
-
--main-class com.company.app.Main \
|
|
125
|
-
--type [exe|dmg|deb|rpm|app-image] \
|
|
126
|
-
--icon src/main/resources/icon.ico \
|
|
127
|
-
--app-version 1.0.0 \
|
|
128
|
-
--vendor "Company Name" \
|
|
129
|
-
--copyright "Copyright 2025" \
|
|
130
|
-
--description "My Desktop Application"
|
|
131
|
-
|
|
132
|
-
Platform-specific options:
|
|
133
|
-
- Windows: --win-dir-chooser, --win-menu, --win-shortcut
|
|
134
|
-
- macOS: --mac-package-identifier com.company.app, --mac-sign
|
|
135
|
-
- Linux: --linux-shortcut, --linux-menu-group
|
|
136
|
-
```
|
|
137
|
-
|
|
138
|
-
**Using GraalVM Native Image:**
|
|
139
|
-
|
|
140
|
-
```bash
|
|
141
|
-
native-image -jar myapp.jar \
|
|
142
|
-
--no-fallback \
|
|
143
|
-
-H:Name=myapp \
|
|
144
|
-
-H:+ReportExceptionStackTraces
|
|
145
|
-
|
|
146
|
-
Benefits:
|
|
147
|
-
- Instant startup (no JVM warmup)
|
|
148
|
-
- Lower memory footprint
|
|
149
|
-
- No JRE required
|
|
150
|
-
Limitations:
|
|
151
|
-
- Reflection requires configuration
|
|
152
|
-
- Dynamic class loading limited
|
|
153
|
-
- Build time longer
|
|
154
|
-
```
|
|
155
|
-
|
|
156
|
-
**Third-party tools:**
|
|
157
|
-
|
|
158
|
-
```
|
|
159
|
-
A) Launch4j (Windows .exe wrapper)
|
|
160
|
-
- Wraps JAR in .exe
|
|
161
|
-
- JRE bundling
|
|
162
|
-
- Icon, splash screen
|
|
163
|
-
|
|
164
|
-
B) exe4j (Commercial Windows wrapper)
|
|
165
|
-
- Professional .exe generation
|
|
166
|
-
- Code signing support
|
|
167
|
-
|
|
168
|
-
C) install4j (Commercial multi-platform)
|
|
169
|
-
- Windows, macOS, Linux
|
|
170
|
-
- Auto-updates, licensing
|
|
171
|
-
|
|
172
|
-
Your choice: __
|
|
173
|
-
```
|
|
174
|
-
|
|
175
|
-
---
|
|
176
|
-
|
|
177
|
-
## 7.4 Distribution & Installation
|
|
178
|
-
|
|
179
|
-
```
|
|
180
|
-
How will users install your application?
|
|
181
|
-
|
|
182
|
-
A) 📦 Download from website
|
|
183
|
-
- Direct download link
|
|
184
|
-
- Manual installation
|
|
185
|
-
- No auto-updates
|
|
186
|
-
|
|
187
|
-
B) 🏪 App Store distribution
|
|
188
|
-
- Windows: Microsoft Store
|
|
189
|
-
- macOS: Mac App Store
|
|
190
|
-
- Linux: Snap Store, Flathub
|
|
191
|
-
- Requires app signing, review process
|
|
192
|
-
|
|
193
|
-
C) 📦 Package managers
|
|
194
|
-
- Windows: Chocolatey, Winget
|
|
195
|
-
- macOS: Homebrew
|
|
196
|
-
- Linux: apt, yum, pacman
|
|
197
|
-
|
|
198
|
-
D) 🔄 Auto-update system
|
|
199
|
-
- Check for updates on launch
|
|
200
|
-
- Download and install updates
|
|
201
|
-
- Libraries: Update4j, AutoUpdater
|
|
202
|
-
|
|
203
|
-
Your distribution method: __
|
|
204
|
-
|
|
205
|
-
Installation options:
|
|
206
|
-
- Install for all users vs current user?
|
|
207
|
-
- Desktop shortcut?
|
|
208
|
-
- Start menu entry?
|
|
209
|
-
- Auto-start on login?
|
|
210
|
-
- File associations?
|
|
211
|
-
```
|
|
212
|
-
|
|
213
|
-
---
|
|
214
|
-
|
|
215
|
-
## 7.5 Code Signing & Security
|
|
216
|
-
|
|
217
|
-
```
|
|
218
|
-
Will you sign your application?
|
|
219
|
-
|
|
220
|
-
**Windows:**
|
|
221
|
-
A) ✅ Code signing certificate
|
|
222
|
-
- .pfx/.p12 certificate
|
|
223
|
-
- Prevents "Unknown publisher" warnings
|
|
224
|
-
- Required for SmartScreen reputation
|
|
225
|
-
- Tools: SignTool.exe
|
|
226
|
-
|
|
227
|
-
B) ❌ No signing (development only)
|
|
228
|
-
|
|
229
|
-
**macOS:**
|
|
230
|
-
A) ✅ Apple Developer ID certificate
|
|
231
|
-
- Required for distribution outside App Store
|
|
232
|
-
- Gatekeeper approval
|
|
233
|
-
- Notarization (macOS 10.15+)
|
|
234
|
-
- Tools: codesign, xcrun altool
|
|
235
|
-
|
|
236
|
-
B) ❌ No signing (development only)
|
|
237
|
-
|
|
238
|
-
**Linux:**
|
|
239
|
-
- GPG signing for repositories
|
|
240
|
-
- AppImage signatures
|
|
241
|
-
|
|
242
|
-
Your signing strategy: __
|
|
243
|
-
|
|
244
|
-
**Distribution Security:**
|
|
245
|
-
- Provide checksums? (SHA-256)
|
|
246
|
-
- HTTPS downloads only?
|
|
247
|
-
- Signature verification instructions?
|
|
248
|
-
```
|
|
249
|
-
|
|
250
|
-
---
|
|
251
|
-
|
|
252
|
-
### Phase 7 Output
|
|
253
|
-
|
|
254
|
-
```
|
|
255
|
-
📋 PHASE 7 SUMMARY:
|
|
256
|
-
|
|
257
|
-
Packaging Format: [Executable JAR / Native executable / Installer]
|
|
258
|
-
Build Tool: [Maven / Gradle / Ant]
|
|
259
|
-
Native Packaging: [jpackage / GraalVM / Launch4j / exe4j]
|
|
260
|
-
Distribution: [Website download / App Store / Package manager / Auto-update]
|
|
261
|
-
Platform Packages:
|
|
262
|
-
- Windows: [.exe, .msi]
|
|
263
|
-
- macOS: [.app, .dmg, .pkg]
|
|
264
|
-
- Linux: [.deb, .rpm, AppImage]
|
|
265
|
-
Code Signing: [Yes - Windows/macOS / No]
|
|
266
|
-
Installation Options: [Desktop shortcut, Start menu, File associations]
|
|
267
|
-
|
|
268
|
-
Is this correct? (Yes/No)
|
|
269
|
-
```
|
|
270
|
-
|
|
271
|
-
---
|
|
272
|
-
|
|
273
|
-
### 📄 Generate Build Scripts
|
|
274
|
-
|
|
275
|
-
**Generate Maven packaging configuration**
|
|
276
|
-
**Generate Gradle packaging configuration**
|
|
277
|
-
**Generate jpackage script (shell/bat)**
|
|
278
|
-
**Generate distribution README**
|
|
279
|
-
|
|
280
|
-
Update `docs/DEPLOYMENT.md`:
|
|
281
|
-
|
|
282
|
-
- Build instructions
|
|
283
|
-
- Packaging process
|
|
284
|
-
- Distribution methods
|
|
285
|
-
- Installation guide
|
|
286
|
-
- Code signing procedures
|
|
287
|
-
|
|
288
|
-
---
|
|
289
|
-
|
|
290
|
-
**Next Phase:** Phase 8 - Project Setup & Final Docs (10-15 min)
|
|
291
|
-
|
|
292
|
-
Read: `.ai-flow/prompts/desktop/flow-build-phase-8.md`
|
|
293
|
-
|
|
294
|
-
---
|
|
295
|
-
|
|
296
|
-
**Last Updated:** 2025-02-03
|
|
297
|
-
**Version:** 1.0.0
|
|
1
|
+
## PHASE 7: Packaging & Deployment (15-20 min)
|
|
2
|
+
|
|
3
|
+
> **Order for this phase:** 7.1 → 7.2 → 7.3 → 7.4 → 7.5
|
|
4
|
+
|
|
5
|
+
### Objective
|
|
6
|
+
|
|
7
|
+
Define how the desktop application will be packaged, distributed, and deployed to end users.
|
|
8
|
+
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
## 7.1 Packaging Format
|
|
12
|
+
|
|
13
|
+
```
|
|
14
|
+
How will you package your application?
|
|
15
|
+
|
|
16
|
+
A) ☕ Executable JAR - Simple distribution
|
|
17
|
+
- java -jar myapp.jar
|
|
18
|
+
- Requires JRE installed
|
|
19
|
+
- Cross-platform
|
|
20
|
+
- Best for: Developers, technical users
|
|
21
|
+
|
|
22
|
+
B) 🚀 Native Executable - Platform-specific
|
|
23
|
+
- Windows: .exe
|
|
24
|
+
- macOS: .app
|
|
25
|
+
- Linux: binary
|
|
26
|
+
- Includes JRE (self-contained)
|
|
27
|
+
- Tools: jpackage (Java 14+), GraalVM native-image
|
|
28
|
+
|
|
29
|
+
C) 💼 Installer Package - Professional distribution
|
|
30
|
+
- Windows: .msi, .exe (NSIS, Inno Setup, WiX)
|
|
31
|
+
- macOS: .dmg, .pkg
|
|
32
|
+
- Linux: .deb, .rpm, AppImage, Snap, Flatpak
|
|
33
|
+
- Includes JRE, auto-updates, shortcuts
|
|
34
|
+
|
|
35
|
+
D) ☁️ Java Web Start (deprecated) - Legacy
|
|
36
|
+
- JNLP files
|
|
37
|
+
- Not recommended for new apps
|
|
38
|
+
|
|
39
|
+
Your primary packaging: __
|
|
40
|
+
Your secondary packaging: __
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
---
|
|
44
|
+
|
|
45
|
+
## 7.2 Build Configuration
|
|
46
|
+
|
|
47
|
+
**For Maven:**
|
|
48
|
+
|
|
49
|
+
```xml
|
|
50
|
+
<!-- Maven Assembly Plugin - Fat JAR -->
|
|
51
|
+
<plugin>
|
|
52
|
+
<artifactId>maven-assembly-plugin</artifactId>
|
|
53
|
+
<configuration>
|
|
54
|
+
<archive>
|
|
55
|
+
<manifest>
|
|
56
|
+
<mainClass>com.company.app.Main</mainClass>
|
|
57
|
+
</manifest>
|
|
58
|
+
</archive>
|
|
59
|
+
<descriptorRefs>
|
|
60
|
+
<descriptorRef>jar-with-dependencies</descriptorRef>
|
|
61
|
+
</descriptorRefs>
|
|
62
|
+
</configuration>
|
|
63
|
+
</plugin>
|
|
64
|
+
|
|
65
|
+
<!-- Maven Shade Plugin - Fat JAR (alternative) -->
|
|
66
|
+
<plugin>
|
|
67
|
+
<groupId>org.apache.maven.plugins</groupId>
|
|
68
|
+
<artifactId>maven-shade-plugin</artifactId>
|
|
69
|
+
<executions>
|
|
70
|
+
<execution>
|
|
71
|
+
<phase>package</phase>
|
|
72
|
+
<goals>
|
|
73
|
+
<goal>shade</goal>
|
|
74
|
+
</goals>
|
|
75
|
+
</execution>
|
|
76
|
+
</executions>
|
|
77
|
+
</plugin>
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
**For Gradle:**
|
|
81
|
+
|
|
82
|
+
```groovy
|
|
83
|
+
// Fat JAR
|
|
84
|
+
jar {
|
|
85
|
+
manifest {
|
|
86
|
+
attributes 'Main-Class': 'com.company.app.Main'
|
|
87
|
+
}
|
|
88
|
+
from {
|
|
89
|
+
configurations.runtimeClasspath.collect {
|
|
90
|
+
it.isDirectory() ? it : zipTree(it)
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
// Or use Shadow plugin
|
|
96
|
+
plugins {
|
|
97
|
+
id 'com.github.johnrengelman.shadow' version '8.1.1'
|
|
98
|
+
}
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
**For Ant (NetBeans):**
|
|
102
|
+
|
|
103
|
+
```xml
|
|
104
|
+
<target name="jar" depends="compile">
|
|
105
|
+
<jar destfile="dist/myapp.jar" basedir="build/classes">
|
|
106
|
+
<manifest>
|
|
107
|
+
<attribute name="Main-Class" value="com.company.app.Main"/>
|
|
108
|
+
<attribute name="Class-Path" value="lib/dependency.jar"/>
|
|
109
|
+
</manifest>
|
|
110
|
+
</jar>
|
|
111
|
+
</target>
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
---
|
|
115
|
+
|
|
116
|
+
## 7.3 Native Packaging
|
|
117
|
+
|
|
118
|
+
**Using jpackage (Java 14+):**
|
|
119
|
+
|
|
120
|
+
```
|
|
121
|
+
jpackage --input target/ \
|
|
122
|
+
--name MyApp \
|
|
123
|
+
--main-jar myapp.jar \
|
|
124
|
+
--main-class com.company.app.Main \
|
|
125
|
+
--type [exe|dmg|deb|rpm|app-image] \
|
|
126
|
+
--icon src/main/resources/icon.ico \
|
|
127
|
+
--app-version 1.0.0 \
|
|
128
|
+
--vendor "Company Name" \
|
|
129
|
+
--copyright "Copyright 2025" \
|
|
130
|
+
--description "My Desktop Application"
|
|
131
|
+
|
|
132
|
+
Platform-specific options:
|
|
133
|
+
- Windows: --win-dir-chooser, --win-menu, --win-shortcut
|
|
134
|
+
- macOS: --mac-package-identifier com.company.app, --mac-sign
|
|
135
|
+
- Linux: --linux-shortcut, --linux-menu-group
|
|
136
|
+
```
|
|
137
|
+
|
|
138
|
+
**Using GraalVM Native Image:**
|
|
139
|
+
|
|
140
|
+
```bash
|
|
141
|
+
native-image -jar myapp.jar \
|
|
142
|
+
--no-fallback \
|
|
143
|
+
-H:Name=myapp \
|
|
144
|
+
-H:+ReportExceptionStackTraces
|
|
145
|
+
|
|
146
|
+
Benefits:
|
|
147
|
+
- Instant startup (no JVM warmup)
|
|
148
|
+
- Lower memory footprint
|
|
149
|
+
- No JRE required
|
|
150
|
+
Limitations:
|
|
151
|
+
- Reflection requires configuration
|
|
152
|
+
- Dynamic class loading limited
|
|
153
|
+
- Build time longer
|
|
154
|
+
```
|
|
155
|
+
|
|
156
|
+
**Third-party tools:**
|
|
157
|
+
|
|
158
|
+
```
|
|
159
|
+
A) Launch4j (Windows .exe wrapper)
|
|
160
|
+
- Wraps JAR in .exe
|
|
161
|
+
- JRE bundling
|
|
162
|
+
- Icon, splash screen
|
|
163
|
+
|
|
164
|
+
B) exe4j (Commercial Windows wrapper)
|
|
165
|
+
- Professional .exe generation
|
|
166
|
+
- Code signing support
|
|
167
|
+
|
|
168
|
+
C) install4j (Commercial multi-platform)
|
|
169
|
+
- Windows, macOS, Linux
|
|
170
|
+
- Auto-updates, licensing
|
|
171
|
+
|
|
172
|
+
Your choice: __
|
|
173
|
+
```
|
|
174
|
+
|
|
175
|
+
---
|
|
176
|
+
|
|
177
|
+
## 7.4 Distribution & Installation
|
|
178
|
+
|
|
179
|
+
```
|
|
180
|
+
How will users install your application?
|
|
181
|
+
|
|
182
|
+
A) 📦 Download from website
|
|
183
|
+
- Direct download link
|
|
184
|
+
- Manual installation
|
|
185
|
+
- No auto-updates
|
|
186
|
+
|
|
187
|
+
B) 🏪 App Store distribution
|
|
188
|
+
- Windows: Microsoft Store
|
|
189
|
+
- macOS: Mac App Store
|
|
190
|
+
- Linux: Snap Store, Flathub
|
|
191
|
+
- Requires app signing, review process
|
|
192
|
+
|
|
193
|
+
C) 📦 Package managers
|
|
194
|
+
- Windows: Chocolatey, Winget
|
|
195
|
+
- macOS: Homebrew
|
|
196
|
+
- Linux: apt, yum, pacman
|
|
197
|
+
|
|
198
|
+
D) 🔄 Auto-update system
|
|
199
|
+
- Check for updates on launch
|
|
200
|
+
- Download and install updates
|
|
201
|
+
- Libraries: Update4j, AutoUpdater
|
|
202
|
+
|
|
203
|
+
Your distribution method: __
|
|
204
|
+
|
|
205
|
+
Installation options:
|
|
206
|
+
- Install for all users vs current user?
|
|
207
|
+
- Desktop shortcut?
|
|
208
|
+
- Start menu entry?
|
|
209
|
+
- Auto-start on login?
|
|
210
|
+
- File associations?
|
|
211
|
+
```
|
|
212
|
+
|
|
213
|
+
---
|
|
214
|
+
|
|
215
|
+
## 7.5 Code Signing & Security
|
|
216
|
+
|
|
217
|
+
```
|
|
218
|
+
Will you sign your application?
|
|
219
|
+
|
|
220
|
+
**Windows:**
|
|
221
|
+
A) ✅ Code signing certificate
|
|
222
|
+
- .pfx/.p12 certificate
|
|
223
|
+
- Prevents "Unknown publisher" warnings
|
|
224
|
+
- Required for SmartScreen reputation
|
|
225
|
+
- Tools: SignTool.exe
|
|
226
|
+
|
|
227
|
+
B) ❌ No signing (development only)
|
|
228
|
+
|
|
229
|
+
**macOS:**
|
|
230
|
+
A) ✅ Apple Developer ID certificate
|
|
231
|
+
- Required for distribution outside App Store
|
|
232
|
+
- Gatekeeper approval
|
|
233
|
+
- Notarization (macOS 10.15+)
|
|
234
|
+
- Tools: codesign, xcrun altool
|
|
235
|
+
|
|
236
|
+
B) ❌ No signing (development only)
|
|
237
|
+
|
|
238
|
+
**Linux:**
|
|
239
|
+
- GPG signing for repositories
|
|
240
|
+
- AppImage signatures
|
|
241
|
+
|
|
242
|
+
Your signing strategy: __
|
|
243
|
+
|
|
244
|
+
**Distribution Security:**
|
|
245
|
+
- Provide checksums? (SHA-256)
|
|
246
|
+
- HTTPS downloads only?
|
|
247
|
+
- Signature verification instructions?
|
|
248
|
+
```
|
|
249
|
+
|
|
250
|
+
---
|
|
251
|
+
|
|
252
|
+
### Phase 7 Output
|
|
253
|
+
|
|
254
|
+
```
|
|
255
|
+
📋 PHASE 7 SUMMARY:
|
|
256
|
+
|
|
257
|
+
Packaging Format: [Executable JAR / Native executable / Installer]
|
|
258
|
+
Build Tool: [Maven / Gradle / Ant]
|
|
259
|
+
Native Packaging: [jpackage / GraalVM / Launch4j / exe4j]
|
|
260
|
+
Distribution: [Website download / App Store / Package manager / Auto-update]
|
|
261
|
+
Platform Packages:
|
|
262
|
+
- Windows: [.exe, .msi]
|
|
263
|
+
- macOS: [.app, .dmg, .pkg]
|
|
264
|
+
- Linux: [.deb, .rpm, AppImage]
|
|
265
|
+
Code Signing: [Yes - Windows/macOS / No]
|
|
266
|
+
Installation Options: [Desktop shortcut, Start menu, File associations]
|
|
267
|
+
|
|
268
|
+
Is this correct? (Yes/No)
|
|
269
|
+
```
|
|
270
|
+
|
|
271
|
+
---
|
|
272
|
+
|
|
273
|
+
### 📄 Generate Build Scripts
|
|
274
|
+
|
|
275
|
+
**Generate Maven packaging configuration**
|
|
276
|
+
**Generate Gradle packaging configuration**
|
|
277
|
+
**Generate jpackage script (shell/bat)**
|
|
278
|
+
**Generate distribution README**
|
|
279
|
+
|
|
280
|
+
Update `docs/DEPLOYMENT.md`:
|
|
281
|
+
|
|
282
|
+
- Build instructions
|
|
283
|
+
- Packaging process
|
|
284
|
+
- Distribution methods
|
|
285
|
+
- Installation guide
|
|
286
|
+
- Code signing procedures
|
|
287
|
+
|
|
288
|
+
---
|
|
289
|
+
|
|
290
|
+
**Next Phase:** Phase 8 - Project Setup & Final Docs (10-15 min)
|
|
291
|
+
|
|
292
|
+
Read: `.ai-flow/prompts/desktop/flow-build-phase-8.md`
|
|
293
|
+
|
|
294
|
+
---
|
|
295
|
+
|
|
296
|
+
**Last Updated:** 2025-02-03
|
|
297
|
+
**Version:** 1.0.0
|