Skip to content

Commit 0cf8683

Browse files
committed
chore: update README.md for improved clarity and organization
1 parent 2b1fd84 commit 0cf8683

File tree

1 file changed

+33
-1
lines changed

1 file changed

+33
-1
lines changed

.devcontainer/README.md

Lines changed: 33 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,26 +12,28 @@ This directory contains a comprehensive development container configuration for
1212
- **VS Code Extensions** - Comprehensive set of development extensions
1313

1414
### Testing & Quality Assurance
15+
1516
- **Pester 5.x** - Modern PowerShell testing framework
1617
- **PSScriptAnalyzer** - Static code analysis
1718
- **Code Coverage** - Integrated coverage reporting
1819
- **Automated Quality Gates** - Pre-commit hooks and CI/CD support
1920

2021
### Build & Automation
22+
2123
- **InvokeBuild** - Advanced build automation
2224
- **ModuleBuilder** - PowerShell module packaging
2325
- **dotnet CLI** - .NET project management
2426
- **Git Hooks** - Automated quality checks
2527

2628
### Development Tools
29+
2730
- **GitHub CLI** - Repository management
2831
- **Azure CLI** - Cloud development support
2932
- **Docker CLI** - Container development
3033
- **Multiple Shell Options** - bash, zsh, PowerShell
3134

3235
## 📁 File Structure
3336

34-
```
3537
.devcontainer/
3638
├── devcontainer.json # Main configuration with features and settings
3739
├── Dockerfile # Multi-stage container build
@@ -40,18 +42,21 @@ This directory contains a comprehensive development container configuration for
4042
├── ubuntutools.sh # Ubuntu tools and utilities
4143
├── cache/ # Persistent cache directory
4244
└── README.md # This file
45+
4346
```
4447
4548
## 🔧 Configuration Details
4649
4750
### devcontainer.json
51+
4852
- Uses VS Code dev container features for .NET, Git, GitHub CLI, and PowerShell
4953
- Configures comprehensive VS Code settings for PowerShell and .NET development
5054
- Includes 20+ carefully selected extensions
5155
- Sets up persistent cache mounting
5256
- Configures post-creation and post-start commands
5357
5458
### Dockerfile
59+
5560
- Multi-stage build based on Ubuntu 22.04
5661
- Installs .NET SDK 8.0 with backward compatibility
5762
- Includes PowerShell 7.x from Microsoft repositories
@@ -60,6 +65,7 @@ This directory contains a comprehensive development container configuration for
6065
- Configures PowerShell modules with specific versions
6166
6267
### Post-Creation Setup (postCreate.sh)
68+
6369
- Restores .NET dependencies
6470
- Installs PowerShell modules from requirements.psd1
6571
- Creates enhanced PowerShell profile
@@ -70,24 +76,28 @@ This directory contains a comprehensive development container configuration for
7076
## 🛠️ PowerShell Modules Included
7177
7278
### Testing & Quality
79+
7380
- **Pester 5.5.0** - Testing framework
7481
- **PSScriptAnalyzer 1.21.0** - Code analysis
7582
- **PSRule 2.9.0** - Rule-based validation
7683
- **PSRule.Rules.Azure 1.30.1** - Azure validation
7784
7885
### Development Tools
86+
7987
- **InvokeBuild 5.10.4** - Build automation
8088
- **ModuleBuilder 2.0.0** - Module packaging
8189
- **PSModuleDevelopment 2.2.9.94** - Development tools
8290
- **Plaster 1.1.3** - Project templating
8391
8492
### Framework & Utilities
93+
8594
- **PSFramework 1.7.270** - Logging and utilities
8695
- **PSDepend 0.3.8** - Dependency management
8796
- **PSReadLine 2.3.4** - Enhanced command line
8897
- **PowerShellGet 2.2.5** - Package management
8998
9099
### Domain-Specific
100+
91101
- **OSD 23.5.26.1** - OS deployment automation
92102
- **PowerShellProTools 5.8.6** - Professional tools
93103
@@ -102,6 +112,7 @@ This directory contains a comprehensive development container configuration for
102112
## 💡 Available Commands
103113
104114
### PowerShell Functions
115+
105116
```powershell
106117
Show-DevEnvironment # Display environment status
107118
Test-ModuleStructure # Validate module structure
@@ -112,6 +123,7 @@ Invoke-FullTest # Complete test suite
112123
```
113124

