Skip to content

Commit 2c3593e

Browse files
committed
add README about DOTNET_ROLL_FORWARD (refer issue #39)
1 parent d25b19f commit 2c3593e

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

README.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,18 @@ list-api --load-reflection-only Library/bin/Release/net8.0/Library.dll
7373

7474
Type `list-api --help` to show usage about command line arguments and options.
7575

76+
77+
78+
If you are loading an assembly that targets a newer version than the runtime version that the `list-api` command targets, try running it with the [DOTNET_ROLL_FORWARD](https://learn.microsoft.com/dotnet/core/versions/selection) environment variable.
79+
80+
```sh
81+
# Installs list-api targeting .NET 6.0
82+
dotnet tool install --framework net6.0 -g Smdn.Reflection.ReverseGenerating.ListApi
83+
84+
# Uses runtime roll forwarding to load the assembly targeting .NET 8.0
85+
DOTNET_ROLL_FORWARD=LatestMajor list-api Library/bin/Release/net8.0/Library.dll
86+
```
87+
7688
## Limitations
7789
This tool does not provide any options for code styles including spaces, indents, and new lines. Use `dotnet format` after generating to format such code styles.
7890

0 commit comments

Comments
 (0)