v3.0.0
·
738 commits
to main
since this release
Immutable
release. Only release title and notes can be modified.
⚠️ Breaking Changes
- Merge sub packages (circleci, drone, github-actions, codebuild) to cienv package
- Remove the generic package
- Change struct to pointer
- Change API signature
Platform.CI()is renamed toPlatform.ID()
Features
- Add
Addfunction to support custom platforms - Add
JobURLto get a job URL
How to use
Get platform
platform := cienv.Get(nil)Support custom platforms
cienv.Add isn't goroutine safe.
cienv.Add(func(param *cienv.Param) cienv.Platform {
// Support custom platform 1
})
cienv.Add(func(param *cienv.Param) cienv.Platform {
// Support custom platform 2
})Mock Getenv and Read
platform := cienv.Get(&cienv.Param{
Getenv: mockGetenv,
Read: mockRead,
})