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

Building with Visual Studio. #53

Open
wants to merge 4 commits into
base: dev
Choose a base branch
from
Open

Building with Visual Studio. #53

wants to merge 4 commits into from

Conversation

PiezPiedPy
Copy link
Contributor

@PiezPiedPy PiezPiedPy commented Jul 15, 2018

Hard-coded file paths in Visual Studio .csproj file have been removed and replaced with an Environment variable $KSPDEVDIR.

  • Allows contributors to have different locations for their development builds. e.g. I use "F:/KSP_DEV/" someone else might use their steam install and another person may use their D Drive, by using an Env Var to point to the install path the .csproj file does not need to be edited to suit each contributors individual preferences.
  • Added a bit of info regarding the Env var to the Readme.md
  • Note. dll is copied from the $KSPDEVDIR/GameData/CryoTanks/Plugins/ dir to the GameData/CryoTanks/Plugins/ dir of local repo.

Also brought the .csproj file up to date with these changes:

  • Toolsversion updated to v.12.
  • Un-needed references removed.
  • References set to not copy to output.
  • Debug symbols turned off for Release builds.
  • Full Debug symbols for Debug builds.

Removed local build files from repo and added .gitignore and .gitattributes files.

Toolsversion updated to v12
Un-needed references removed.
References set to not copy to output.
Debug symbols turned off for Release builds
Full Debug symbols for Debug builds
Hard-coded file paths in VS proj file have been removed and replaced with an Environment variable $KSPDEVDIR.
Allows contributors to have different locations for their development builds.
@PiezPiedPy PiezPiedPy changed the base branch from master to dev July 15, 2018 18:01
@ChrisAdderley
Copy link
Collaborator

Idea - wouldn't it be better for the future to only include actual code in the repo. I mean, I've kinda been developing by myself with not ever considering others so I just dumped all the VCS project files up here.

@PiezPiedPy
Copy link
Contributor Author

Leaving only the source means new contributors have to set up their own solution which means importing the source files into their solution, then adding references and also setting output directories etc.
Also there is high risk of the Assembly version not being set up correctly, unless of course that file remains with the source.

Personally I think it's better for new contributors who use VS to be able to just click on the .sln file and all is ready to go. The only thing they have to do is set their Env variable to the KSP directory they wish to use.

We use this system with Kerbalism and Trajectories and also have build scripts to build the Release.zip for Release builds and for Debug builds generate the mono-debug .mdb file for debugging with Unity if contributors wish to integrate Unity into their debugging scheme.
See https://github.com/steamp0rt/Kerbalism/tree/master/buildscripts

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.

2 participants