Skip to content
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

Paket should keep paket.dependencies as stable as possible #802

Merged
merged 3 commits into from
Apr 30, 2015
Merged

Conversation

forki
Copy link
Member

@forki forki commented Apr 29, 2015

Idea:

Instead of serializing the Dependencies file from the already parsed information we always modify the text and reparse it. Maybe not the best style, but it keep comments and everything in place.

fixes #780, #731

This needs a lot of testing. Especially the convert-from-nuget stuff (cc @theimowski)

/cc @matthid, @cjbhaines, @mexx, @inosik , @haf

@@ -399,7 428,7 @@ type DependenciesFile(fileName,options,sources,packages : PackageRequirement lis
if NormalizedPackageName p.Name = NormalizedPackageName packageName then
{ p with VersionRequirement = versionRequirement }
else p)
DependenciesFile(this.FileName, this.Options, sources, packages, this.RemoteFiles, comments)
DependenciesFile(this.FileName, this.Options, sources, packages, this.RemoteFiles, textRepresentation)
Copy link
Member

Choose a reason for hiding this comment

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

Text representation have to be updated in this case.

Copy link
Member Author

Choose a reason for hiding this comment

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

oups. correct.

Writing a test since this is uncovered.

Copy link
Member Author

Choose a reason for hiding this comment

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

fixed in 93ca6f8

@theimowski
Copy link
Member

I'll do some testing on Friday

@theimowski theimowski closed this Apr 29, 2015
@theimowski theimowski reopened this Apr 29, 2015
@forki
Copy link
Member Author

forki commented Apr 29, 2015

huh. I accidentally realigned the whole file. reverting that

@forki forki merged commit a062fcc into master Apr 30, 2015
@forki
Copy link
Member Author

forki commented Apr 30, 2015

it's in 1.3.0-alpha001

@theimowski
Copy link
Member

I think dependenciesFile is a good candidate for Property-Based round-trip test (parse, format, compare). Would need better tracking of comments/ custom code and similar stuff tho.

@forki
Copy link
Member Author

forki commented Apr 30, 2015

would love to see that.

2015-04-30 21:07 GMT 02:00 Tomasz Heimowski [email protected]:

I think dependenciesFile is a good candidate for Property-Based
round-trip test (parse, format, compare). Would need better tracking of
comments/ custom code and similar stuff tho.


Reply to this email directly or view it on GitHub
#802 (comment).

@theimowski
Copy link
Member

changes in NugetConver look ok - tested on a simple scenario, accidently also found a bug in the convert logic itself - fix in #804

@forki
Copy link
Member Author

forki commented Apr 30, 2015

so ready to release?

@theimowski
Copy link
Member

:shipit:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Paket Update messes with sources in paket.dependencies
3 participants