File tree Expand file tree Collapse file tree 2 files changed +19
-3
lines changed
Expand file tree Collapse file tree 2 files changed +19
-3
lines changed Original file line number Diff line number Diff line change @@ -5,8 +5,14 @@ All notable changes to this project will be documented in this file.
55The format is based on [ Keep a Changelog] ( https://keepachangelog.com/en/1.0.0/ ) ,
66and this project adheres to [ Semantic Versioning] ( https://semver.org/spec/v2.0.0.html ) .
77
8- ## Unreleased
8+ ## 0.4.0 - 2025-07-21
9+
10+ This release supports compile-time rewriting of source files via ` toolexec ` .
11+ Build your package or binary with ` go build -toolexec errtrace ` and all packages
12+ that import ` errtrace ` will be automatically instrumented with ` errtrace ` .
13+
914### Added
15+
1016- Add ` UnwrapFrame ` function to extract a single frame from an error.
1117 You can use this to implement your own trace formatting logic.
1218- Support extracting trace frames from custom errors.
Original file line number Diff line number Diff line change @@ -259,7 +259,7 @@ go install braces.dev/errtrace/cmd/errtrace@latest
259259errtrace offers the following modes of usage:
260260
261261* [ Manual instrumentation] ( #manual-instrumentation )
262- * [ Automatic instrumentation] ( #automatic-instrumentation )
262+ * [ Automatic instrumentation] ( #automatic-instrumentation ) on [ save ] ( #automatic-instrumentation-on-save ) or at [ compile time ] ( #automatic-compile-time-instrumentation ) .
263263
264264### Manual instrumentation
265265
@@ -344,10 +344,20 @@ errtrace -w example.com/path/to/package
344344errtrace -w ./...
345345```
346346
347+ #### Automatic instrumentation on save
348+
347349errtrace can be set be setup as a custom formatter in your editor,
348350similar to gofmt or goimports.
349351
350- #### Opting-out during automatic instrumentation
352+ #### Automatic compile-time instrumentation
353+
354+ ![ experimental] ( http://badges.github.io/stability-badges/dist/experimental.svg )
355+
356+ errtrace can rewrite files as part of compilation by passing a ` -toolexec ` flag.
357+ Build your package or binary with ` go build -toolexec=errtrace ` and all packages
358+ that import ` errtrace ` will be automatically instrumented.
359+
360+ ### Opting-out during automatic instrumentation
351361
352362If you're relying on automatic instrumentation
353363and want to ignore specific lines from being instrumented,
You can’t perform that action at this time.
0 commit comments