114125
### VS Code Tasks
126+
115127
- **Build: Full Project** - Complete build process
116128
- **Test: Full Test Suite** - All tests with coverage
117129
- **Test: Pester Only** - PowerShell tests only
@@ -121,6 +133,7 @@ Invoke-FullTest # Complete test suite
121133
- **Clean: All Artifacts** - Remove build outputs
122134

123135
### Shell Aliases
136+
124137
```bash
125138
# Git shortcuts
126139
gs # git status
@@ -142,29 +155,34 @@ analyze # pwsh -Command Invoke-ScriptAnalyzer
142155
## 🔍 Testing Strategy
143156

144157
### Unit Tests
158+
145159
- **Pester Tests** - Located in `./tests/`
146160
- **Coverage Analysis** - Automatic code coverage
147161
- **Mock Support** - Comprehensive mocking capabilities
148162

149163
### Integration Tests
164+
150165
- **Module Loading** - Verify module imports
151166
- **Function Validation** - End-to-end function testing
152167
- **Configuration Testing** - Settings validation
153168

154169
### Quality Assurance
170+
155171
- **PSScriptAnalyzer** - Static code analysis
156172
- **Pre-commit Hooks** - Automated quality gates
157173
- **Continuous Integration** - Ready for CI/CD pipelines
158174

159175
## 📊 Monitoring & Debugging
160176

161177
### Code Coverage
178+
162179
- **Coverlet** - .NET code coverage
163180
- **Pester Coverage** - PowerShell code coverage
164181
- **ReportGenerator** - Coverage report generation
165182
- **VS Code Integration** - Coverage gutters
166183

167184
### Debugging
185+
168186
- **PowerShell Debugger** - Integrated debugging
169187
- **Breakpoint Support** - Full breakpoint functionality
170188
- **Variable Inspection** - Runtime variable analysis
@@ -173,11 +191,13 @@ analyze # pwsh -Command Invoke-ScriptAnalyzer
173191
## 🔒 Security & Best Practices
174192

175193
### Security
194+
176195
- **Non-root User** - vscode user for development
177196
- **Least Privilege** - Minimal required permissions
178197
- **Secure Defaults** - Security-focused configurations
179198

180199
### Best Practices
200+
181201
- **Version Pinning** - Specific module versions
182202
- **Clean Separation** - Clear separation of concerns
183203
- **Documentation** - Comprehensive inline documentation
@@ -186,19 +206,23 @@ analyze # pwsh -Command Invoke-ScriptAnalyzer
186206
## 🚀 Performance Optimizations
187207

188208
### Caching
209+
189210
- **Persistent Cache** - `.devcontainer/cache` mounting
190211
- **Module Cache** - PowerShell module caching
191212
- **Build Cache** - .NET build artifact caching
192213

193214
### Resource Management
215+
194216
- **Optimized Images** - Multi-stage Docker builds
195217
- **Selective Installation** - Only required components
196218
- **Cleanup Processes** - Automated cleanup procedures
197219

198220
## 🔧 Customization
199221

200222
### Adding Modules
223+
201224
Edit `devsetup.ps1` to add PowerShell modules:
225+
202226
```powershell
203227
$RequiredModules += @{
204228
Name = "ModuleName"
@@ -209,13 +233,17 @@ $RequiredModules += @{
209233
```
210234

211235
### Adding Tools
236+
212237
Edit `ubuntutools.sh` to add system tools:
238+
213239
```bash
214240
sudo apt install -y new-tool
215241
```
216242

217243
### VS Code Extensions
244+
218245
Edit `devcontainer.json` extensions array:
246+
219247
```json
220248
"extensions": [
221249
"publisher.extension-name"
@@ -227,21 +255,25 @@ Edit `devcontainer.json` extensions array:
227255
### Common Issues
228256

229257
#### Container Build Fails
258+
230259
- Check Docker daemon is running
231260
- Verify network connectivity
232261
- Clear Docker cache: `docker system prune -a`
233262

234263
#### PowerShell Module Issues
264+
235265
- Verify PSGallery connectivity
236266
- Check module versions in `devsetup.ps1`
237267
- Clear PowerShell cache: `Clear-PackageCache`
238268

239269
#### Performance Issues
270+
240271
- Increase Docker memory allocation
241272
- Use WSL 2 backend on Windows
242273
- Enable Docker BuildKit
243274

244275
### Debug Commands
276+
245277
```bash
246278
# Check container logs
247279
docker logs <container-id>

0 commit comments

Comments
 (0)