fsprojects / fsprojects/Paket

<Import Project="..\.paket\paket.targets" /> is moved around in project files

Open
#3,263 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
F#
Stars
2.1k
Forks
528
Avg merge
1d 12m
Merged PRs (30d)
54

Description

This happens in all fsproj and csproj files in a .NET Framework 4.6.1 only solution.

The tag is :

<Import Project="..\.paket\paket.targets" />

When doing an "install", the tag is moved before all the Choose tags. When doing "auto-restore on", or possibly some other command, the tag is moved to the very bottom of the Project tag.

In other words, the tag moves around needlessly, and cause unneeded changes in commits unless taken care of.

Known workarounds

Alternative 1 : Go through files to be committed, and remove unneeded changes.

Alternative 2 : Run some command that doesn't effectively do anything except restore the placement of the tag. I do an "auto-restore on" to achieve this.

At some point in my development I had to decide which placement I wanted to be the right one, and I decided to go with the placement at the bottom. So I do "install" and then follow up by some other "dummy" command that fixes the placement.

Other info

Version 5.172.2 and 5.173

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the behavior in a .NET Framework 4.6.1 solution containing fsproj and csproj files by running install and auto-restore on. Compare the placement of the Paket Import tag before and after each command, then trace the project-file processing that changes it. Done means the tag remains in one consistent location without needless project-file changes.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp, fsharp
Domain
build-system
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.