Skip to content

Conversation

@ChrSteinert
Copy link
Contributor

This fixes #1053 temporarily until NuGet fixes this.
Because the files are not used in any manner (at least I have not found any) they can safely be removed.

@adamralph
Copy link
Contributor

Thanks!

@ChrSteinert
Copy link
Contributor Author

Ah - just saw the build fail because of a bug I introduced. Going to fix now. Please stay with me ;)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Whilst acknowledging that this is always going to be a hack, my first question is whether this is the right place to put it.

This method retreives a list of the DLLs contained within the package which are compatible with the specified framework. Is this the right place to add the side effect of removing the folders from the temp folder? If the preceding (existing) lines in the method have the side effect of creating them, then it is the right place. If not, I think it may be worth searching for a better place to put this.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, they do. Line 61 (var dlls = _package.GetLibFiles().Where(i => i.EffectivePath.EndsWith(Dll) || i.EffectivePath.EndsWith(Exe));) creates the temporary files. After this method, you have no access to the underlying SourcePath property. Therefore it has to be there (unfortunately).

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wow, that is ugly! 😲

In that case I agree, this is the right place to put this hack.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lol nuget

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Indeed - this seems it. No where else the information of created temporary folders is available. Also the NuGet method does not have any other overloads for NOT creating this ...

glennblock added a commit that referenced this pull request Feb 14, 2016
Added a hotfix which deletes temporary folders created by NuGet
@glennblock glennblock merged commit d4d8e02 into scriptcs:dev Feb 14, 2016
@glennblock
Copy link
Contributor

Thanks @ChrSteinert! We're revving up to do a release (FINALLY)

@ChrSteinert
Copy link
Contributor Author

Awesome. Really looking forward to it!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Housekeeping of file system artifacts created by NuGet.Core

4 participants