[Bug π]: Lightly borked project file
keyspace opened this issue Β· 5 comments
Brief description of your issue (aka the problem)
After commit ca27df7, the solution cannot be opened in either MSVS 2019 or 2022:
C:\Users\keysp\source\repos\OhScrap\source\OhScrap\OhScrap.csproj : error : The project file could not be loaded. The 'ItemGroup' start tag on line 41 position 4 does not match the end tag of 'Reference'. Line 58, position 7. C:\Users\keysp\source\repos\OhScrap\source\OhScrap\OhScrap.csproj
There is a stray </Reference>
closing tag where the previous tag already has an inline close.
Removing the stray allows opening the project/solution.
Operating system
No response
KSP version
N/A
Version of addon
git master
Steps to reproduce the behavior or issue
- Clone the repo.
- Launch the solution.
Expected behavior
Solution opens.
Actual behavior
Error as outlined.
Environment
N/A
Log files
No response
Screenshots
No response
Additional context
No response
How did you download and install this?
GitHub clone (expert manual installation)
π Thank you @keyspace
ββ
Have you reviewed the open issues logs and recent changelogs?
In order to help us help you, please provide:
- <KSP_ROOT>/KSP.LOG
- and one of the following:
- if Module Manger is installed
- <KSP_ROOT>/GameData/ModuleManager.ConfigCache
- if Module Manger /L is installed
- <KSP_ROOT>/PluginData\ModuleManager\ConfigCache.cfg
- if Module Manger is installed
- Screenshots of issue (if appropriate) (images tell a much stronger tale)
You can archive these files (rar or zip, sadly no 7zip) and drag-n-drop them into an issue comment
π³πPlease either watch this repositiory for updates.
π¬Kindly read our simple guides to:
- contributing
- our expected code of conduct (hint: we are all adults here)
- our style guide.md
These are boilerplate.'
Not sure if intended, but the same commit changed <TargetFrameworkVersion>
to v3.5, which makes the solution impossible to compile for me.
For anyone wanting to build right now:
Removing the stray line, changing .NET back to v4.7.2 (and leaving the pre/post build hooks in Project->Properties->Build Events, i.e. not heeding Microsoft's security warning) allows the solution to be built.
The post-hook will fail, since the deploy scripts are not in the repo (IMO that's good). The pre-hook is required, as otherwise version information will not be populated, and building will fail with a cryptic error referencing Version.Text
.
Also, set K112
environment variable to C:\Program Files (x86)\Steam\steamapps\common\Kerbal Space Program\KSP_x64_Data\Managed\
, or wherever the .dll
s are. Yes, trailing backslash.
Thank you @keyspace !
Not sure if intended, but the same commit changed
<TargetFrameworkVersion>
to v3.5, which makes the solution impossible to compile for me.
In order to compile against .NET 3.5. the following line needs to read:<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
OhScrap/source/OhScrap/OhScrap.csproj
Line 2 in ca27df7
Also, set
K112
environment variable toC:\Program Files (x86)\Steam\steamapps\common\Kerbal Space Program\KSP_x64_Data\Managed\
, or wherever the.dll
s are. Yes, trailing backslash.
All good - I use environmental variables so I can easily and quickly compile against all major versions of KSP.