-
-
Notifications
You must be signed in to change notification settings - Fork 348
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
Support BreakingGround-DLC in instance faking #2773
Conversation
I see that the "bug" that DLCs weren't faked without error message was used in the validation scripts. But I still believe that it should behave the new way. We can use the |
This comment has been minimized.
This comment has been minimized.
Also adjust the `ckan ksp fake` syntax for KSP-CKAN/CKAN#2773
That's cool, thanks! |
This comment has been minimized.
This comment has been minimized.
Darn it, feared this would happen ;) |
This comment has been minimized.
This comment has been minimized.
a51663a
to
3b98071
Compare
'Merged' the PR, thanks. |
3b98071
to
86e7bb6
Compare
d95ecbd
to
a02d7a3
Compare
a02d7a3
to
6d757f5
Compare
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
It's because I just forgot to put a |
* Redo `ckan ksp fake` command syntax. * Adjust `CloneFakeKspDialog` * Extend IDlcDetector with `InstallPath()` and `AllowedOnBaseVersion()`. * Make `FakeInstance()` a transaction, cover IO operations in `CopyDirectory()` transaction, make `KSP.SetupCkanDirectories()` transaction aware and add bool argument to skip directory scanning.
6d757f5
to
688e4ca
Compare
Okay, some more changes:
|
Does the bot skip network-dependent tests? |
I believe so: Line 43 in 1ac6261
|
Yep, just discovered that flag. Was wondering, because on my machine I obviously fail the two Curseforge tests. |
Got a bit bigger than I thought.
(And it's getting bigger and bigger)
Changes
Important stuff first:
Console command for faking changed!
It is now
ckan ksp fake <name> <path> <version> [--MakingHistory <version>] [--BreakingGround <version>]
instead of previous
ckan ksp fake <name> <path> <version> [MakingHistoryVersion]
.I think this is more future-proof.
I am going to try my luck adjusting KSP-CKAN/xKAN-meta_testing.
IDlcDetector
:I added
string InstallPath()
, it returns the install path relative to the GameDir, that means for example"GameData/SquadExpansion/Serenity"
.Depending on how this idea of mine will be implemented (if at all), we might restructure the whole thing again. But I think this is the best solution for now, I'm open for feedback.
I added
bool AllowedOnBaseVersion(KspVersion)
, it returns whether a DLC is allowed to be installed or faked on a given basegame version.I added
to allow accessing those two from outside the interface implementations.
I changed the two fields with these names inside
StandardDlcDetectorBase
to getter without setter (this effectively is like thereadonly
modificator before).CloneFakeInstanceDialog
:The GUI
CloneFakeInstanceDialog
has been adjusted:If Squad releases another 10 DLCs we might get out of space and need a new system, but for now it works.
FakeInstance()
:FakeInstance()
is now a transaction.Before the DLC just wasn't faked if f.e. the KSP version was < 1.4.0.
This left the user in an unfavorable situation, he had to delete the new folder and run
ckan ksp forget
once and try again to include the DLC. now it's all or nothing.FakeInstance()
takes the DLCs that should be faked asDictionary<IDlcDetector, KspVersion>
. Future DLC releases shouldn't need a change in this fuction.Also
CopyDirectory()
is now a real transaction that includes IO operations, if I understand stock .NET transactions right they don't include them, but usingChinhDo.Transactions
withTxFileManager
should fix this.Correct me if I got something wrong there (or anywhere else too of course).
Fixes #2791
Oh yeah, #2749 needs another rebase ^^