blob: 8d3b54eeb39afe30efe7b2463a28cfef15aa9fbf (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
# Changelog
All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [Unreleased]
### Changed
- Migrated the project from sourcehut to git.eugenetriguba.com. The module path
is now `git.eugenetriguba.com/envelope` instead of
`git.sr.ht/~eugenetriguba/envelope`.
## [0.2.0] - 2025-07-19
### Added
- Support for nested struct handling
- Structs within structs are now processed recursively, allowing for nested configuration
- A parent struct field with an `env` tag acts as a prefix for all fields in its nested struct
- When a parent has no `env` tag, nested fields are accessed without prefixing
- Custom error types
- `NotPointerToStructError`: When input is not a pointer to a struct
- `UnsupportedTypeError`: When a field type cannot be parsed
- `ParseError`: When a value cannot be parsed into the target type
- Support for additional standard library types:
- `time.Duration`
- `net.IP` and `net.IPNet` (CIDR notation)
- `url.URL`
- `[]string` and `[]int` slices with comma-separated values
- Extensible type parser system
- `RegisterTypeParser` function to register parsers for custom types
- Ability to override default parsers for built-in types
### Changed
- Improved error messages with more context about failure points
### Fixed
- Boolean parsing now supports additional formats (on/off, yes/no, y/n)
- Proper handling of unexported fields in structs
## [0.1.0] - 2024-08-31
- Initial Release
|