Skip to content
This repository has been archived by the owner on Nov 11, 2017. It is now read-only.

Fixed issues #18, #19, and #20 #21

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

icnocop
Copy link

@icnocop icnocop commented Feb 27, 2016

#18: Avoiding inserting blank lines at the end of project files by using [System.IO.File]::WriteAllText instead of out-file
#19: Removed <SolutionDir Condition="$(SolutionDir) == '' Or $(SolutionDir) == '*Undefined*'">..\</SolutionDir>
#20: Using the same file encoding when saving the file

owen2#18: Avoiding inserting blank lines at the end of project files by using [System.IO.File]::WriteAllText instead of out-file
owen2#19: Removed <SolutionDir Condition="$(SolutionDir) == '' Or $(SolutionDir) == '*Undefined*'">..\</SolutionDir>
owen2#20: Using the same file encoding when saving the file
@@ -7,6 +9,7 @@ $listOfBadStuff = @(
"\s*<Import Project=""\$\(SolutionDir\)\\\.nuget\\NuGet\.targets"".*?/>",
"\s*<Target Name=""EnsureNuGetPackageBuildImports"" BeforeTargets=""PrepareForBuild"">(.|\n)*?</Target>"
"\s*<RestorePackages>\w*</RestorePackages>"
"\s*<SolutionDir Condition=""\$\(SolutionDir\) == '' Or \$\(SolutionDir\) == '\*Undefined\*'"">\.\.\\</SolutionDir>"
Copy link
Owner

Choose a reason for hiding this comment

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

I can't accept this pull request because of this line. Some other tools might need this information to work! It also does not break automatic package restore.

Copy link
Author

Choose a reason for hiding this comment

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

I've updated the code to optionally remove the SolutionDir property based on a command line parameter.

…DirProperty command line switch

add Test solution and project
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants