-
Notifications
You must be signed in to change notification settings - Fork 86
What am I doing wrong? #140
Comments
Do you see the *.srcsrv file in the folder? If so, you can open the symbol file in the Notepad. |
No, I can see that I have gitlink in the packages as a developmentDependency and a binary reference in the project., but that's it - there's no change to the project's build targets so I don't see how it's going to achieve anything. |
@phatcher can you confirm which NuGet Package you have installed? Sounds like you have added this one: https://www.nuget.org/packages/gitlink/ Which contains the exe and pdb, where as I think you want this one: https://www.nuget.org/packages/gitlinktask/ which contains the exe, dll, pdb and associated targets file. |
I do have gitlink - that's what the front page says to install. Just tried to use gitlinktask and it wouldn't install into my project (which is .NET 4.5) - I notice the package does not have a lib folder install-package : Could not install package 'gitlinktask 2.4.1'. You are trying to install this package into a project that targets '.NETFramework,Version=v4.5', but the package does not contain any assembly references or content files that are compatible with
|
The issue that you are seeing is that the readme in the develop branch (which is the default branch) tells you about the new, soon to be released version of GitLink, and not the one that is currently pushed to nuget.org, i.e. 2.4.1. I would point you here: https://github.com/GitTools/GitLink/tree/master For information about the GitLink and GitLinkTask packages which are currently pushed to NuGet.org. |
Ah thanks, hadn't noticed that I was on the develop branch, so at the moment it has to process the source and the new one will process the pdb directly? |
I would need @GeertvanHorrik or @AArnott to confirm that one. Personally, I run GitLink through a Cake task: https://github.com/cake-contrib/Cake.Recipe/blob/develop/Cake.Recipe/Content/gitlink.cake#L9 So I haven't used the approach that you are describing, I just know about it's existence 😄 |
@phatcher: yes, the gitlink in the develop branch can just be given the pdb file and it will do all the work without a bunch of the other integration with MSBuild. |
@AArnott I'll have a go at that and get back to you - will make it easier to integrate into my Fake build script as it would just be another task after the tests but before the nuget pack |
Why add a task at all? So long as you're using MSBuild to compile your projects, PdbGit does it as part of that. |
I need it as a separate task as it operates on the pdbs in the build directory, so I do the task after the tests are run successfully but before the pack. You end up with something like...
I notice that it only takes a single file i.e. it won't accept a filespec *.pdb which might be a useful change, though I suppose you'd have to be careful specifying it so you don't process for third-party assemblies |
@phatcher what you're doing and asking for makes sense. But I still don't understand why you can't do it as part of your msbuild. You say you rewrite the PDB after tests pass, but why not do it when the PDB is first created? In the future, Roslyn compilers will support passing data to the compiler so that the PDB has source server support without rewriting, which would mean this is all front-loaded, very similar to pdbgit doing it directly after compilation. So what is your concern with doing this write after compilation? |
@AArnott Sorry I think I was misunderstanding - couldn't see how I can pass this as an argument to MSBuild. Do I basically install this as a solution-level package and it adds targets to the solution to do the source indexing? |
Almost. Install the package to each of your individual projects. |
Thanks |
Steps to reproduce
Platform:
.NET version: 4.5
Expected behaviour
Should have the symbols replaced
Actual behaviour
Symbol still pointing locally
Code is available at https://github.com/phatcher/Meerkat.Security
Also some advice on how incorporate into a FAKE script without adding the NuGet package would be nice.
The text was updated successfully, but these errors were encountered: