@khester/create-dynamics-app 1.0.8 → 1.1.0
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/bin/create-dynamics-app.js +1 -1
- package/dist/index.js +140 -15
- package/dist/index.js.map +1 -1
- package/dist/utils/consultingHelpers.d.ts +13 -0
- package/dist/utils/consultingHelpers.d.ts.map +1 -0
- package/dist/utils/consultingHelpers.js +569 -0
- package/dist/utils/consultingHelpers.js.map +1 -0
- package/dist/utils/copyTemplate.d.ts.map +1 -1
- package/dist/utils/copyTemplate.js.map +1 -1
- package/dist/utils/initGit.d.ts.map +1 -1
- package/dist/utils/initGit.js.map +1 -1
- package/dist/utils/installDependencies.d.ts.map +1 -1
- package/dist/utils/installDependencies.js +3 -2
- package/dist/utils/installDependencies.js.map +1 -1
- package/dist/utils/updatePackageJson.d.ts +1 -1
- package/dist/utils/updatePackageJson.d.ts.map +1 -1
- package/dist/utils/updatePackageJson.js +11 -1
- package/dist/utils/updatePackageJson.js.map +1 -1
- package/package.json +1 -1
- package/templates/dynamics-365-starter/INTEGRATION_TEST_RESULTS.md +302 -0
- package/templates/dynamics-365-starter/PHASE_4_COMPLETION_SUMMARY.md +305 -0
- package/templates/dynamics-365-starter/README.md +566 -137
- package/templates/dynamics-365-starter/deployment/QUICKSTART-MAC.md +507 -0
- package/templates/dynamics-365-starter/deployment/QUICKSTART-WINDOWS.md +372 -0
- package/templates/dynamics-365-starter/deployment/README.md +484 -0
- package/templates/dynamics-365-starter/deployment/pipelines/README.md +375 -0
- package/templates/dynamics-365-starter/deployment/pipelines/azure-pipelines.yml +330 -0
- package/templates/dynamics-365-starter/deployment/pipelines/github-actions.yml +422 -0
- package/templates/dynamics-365-starter/deployment/pipelines/jenkins.groovy +636 -0
- package/templates/dynamics-365-starter/deployment/scripts/deploy.ps1 +417 -0
- package/templates/dynamics-365-starter/deployment/scripts/deploy.sh +582 -0
- package/templates/dynamics-365-starter/deployment/scripts/team-onboarding.ps1 +486 -0
- package/templates/dynamics-365-starter/deployment/scripts/team-onboarding.sh +567 -0
- package/templates/dynamics-365-starter/deployment/scripts/validate-setup.ps1 +703 -0
- package/templates/dynamics-365-starter/deployment/scripts/validate-setup.sh +671 -0
- package/templates/dynamics-365-starter/docs/ARCHITECTURE_OVERVIEW.md +506 -0
- package/templates/dynamics-365-starter/docs/BEST_PRACTICES.md +723 -0
- package/templates/dynamics-365-starter/docs/MIGRATION_GUIDE.md +447 -0
- package/templates/dynamics-365-starter/docs/team-standards/README.md +273 -0
- package/templates/dynamics-365-starter/docs/team-standards/client-onboarding.md +577 -0
- package/templates/dynamics-365-starter/docs/team-standards/code-review-checklist.md +359 -0
- package/templates/dynamics-365-starter/docs/team-standards/coding-standards.md +700 -0
- package/templates/dynamics-365-starter/docs/team-standards/cross-platform-team-guide.md +736 -0
- package/templates/dynamics-365-starter/docs/team-standards/development-workflows.md +727 -0
- package/templates/dynamics-365-starter/docs/troubleshooting/common-errors.md +758 -0
- package/templates/dynamics-365-starter/docs/troubleshooting/platform-specific-issues.md +878 -0
- package/templates/dynamics-365-starter/package.json +22 -1
- package/templates/dynamics-365-starter/public/index.html +8 -11
- package/templates/dynamics-365-starter/scripts/custom-build.js +255 -0
- package/templates/dynamics-365-starter/src/client-project-template/README.md +234 -0
- package/templates/dynamics-365-starter/src/client-project-template/config/client.template.json +114 -0
- package/templates/dynamics-365-starter/src/client-project-template/config/environments/template.json +186 -0
- package/templates/dynamics-365-starter/src/client-project-template/scripts/client-setup.js +667 -0
- package/templates/dynamics-365-starter/src/components/AccountForm.css +71 -0
- package/templates/dynamics-365-starter/src/components/AccountForm.tsx +541 -0
- package/templates/dynamics-365-starter/src/components/AccountManagement.css +86 -0
- package/templates/dynamics-365-starter/src/components/AccountManagement.tsx +370 -0
- package/templates/dynamics-365-starter/src/components/ContactForm.tsx +149 -63
- package/templates/dynamics-365-starter/src/components/ContactManagement.tsx +153 -63
- package/templates/dynamics-365-starter/src/components/Logging/LogDialog.tsx +291 -0
- package/templates/dynamics-365-starter/src/components/Logging/LoggingContext.tsx +166 -0
- package/templates/dynamics-365-starter/src/components/Logging/LoggingDebugPanel.css +192 -0
- package/templates/dynamics-365-starter/src/components/Logging/LoggingDebugPanel.tsx +177 -0
- package/templates/dynamics-365-starter/src/components/Logging/LoggingProvider.tsx +3 -0
- package/templates/dynamics-365-starter/src/components/Logging/logger.ts +193 -0
- package/templates/dynamics-365-starter/src/constants/account.ts +410 -0
- package/templates/dynamics-365-starter/src/constants/contact.ts +362 -0
- package/templates/dynamics-365-starter/src/examples/README.md +52 -0
- package/templates/dynamics-365-starter/src/examples/component-examples/opportunity-management.tsx +625 -0
- package/templates/dynamics-365-starter/src/examples/entity-examples/opportunity-model.ts +545 -0
- package/templates/dynamics-365-starter/src/examples/integration-examples/custom-pcf-wrapper.tsx +722 -0
- package/templates/dynamics-365-starter/src/examples/workflow-examples/sales-workflow.ts +662 -0
- package/templates/dynamics-365-starter/src/index.tsx +107 -19
- package/templates/dynamics-365-starter/src/models/Account.ts +480 -0
- package/templates/dynamics-365-starter/src/models/BaseEntity.ts +204 -0
- package/templates/dynamics-365-starter/src/models/Contact.ts +580 -0
- package/templates/dynamics-365-starter/src/page-templates/EntityDashboard.tsx +519 -0
- package/templates/dynamics-365-starter/src/page-templates/EntityDetailPage.tsx +456 -0
- package/templates/dynamics-365-starter/src/page-templates/EntityListPage.tsx +406 -0
- package/templates/dynamics-365-starter/src/page-templates/RelatedEntitiesPage.tsx +578 -0
- package/templates/dynamics-365-starter/src/page-templates/SearchPage.tsx +629 -0
- package/templates/dynamics-365-starter/src/pcf/ContactControlWrapper.tsx +75 -22
- package/templates/dynamics-365-starter/src/pcf/MultiEntityControlWrapper.tsx +205 -0
- package/templates/dynamics-365-starter/src/providers/DynamicsProvider.tsx +297 -80
- package/templates/dynamics-365-starter/src/services/MockApiService.ts +260 -0
- package/templates/dynamics-365-starter/src/services/ServiceFactory.ts +65 -0
- package/templates/dynamics-365-starter/src/services/XrmApiService.ts +213 -0
- package/templates/dynamics-365-starter/src/styles/index.css +74 -7
- package/templates/dynamics-365-starter/tools/entity-generator/index.js +168 -0
- package/templates/dynamics-365-starter/tools/entity-generator/templates/constants.template.ts +124 -0
- package/templates/dynamics-365-starter/tools/entity-generator/templates/form.template.css +283 -0
- package/templates/dynamics-365-starter/tools/entity-generator/templates/form.template.tsx +275 -0
- package/templates/dynamics-365-starter/tools/entity-generator/templates/management.template.css +204 -0
- package/templates/dynamics-365-starter/tools/entity-generator/templates/management.template.tsx +413 -0
- package/templates/dynamics-365-starter/tools/entity-generator/templates/model.template.ts +250 -0
- package/templates/dynamics-365-starter/tools/metadata-sync/d365-client.js +410 -0
- package/templates/dynamics-365-starter/tools/metadata-sync/index.js +512 -0
- package/templates/dynamics-365-starter/tools/metadata-sync/type-generator.js +675 -0
- package/templates/dynamics-365-starter/tsconfig.json +11 -8
- package/templates/dynamics-365-starter/webpack.config.js +8 -9
- package/templates/power-pages-starter/README.md +7 -1
- package/templates/power-pages-starter/public/index.html +8 -11
- package/templates/power-pages-starter/src/components/ContactForm.tsx +60 -41
- package/templates/power-pages-starter/src/index.tsx +3 -3
- package/templates/power-pages-starter/src/providers/PowerPagesProvider.tsx +46 -23
- package/templates/power-pages-starter/tsconfig.json +3 -9
- package/templates/power-pages-starter/webpack.config.js +8 -3
|
@@ -0,0 +1,507 @@
|
|
|
1
|
+
# Quick Start Guide - Mac Developers
|
|
2
|
+
|
|
3
|
+
🍎 **Platform-specific setup for Mac developers using Bash**
|
|
4
|
+
|
|
5
|
+
## Prerequisites
|
|
6
|
+
|
|
7
|
+
### Required Software
|
|
8
|
+
|
|
9
|
+
- **macOS 10.15+** (Catalina or newer)
|
|
10
|
+
- **Homebrew** package manager
|
|
11
|
+
- **Node.js 18+** and **npm**
|
|
12
|
+
- **Git**
|
|
13
|
+
|
|
14
|
+
### Install Development Tools
|
|
15
|
+
|
|
16
|
+
```bash
|
|
17
|
+
# Install Homebrew (if not already installed)
|
|
18
|
+
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
|
|
19
|
+
|
|
20
|
+
# Install required tools
|
|
21
|
+
brew install node npm git jq curl
|
|
22
|
+
|
|
23
|
+
# Verify installations
|
|
24
|
+
node --version
|
|
25
|
+
npm --version
|
|
26
|
+
git --version
|
|
27
|
+
jq --version
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
### Optional: Install PowerShell Core (Alternative)
|
|
31
|
+
|
|
32
|
+
```bash
|
|
33
|
+
# If you prefer PowerShell (optional)
|
|
34
|
+
brew install --cask powershell
|
|
35
|
+
|
|
36
|
+
# Verify PowerShell installation
|
|
37
|
+
pwsh --version
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
## Project Setup
|
|
41
|
+
|
|
42
|
+
### 1. Clone and Setup Project
|
|
43
|
+
|
|
44
|
+
```bash
|
|
45
|
+
# Clone the project
|
|
46
|
+
git clone https://github.com/your-org/your-dynamics-project.git
|
|
47
|
+
cd your-dynamics-project
|
|
48
|
+
|
|
49
|
+
# Install dependencies
|
|
50
|
+
npm install
|
|
51
|
+
|
|
52
|
+
# Build the project
|
|
53
|
+
npm run build:prod
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
### 2. Configure Environment
|
|
57
|
+
|
|
58
|
+
```bash
|
|
59
|
+
# Copy environment template
|
|
60
|
+
cp config/environments/template.json config/environments/dev.json
|
|
61
|
+
|
|
62
|
+
# Edit configuration (use your preferred editor)
|
|
63
|
+
code config/environments/dev.json # VS Code
|
|
64
|
+
# or
|
|
65
|
+
nano config/environments/dev.json # Terminal editor
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
### 3. Validate Setup
|
|
69
|
+
|
|
70
|
+
```bash
|
|
71
|
+
# Make deployment script executable
|
|
72
|
+
chmod +x deployment/scripts/deploy.sh
|
|
73
|
+
chmod +x deployment/scripts/validate-setup.sh
|
|
74
|
+
chmod +x deployment/scripts/test-connection.sh
|
|
75
|
+
|
|
76
|
+
# Run validation script
|
|
77
|
+
./deployment/scripts/validate-setup.sh
|
|
78
|
+
|
|
79
|
+
# Test connection to D365
|
|
80
|
+
./deployment/scripts/test-connection.sh dev
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
## Daily Deployment Workflow
|
|
84
|
+
|
|
85
|
+
### Development Deployment
|
|
86
|
+
|
|
87
|
+
```bash
|
|
88
|
+
# Quick development deployment
|
|
89
|
+
./deployment/scripts/deploy.sh dev
|
|
90
|
+
|
|
91
|
+
# With verbose output
|
|
92
|
+
./deployment/scripts/deploy.sh dev --verbose
|
|
93
|
+
|
|
94
|
+
# Dry run (test without changes)
|
|
95
|
+
./deployment/scripts/deploy.sh dev --dry-run
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
### Production Deployment
|
|
99
|
+
|
|
100
|
+
```bash
|
|
101
|
+
# Production deployment with backup
|
|
102
|
+
./deployment/scripts/deploy.sh prod
|
|
103
|
+
|
|
104
|
+
# Force deployment (skip some validations)
|
|
105
|
+
./deployment/scripts/deploy.sh prod --force
|
|
106
|
+
|
|
107
|
+
# Skip backup (faster deployment)
|
|
108
|
+
./deployment/scripts/deploy.sh prod --skip-backup
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
### Entity Generation
|
|
112
|
+
|
|
113
|
+
```bash
|
|
114
|
+
# Generate new entity
|
|
115
|
+
npm run generate:entity -- --entity "salesorder" --display-name "Sales Order"
|
|
116
|
+
|
|
117
|
+
# Generate multiple entities
|
|
118
|
+
npm run generate:entity -- --entity "product" --display-name "Product"
|
|
119
|
+
npm run generate:entity -- --entity "pricing" --display-name "Pricing Rule"
|
|
120
|
+
```
|
|
121
|
+
|
|
122
|
+
## Common Commands Reference
|
|
123
|
+
|
|
124
|
+
### Build Commands
|
|
125
|
+
|
|
126
|
+
```bash
|
|
127
|
+
npm run build:dev # Development build (unminified)
|
|
128
|
+
npm run build:prod # Production build (optimized)
|
|
129
|
+
npm run build:d365 # Dynamics 365 optimized build
|
|
130
|
+
npm run clean # Clean build artifacts
|
|
131
|
+
```
|
|
132
|
+
|
|
133
|
+
### Quality Checks
|
|
134
|
+
|
|
135
|
+
```bash
|
|
136
|
+
npm run lint # Check code style
|
|
137
|
+
npm run lint:fix # Fix code style issues
|
|
138
|
+
npm run typecheck # TypeScript validation
|
|
139
|
+
npm run quality # Run all quality checks
|
|
140
|
+
npm run test # Run unit tests
|
|
141
|
+
```
|
|
142
|
+
|
|
143
|
+
### Metadata Operations
|
|
144
|
+
|
|
145
|
+
```bash
|
|
146
|
+
npm run metadata:pull -- --environment dev --entities "account,contact"
|
|
147
|
+
npm run metadata:generate
|
|
148
|
+
npm run metadata:validate -- --environment dev
|
|
149
|
+
npm run metadata:sync -- --environment dev --all
|
|
150
|
+
```
|
|
151
|
+
|
|
152
|
+
### Deployment Operations
|
|
153
|
+
|
|
154
|
+
```bash
|
|
155
|
+
# Deploy to specific environment
|
|
156
|
+
./deployment/scripts/deploy.sh <environment>
|
|
157
|
+
|
|
158
|
+
# Rollback deployment
|
|
159
|
+
./deployment/scripts/rollback.sh <environment> backup-file.tar.gz
|
|
160
|
+
|
|
161
|
+
# Health check
|
|
162
|
+
./deployment/scripts/health-check.sh <environment>
|
|
163
|
+
|
|
164
|
+
# Monitor deployment
|
|
165
|
+
./deployment/scripts/monitor.sh <environment>
|
|
166
|
+
```
|
|
167
|
+
|
|
168
|
+
## Bash Configuration
|
|
169
|
+
|
|
170
|
+
### Shell Profile Setup
|
|
171
|
+
|
|
172
|
+
```bash
|
|
173
|
+
# Determine your shell
|
|
174
|
+
echo $SHELL
|
|
175
|
+
|
|
176
|
+
# For Zsh (default on macOS Catalina+)
|
|
177
|
+
echo '# Dynamics 365 Development Aliases' >> ~/.zshrc
|
|
178
|
+
echo 'alias d365deploy="./deployment/scripts/deploy.sh"' >> ~/.zshrc
|
|
179
|
+
echo 'alias d365health="./deployment/scripts/health-check.sh"' >> ~/.zshrc
|
|
180
|
+
echo 'alias d365rollback="./deployment/scripts/rollback.sh"' >> ~/.zshrc
|
|
181
|
+
echo 'alias d365cd="cd ~/Code/YourProject"' >> ~/.zshrc
|
|
182
|
+
|
|
183
|
+
# For Bash
|
|
184
|
+
echo '# Dynamics 365 Development Aliases' >> ~/.bash_profile
|
|
185
|
+
echo 'alias d365deploy="./deployment/scripts/deploy.sh"' >> ~/.bash_profile
|
|
186
|
+
echo 'alias d365health="./deployment/scripts/health-check.sh"' >> ~/.bash_profile
|
|
187
|
+
echo 'alias d365rollback="./deployment/scripts/rollback.sh"' >> ~/.bash_profile
|
|
188
|
+
echo 'alias d365cd="cd ~/Code/YourProject"' >> ~/.bash_profile
|
|
189
|
+
|
|
190
|
+
# Reload profile
|
|
191
|
+
source ~/.zshrc # or ~/.bash_profile
|
|
192
|
+
```
|
|
193
|
+
|
|
194
|
+
### Environment Variables
|
|
195
|
+
|
|
196
|
+
```bash
|
|
197
|
+
# Set environment variables for session
|
|
198
|
+
export D365_ENVIRONMENT="dev"
|
|
199
|
+
export D365_CLIENT_ID="your-client-id"
|
|
200
|
+
|
|
201
|
+
# Make permanent (add to ~/.zshrc or ~/.bash_profile)
|
|
202
|
+
echo 'export D365_ENVIRONMENT="dev"' >> ~/.zshrc
|
|
203
|
+
echo 'export D365_CLIENT_ID="your-client-id"' >> ~/.zshrc
|
|
204
|
+
```
|
|
205
|
+
|
|
206
|
+
## Mac-Specific Tips
|
|
207
|
+
|
|
208
|
+
### File Permissions
|
|
209
|
+
|
|
210
|
+
```bash
|
|
211
|
+
# Make all deployment scripts executable
|
|
212
|
+
find deployment/scripts -name "*.sh" -exec chmod +x {} \;
|
|
213
|
+
|
|
214
|
+
# Check file permissions
|
|
215
|
+
ls -la deployment/scripts/
|
|
216
|
+
```
|
|
217
|
+
|
|
218
|
+
### Path Handling
|
|
219
|
+
|
|
220
|
+
```bash
|
|
221
|
+
# Use forward slashes for paths (native to Unix/Mac)
|
|
222
|
+
./deployment/scripts/deploy.sh
|
|
223
|
+
|
|
224
|
+
# Current directory reference
|
|
225
|
+
./deployment/scripts/deploy.sh dev
|
|
226
|
+
```
|
|
227
|
+
|
|
228
|
+
### Using Finder Integration
|
|
229
|
+
|
|
230
|
+
```bash
|
|
231
|
+
# Open current directory in Finder
|
|
232
|
+
open .
|
|
233
|
+
|
|
234
|
+
# Open project in VS Code
|
|
235
|
+
code .
|
|
236
|
+
|
|
237
|
+
# Open specific file
|
|
238
|
+
open config/environments/dev.json
|
|
239
|
+
```
|
|
240
|
+
|
|
241
|
+
### Terminal Configuration
|
|
242
|
+
|
|
243
|
+
#### iTerm2 Setup (Recommended)
|
|
244
|
+
|
|
245
|
+
```bash
|
|
246
|
+
# Install iTerm2
|
|
247
|
+
brew install --cask iterm2
|
|
248
|
+
|
|
249
|
+
# Create D365 project profile in iTerm2:
|
|
250
|
+
# 1. Open iTerm2 Preferences
|
|
251
|
+
# 2. Go to Profiles
|
|
252
|
+
# 3. Create new profile "D365 Development"
|
|
253
|
+
# 4. Set working directory to your project folder
|
|
254
|
+
# 5. Set custom color scheme if desired
|
|
255
|
+
```
|
|
256
|
+
|
|
257
|
+
#### Terminal.app Setup
|
|
258
|
+
|
|
259
|
+
```bash
|
|
260
|
+
# Create custom terminal profile:
|
|
261
|
+
# 1. Open Terminal.app
|
|
262
|
+
# 2. Go to Terminal > Preferences > Profiles
|
|
263
|
+
# 3. Duplicate "Basic" profile
|
|
264
|
+
# 4. Name it "D365 Development"
|
|
265
|
+
# 5. Set startup directory to your project
|
|
266
|
+
```
|
|
267
|
+
|
|
268
|
+
## Troubleshooting
|
|
269
|
+
|
|
270
|
+
### Common Issues
|
|
271
|
+
|
|
272
|
+
#### Permission Denied Errors
|
|
273
|
+
|
|
274
|
+
```bash
|
|
275
|
+
# Fix script permissions
|
|
276
|
+
chmod +x deployment/scripts/deploy.sh
|
|
277
|
+
|
|
278
|
+
# Check script permissions
|
|
279
|
+
ls -la deployment/scripts/deploy.sh
|
|
280
|
+
```
|
|
281
|
+
|
|
282
|
+
#### Command Not Found
|
|
283
|
+
|
|
284
|
+
```bash
|
|
285
|
+
# Check if tool is installed
|
|
286
|
+
which jq
|
|
287
|
+
which curl
|
|
288
|
+
which node
|
|
289
|
+
|
|
290
|
+
# Install missing tools
|
|
291
|
+
brew install jq curl node
|
|
292
|
+
```
|
|
293
|
+
|
|
294
|
+
#### Authentication Issues
|
|
295
|
+
|
|
296
|
+
```bash
|
|
297
|
+
# Clear any cached credentials
|
|
298
|
+
rm -rf ~/.azure
|
|
299
|
+
rm -rf ~/.config/powershell
|
|
300
|
+
|
|
301
|
+
# Test authentication
|
|
302
|
+
./deployment/scripts/test-auth.sh dev
|
|
303
|
+
```
|
|
304
|
+
|
|
305
|
+
#### Build Failures
|
|
306
|
+
|
|
307
|
+
```bash
|
|
308
|
+
# Clear npm cache
|
|
309
|
+
npm cache clean --force
|
|
310
|
+
|
|
311
|
+
# Remove node_modules and reinstall
|
|
312
|
+
rm -rf node_modules
|
|
313
|
+
npm install
|
|
314
|
+
|
|
315
|
+
# Clear build artifacts
|
|
316
|
+
npm run clean
|
|
317
|
+
```
|
|
318
|
+
|
|
319
|
+
#### Network Issues
|
|
320
|
+
|
|
321
|
+
```bash
|
|
322
|
+
# Check internet connectivity
|
|
323
|
+
ping google.com
|
|
324
|
+
|
|
325
|
+
# Test D365 connectivity
|
|
326
|
+
curl -I https://yourdomain.crm.dynamics.com
|
|
327
|
+
|
|
328
|
+
# Check for proxy issues
|
|
329
|
+
echo $HTTP_PROXY
|
|
330
|
+
echo $HTTPS_PROXY
|
|
331
|
+
```
|
|
332
|
+
|
|
333
|
+
### Performance Optimization
|
|
334
|
+
|
|
335
|
+
```bash
|
|
336
|
+
# Increase Node.js memory limit
|
|
337
|
+
export NODE_OPTIONS="--max-old-space-size=4096"
|
|
338
|
+
|
|
339
|
+
# Use faster package manager (optional)
|
|
340
|
+
brew install pnpm
|
|
341
|
+
# Then use 'pnpm install' instead of 'npm install'
|
|
342
|
+
```
|
|
343
|
+
|
|
344
|
+
## VS Code Integration
|
|
345
|
+
|
|
346
|
+
### Recommended Extensions
|
|
347
|
+
|
|
348
|
+
- **TypeScript** - Enhanced TypeScript support
|
|
349
|
+
- **Bash IDE** - Bash script development
|
|
350
|
+
- **REST Client** - Test D365 APIs
|
|
351
|
+
- **GitLens** - Enhanced Git capabilities
|
|
352
|
+
|
|
353
|
+
### Launch Configuration
|
|
354
|
+
|
|
355
|
+
```json
|
|
356
|
+
// .vscode/launch.json
|
|
357
|
+
{
|
|
358
|
+
"version": "0.2.0",
|
|
359
|
+
"configurations": [
|
|
360
|
+
{
|
|
361
|
+
"name": "Deploy to Dev",
|
|
362
|
+
"type": "node",
|
|
363
|
+
"request": "launch",
|
|
364
|
+
"program": "${workspaceFolder}/deployment/scripts/deploy.sh",
|
|
365
|
+
"args": ["dev", "--verbose"],
|
|
366
|
+
"cwd": "${workspaceFolder}",
|
|
367
|
+
"console": "integratedTerminal"
|
|
368
|
+
}
|
|
369
|
+
]
|
|
370
|
+
}
|
|
371
|
+
```
|
|
372
|
+
|
|
373
|
+
### Tasks Configuration
|
|
374
|
+
|
|
375
|
+
```json
|
|
376
|
+
// .vscode/tasks.json
|
|
377
|
+
{
|
|
378
|
+
"version": "2.0.0",
|
|
379
|
+
"tasks": [
|
|
380
|
+
{
|
|
381
|
+
"label": "Deploy to Dev",
|
|
382
|
+
"type": "shell",
|
|
383
|
+
"command": "./deployment/scripts/deploy.sh",
|
|
384
|
+
"args": ["dev"],
|
|
385
|
+
"group": "build",
|
|
386
|
+
"presentation": {
|
|
387
|
+
"echo": true,
|
|
388
|
+
"reveal": "always",
|
|
389
|
+
"focus": false,
|
|
390
|
+
"panel": "shared"
|
|
391
|
+
},
|
|
392
|
+
"problemMatcher": []
|
|
393
|
+
},
|
|
394
|
+
{
|
|
395
|
+
"label": "Generate Entity",
|
|
396
|
+
"type": "shell",
|
|
397
|
+
"command": "npm",
|
|
398
|
+
"args": [
|
|
399
|
+
"run",
|
|
400
|
+
"generate:entity",
|
|
401
|
+
"--",
|
|
402
|
+
"--entity",
|
|
403
|
+
"${input:entityName}",
|
|
404
|
+
"--display-name",
|
|
405
|
+
"${input:displayName}"
|
|
406
|
+
],
|
|
407
|
+
"group": "build"
|
|
408
|
+
}
|
|
409
|
+
],
|
|
410
|
+
"inputs": [
|
|
411
|
+
{
|
|
412
|
+
"id": "entityName",
|
|
413
|
+
"description": "Entity logical name",
|
|
414
|
+
"default": "customentity",
|
|
415
|
+
"type": "promptString"
|
|
416
|
+
},
|
|
417
|
+
{
|
|
418
|
+
"id": "displayName",
|
|
419
|
+
"description": "Entity display name",
|
|
420
|
+
"default": "Custom Entity",
|
|
421
|
+
"type": "promptString"
|
|
422
|
+
}
|
|
423
|
+
]
|
|
424
|
+
}
|
|
425
|
+
```
|
|
426
|
+
|
|
427
|
+
## Docker Alternative (Optional)
|
|
428
|
+
|
|
429
|
+
### Using Docker for Consistency
|
|
430
|
+
|
|
431
|
+
```bash
|
|
432
|
+
# Create Dockerfile for D365 development
|
|
433
|
+
cat > Dockerfile << 'EOF'
|
|
434
|
+
FROM node:18-alpine
|
|
435
|
+
RUN apk add --no-cache bash jq curl git
|
|
436
|
+
WORKDIR /app
|
|
437
|
+
COPY package*.json ./
|
|
438
|
+
RUN npm ci
|
|
439
|
+
COPY . .
|
|
440
|
+
RUN npm run build:prod
|
|
441
|
+
CMD ["./deployment/scripts/deploy.sh"]
|
|
442
|
+
EOF
|
|
443
|
+
|
|
444
|
+
# Build Docker image
|
|
445
|
+
docker build -t d365-deploy .
|
|
446
|
+
|
|
447
|
+
# Run deployment in container
|
|
448
|
+
docker run --rm -v $(pwd)/config:/app/config d365-deploy dev
|
|
449
|
+
```
|
|
450
|
+
|
|
451
|
+
## Team Collaboration
|
|
452
|
+
|
|
453
|
+
### Shared Scripts Compatibility
|
|
454
|
+
|
|
455
|
+
All Bash scripts in `deployment/scripts/` work identically across all Mac machines and are
|
|
456
|
+
compatible with Linux CI/CD systems.
|
|
457
|
+
|
|
458
|
+
### Configuration Sharing
|
|
459
|
+
|
|
460
|
+
- Environment configs in `config/environments/` are shared across team
|
|
461
|
+
- Personal settings go in `.env.local` (not committed to git)
|
|
462
|
+
- Use the same JSON configuration files as Windows team members
|
|
463
|
+
|
|
464
|
+
### Log Files
|
|
465
|
+
|
|
466
|
+
```bash
|
|
467
|
+
# Deployment logs location
|
|
468
|
+
ls -la deployment/logs/
|
|
469
|
+
|
|
470
|
+
# View latest deployment log
|
|
471
|
+
tail -f deployment/logs/deploy-dev-*.log
|
|
472
|
+
|
|
473
|
+
# Search for errors
|
|
474
|
+
grep -i error deployment/logs/deploy-dev-*.log
|
|
475
|
+
```
|
|
476
|
+
|
|
477
|
+
## Compatibility with Windows Team Members
|
|
478
|
+
|
|
479
|
+
### Same Functionality
|
|
480
|
+
|
|
481
|
+
✅ **Identical deployment results** as Windows PowerShell scripts
|
|
482
|
+
✅ **Same configuration files** work for both platforms
|
|
483
|
+
✅ **Same entity generation** and build processes
|
|
484
|
+
✅ **Compatible log formats** for shared troubleshooting
|
|
485
|
+
|
|
486
|
+
### Command Equivalents
|
|
487
|
+
|
|
488
|
+
| Windows PowerShell | Mac Bash | Result |
|
|
489
|
+
| ---------------------------------------- | ---------------------------- | ----------------- |
|
|
490
|
+
| `.\deploy.ps1 -Environment dev` | `./deploy.sh dev` | Same deployment |
|
|
491
|
+
| `.\deploy.ps1 -Environment prod -DryRun` | `./deploy.sh prod --dry-run` | Same dry run |
|
|
492
|
+
| `.\health-check.ps1 -Environment prod` | `./health-check.sh prod` | Same health check |
|
|
493
|
+
|
|
494
|
+
## Next Steps
|
|
495
|
+
|
|
496
|
+
1. ✅ **Complete environment setup** using this guide
|
|
497
|
+
2. ✅ **Run first deployment** to development environment
|
|
498
|
+
3. ✅ **Generate your first entity** using the entity generator
|
|
499
|
+
4. ✅ **Deploy to test environment** when ready
|
|
500
|
+
5. ✅ **Set up CI/CD pipeline** for automated deployments
|
|
501
|
+
|
|
502
|
+
For Windows team members, refer to `QUICKSTART-WINDOWS.md` for their platform-specific setup.
|
|
503
|
+
|
|
504
|
+
---
|
|
505
|
+
|
|
506
|
+
💡 **Tip**: Save this guide to your bookmarks and use the **Common Commands Reference** section for
|
|
507
|
+
daily workflows!
|