jsimmons Posted March 6, 2016 Share Posted March 6, 2016 Hello. I'm looking to add CKAN support to my mod and the question I have is about optional support mods. What is the best way to handle this? Can CKAN pause and ask the user if they want to download these optional mods? Link to comment Share on other sites More sharing options...
hab136 Posted March 7, 2016 Share Posted March 7, 2016 (edited) 22 hours ago, jsimmons said: Hello. I'm looking to add CKAN support to my mod and the question I have is about optional support mods. What is the best way to handle this? Can CKAN pause and ask the user if they want to download these optional mods? Yes, it pauses and asks users if you use "recommends" or "suggests": https://github.com/KSP-CKAN/CKAN/wiki/Adding-a-mod-to-the-CKAN#dependencies-or-recommended-companion-mods Edited March 7, 2016 by hab136 Link to comment Share on other sites More sharing options...
politas Posted March 7, 2016 Share Posted March 7, 2016 5 hours ago, hab136 said: Yes, it pauses and asks users if you use "recommends" or "suggests": https://github.com/KSP-CKAN/CKAN/wiki/Adding-a-mod-to-the-CKAN#dependencies-or-recommended-companion-mods With the difference that "recommends" mods appear as selected, so the user has to opt-out, while "suggests" mods are unselected, so the user has to opt-in. The CKAN Wiki has full details. Link to comment Share on other sites More sharing options...
Streetwind Posted March 7, 2016 Share Posted March 7, 2016 Here's a question I couldn't find an answer to with a cursory search through this thread: Is removing a mod from CKAN a thing that's within the scope of things that should happen? I'm asking because I notice that Github is starting to truncate the list of entries in the NetKAN repository, meaning there'll be a growing number of entries which will be very difficult to access in order to update them. And well, I have a few minor entries for optional extras that are either deprecated now or will become deprecated with 1.1. Since all of Nertea's stuff is moving to Github, I'm not sure CKAN will be able to offer installs for anything other than the very latest KSP version. And even if it can, there are no releases prior to 1.0.5 or maybe even 1.1 available on Github anyway. So it makes no sense for the repository to carry around the .netkan file for something that's only valid for 1.0.4 or earlier. So from my logic, it would make sense to just remove the deprecated stuff. However, what "my logic" has told me to make sense has been repeatedly explained to me as totally not how CKAN works on pretty much every occasion so far Hence I thought I'd ask first. Do I remove the unneeded files, or are they designed to remain in the repository forever? Link to comment Share on other sites More sharing options...
politas Posted March 8, 2016 Share Posted March 8, 2016 For mods that have disappeared forever, we "freeze" the files by changing the extension from ".netkan" to something else (eg ".kerbalstuff" for mods lost that way), so that we maintain the history of names in order to not have duplicated keys. We are maintaining mirrors for old versions of mods (where licencing allows), so that people who want to go back and experience an old version of KSP can still add at least some mods to it, but that's related to the .ckan files, not the .netkans. As for the difficulty of seeing entries, my understanding is that it is only folders that get left off the list, not files, so by knowing the folder name, you can always type in the path to a folder. Also, by making a local fork, it's very easy to see all the files using a local file manager. Link to comment Share on other sites More sharing options...
hab136 Posted March 8, 2016 Share Posted March 8, 2016 4 hours ago, politas said: As for the difficulty of seeing entries, my understanding is that it is only folders that get left off the list, not files, so by knowing the folder name, you can always type in the path to a folder. Also, by making a local fork, it's very easy to see all the files using a local file manager. Github's web UI will hide files too if the list is too long: " Sorry, we had to truncate this directory to 1,000 files. 89 entries were omitted from the list. " when looking at https://github.com/KSP-CKAN/NetKAN/tree/master/NetKAN (which only contains files). This is only a limitation of the web UI; it doesn't affect the actual files. Still, the web UI is super convenient when you just want to edit one file; Github will set up a fork and then pull request when you use their built-in editor, so with a few clicks you can edit your NetKAN entry while you're on break at work. One solution is to break up the giant directory into subdirectories by first letter: /A/AutoRove /A/AutoAsparagus /B/B9 /B/BDArmory /C/Chatterer /C/CustomBiomes The NetKAN and CKAN-meta directories could use this, but then flatten it again when creating the master.zip file for the client, if needed. Link to comment Share on other sites More sharing options...
NecroBones Posted March 8, 2016 Share Posted March 8, 2016 If you know the name of what you're looking for, you can also use the UI's search and get to the files that fell off the end of the list. Link to comment Share on other sites More sharing options...
Streetwind Posted March 8, 2016 Share Posted March 8, 2016 5 hours ago, politas said: For mods that have disappeared forever, we "freeze" the files by changing the extension from ".netkan" to something else (eg ".kerbalstuff" for mods lost that way), so that we maintain the history of names in order to not have duplicated keys. We are maintaining mirrors for old versions of mods (where licencing allows), so that people who want to go back and experience an old version of KSP can still add at least some mods to it, but that's related to the .ckan files, not the .netkans. As for the difficulty of seeing entries, my understanding is that it is only folders that get left off the list, not files, so by knowing the folder name, you can always type in the path to a folder. Also, by making a local fork, it's very easy to see all the files using a local file manager. Alright, I'll see about renaming files as they become unneeded. Link to comment Share on other sites More sharing options...
politas Posted March 8, 2016 Share Posted March 8, 2016 Ok, I've raised an issue for discussion about the folder truncation on Github. Feel free to add to the discussion there. Link to comment Share on other sites More sharing options...
Taowulf Posted March 9, 2016 Share Posted March 9, 2016 On 3/5/2016 at 5:15 PM, politas said: Can you check using these instructions? .Net Framework 4.6.1 Link to comment Share on other sites More sharing options...
Verkio Posted March 9, 2016 Share Posted March 9, 2016 Could you help? Whenever I run CKAN, it shows a pop-up and it shows if it can add a handler. I clicked no, and everything was fine and CKAN was running. But then the next day, I run it again and it shows the pop-up again. I clicked no, then nothing happened. Then, when I tried to run CKAN again, it shows that unhandled exception pop-up. I already have .NET 4.5 installed, so I don't know what's happening. Link to comment Share on other sites More sharing options...
John FX Posted March 9, 2016 Share Posted March 9, 2016 Hello, I would like to say thanks for CKAN, it is one of the best things to happen to KSP. I also have a feature request. I recently updated RP-0 and in the changelog it said that testflight and shipmanifest had been added to the recommended mods. I went into CKAN and updated RP-0 but there was not any point where I was asked if I wanted to install either mod. Could I request that when a mod has changed it`s recommended mods (don`t know about required, maybe that already happens there) the user is asked if they want to install either all the recommended mods or just the ones that have been added please? I would imagine some people would want to be notified if the list of required or recommended mods has a mod removed from it also. Link to comment Share on other sites More sharing options...
jdcr Posted March 11, 2016 Share Posted March 11, 2016 I have a few quick questions about the KSP installs management of CKAN on Linux (Mint 17) and would appreciate it if anybody could help. Here's what I did: I have one KSP install in the standard Steam directory (/home/me/.steam/steam/steamapps/common/Kerbal Space Program) and another one which I would like to mod (/home/me/.steam/steam/steamapps/common/Kerbal Space Program Modded). I downloaded ckan.exe and put it in the second directory. Unfortunately, CKAN only finds the first install (as expected), but I can't get it to recognise the second one. The problem is that the directory selection dialogue (a standard Mono window I suppose?) doesn't show hidden directories (.steam) and it doesn't allow entering the path as text. It's basically this bug, only on Linux. So I tried adding the second install via the command line: cd /home/me/.steam/steam/steamapps/common/Kerbal\ Space\ Program\ Modded ./ckan.exe ksp add Modded /home/me/.steam/steam/steamapps/common/Kerbal\ Space\ Program\ Modded Added "Modded" with root "/home/me/.steam/steam/steamapps/common/Kerbal Space Program Modded" to known installs At first, this seems to work: ./ckan.exe ksp list Listing all known KSP installations: 1) "Modded" - Z:/home/me/.steam/steam/steamapps/common/Kerbal Space Program Modded However, when I start the CKAN GUI, it only has the "auto" KSP install (pointing to the default Steam directory which I would like to keep vanilla). So here are my questions, also TL;DR: Are there separate settings (in particular the list of KSP installs) for the GUI and the cli versions of CKAN? Where are those settings stored? Can I manually edit them? All I can find are "CKAN" directories inside both of my installs, but as far as I can tell after a quick scan through the files, none of them contains this information. Where does that "Z:" in "ckan.exe ksp list" come from? Is it a Mono thing? I don't like that CKAN (despite residing in my second install) puts stuff into my default install. I hope I can just remove the CKAN directory there and it's all gone. Right? Link to comment Share on other sites More sharing options...
Octa Posted March 11, 2016 Share Posted March 11, 2016 I hope these weren't suggested before, but i just found 2 features for the client that'd be nice: Reverse dependency on local mods I want to tidy up my installation, but i can't see which mods where installed by myself and which mods where installed because of an dependency My suggestion: Add fields like "required by", "suggested by", "supported by". etc which are only filled locally with the information provided by the locally installed mods.Should be up do date if this is done every time a new mod is installed...i'd query for myself using the CLIs and some bash/perl-script, but i dont have a linux system available.... Disable Mods / temporary uninstall uninstall mods for debug reasons, but keep the information saved in the program so the can be re-insalled fast Well....they go in the category "Surely, there are ways around it, but it'd be nice to have directly integrated".... Link to comment Share on other sites More sharing options...
Brigadier Posted March 11, 2016 Share Posted March 11, 2016 4 hours ago, Octa said: Disable Mods / temporary uninstall uninstall mods for debug reasons, but keep the information saved in the program so the can be re-insalled fast Doesn't it do this already? The CKAN cache keeps the mod download package even though you uninstall the mod from KSP. Link to comment Share on other sites More sharing options...
Octa Posted March 12, 2016 Share Posted March 12, 2016 2 minutes ago, Brigadier said: Doesn't it do this already? The CKAN cache keeps the mod download package even though you uninstall the mod from KSP. i meant a feature which shows the recently uninstalled mods, no caching, as this has no usable history for the user. If you want to track down a problem, you uninstall a bunch of mods, re-test if the issue still exists and repeat that until it's gone. Then you re-install the mods again until it re-appears. Remember the exact name of all mods you have installed so you can 100% rollback? Was it Mk2 Extended, Mk2 Essentials or Mk2 Expansion? Easiest way would be to make the status log persistent in the ckan directory of the KSP instance, so you could see what happened after each "Execute changes" Link to comment Share on other sites More sharing options...
Brigadier Posted March 12, 2016 Share Posted March 12, 2016 @Octa, got it. I understand now. On another topic, the latest version of Near Future Propulsion is v0.6.1 but CKAN keeps pulling v0.5.4 and reporting v0.6.0 in the UI. The .version file in the NFP folder says v0.5.4 so I'm a little confused. KSP-AVC reports it correctly. Link to comment Share on other sites More sharing options...
politas Posted March 12, 2016 Share Posted March 12, 2016 22 hours ago, jdcr said: I have a few quick questions about the KSP installs management of CKAN on Linux (Mint 17) and would appreciate it if anybody could help. Here's what I did: I have one KSP install in the standard Steam directory (/home/me/.steam/steam/steamapps/common/Kerbal Space Program) and another one which I would like to mod (/home/me/.steam/steam/steamapps/common/Kerbal Space Program Modded). I downloaded ckan.exe and put it in the second directory. Unfortunately, CKAN only finds the first install (as expected), but I can't get it to recognise the second one. The problem is that the directory selection dialogue (a standard Mono window I suppose?) doesn't show hidden directories (.steam) and it doesn't allow entering the path as text. It's basically this bug, only on Linux. So I tried adding the second install via the command line: cd /home/me/.steam/steam/steamapps/common/Kerbal\ Space\ Program\ Modded ./ckan.exe ksp add Modded /home/me/.steam/steam/steamapps/common/Kerbal\ Space\ Program\ Modded Added "Modded" with root "/home/me/.steam/steam/steamapps/common/Kerbal Space Program Modded" to known installs At first, this seems to work: ./ckan.exe ksp list Listing all known KSP installations: 1) "Modded" - Z:/home/me/.steam/steam/steamapps/common/Kerbal Space Program Modded However, when I start the CKAN GUI, it only has the "auto" KSP install (pointing to the default Steam directory which I would like to keep vanilla). So here are my questions, also TL;DR: Are there separate settings (in particular the list of KSP installs) for the GUI and the cli versions of CKAN? Where are those settings stored? Can I manually edit them? All I can find are "CKAN" directories inside both of my installs, but as far as I can tell after a quick scan through the files, none of them contains this information. Where does that "Z:" in "ckan.exe ksp list" come from? Is it a Mono thing? I don't like that CKAN (despite residing in my second install) puts stuff into my default install. I hope I can just remove the CKAN directory there and it's all gone. Right? To get around the hidden directory thing, you could make a directory /home/me/KSP and symlink your "Kerbal Space Program" and "Kerbal Space Program Modded" directories into it. Link to comment Share on other sites More sharing options...
jdcr Posted March 12, 2016 Share Posted March 12, 2016 (edited) 16 minutes ago, politas said: To get around the hidden directory thing, you could make a directory /home/me/KSP and symlink your "Kerbal Space Program" and "Kerbal Space Program Modded" directories into it. Yes I could, but I'd rather understand what the program does to my system. The fact that it seems to store information where I can't find it makes me very uncomfortable. After all, it doesn't have an uninstall routine other than "just delete ckan.exe and the CKAN folder". I'm also confused why a KSP installation added via command line doesn't show up in the GUI. This is either a bug or my understanding of CKAN is completely wrong. Edit: Ok, turns out the GUI version stores its known KSP instances in ~/.mono/registry/CurrentUser/software/ckan/values.xml. I am able to manually add instances there. I still have no idea where the command line interface stores its values. Edited March 12, 2016 by jdcr Link to comment Share on other sites More sharing options...
politas Posted March 13, 2016 Share Posted March 13, 2016 (edited) On 11/03/2016 at 8:09 PM, jdcr said: At first, this seems to work: ./ckan.exe ksp list Listing all known KSP installations: 1) "Modded" - Z:/home/me/.steam/steam/steamapps/common/Kerbal Space Program Modded Where does that "Z:" in "ckan.exe ksp list" come from? Is it a Mono thing That's a good question. I'm wondering what you have set up that allows you to just run ckan.exe without putting "mono " before it. Could you be running the CLI in WINE or emu or some such? You shouldn't have any "z:" showing up if things are working normally. Edited March 13, 2016 by politas Link to comment Share on other sites More sharing options...
pjf Posted March 13, 2016 Author Share Posted March 13, 2016 (edited) On 11/3/2016 at 8:09 PM, jdcr said: So here are my questions, also TL;DR: Are there separate settings (in particular the list of KSP installs) for the GUI and the cli versions of CKAN? Where are those settings stored? Can I manually edit them? All I can find are "CKAN" directories inside both of my installs, but as far as I can tell after a quick scan through the files, none of them contains this information. Where does that "Z:" in "ckan.exe ksp list" come from? Is it a Mono thing? I don't like that CKAN (despite residing in my second install) puts stuff into my default install. I hope I can just remove the CKAN directory there and it's all gone. Right? 1. The CLI and GUI both store settings in the ".NET Registry". 2. On linux the .NET registry is at ~/.mono/registry/CurrentUser/software/ckan/values.xml . You can edit them if you want 2a. You may find it easier to use `ckan.exe ksp list`, `ckan.exe ksp add <name> <path>`, and `ckan.exe ksp default <name>` to adjust the settings. These also won't have problems with any "hidden" directories. 3. That's *weird*. I don't see a 'Z:' drive at all, and I'm using mono/Linux. There's a good chance if you remove the `Z:` things will work; or at least be differently broken. (This should be pretty straightforward editing `values.xml`). 4. You can totally remove the CKAN directory and everything's gone. Of course, that won't remove any mods you've installed using the CKAN. There's also a super-easy option of just copying ckan.exe to the install you'd like it to use, and starting it from there. We *always* look in the same directory as the executable for an install first, which is convenient for all sorts of things like mobile installs that may not have a stable path.Edit: Or at least, I thought we always look in the same location. I'm checking this after lunch! Hope this helps! ~ Paul Edited March 13, 2016 by pjf Link to comment Share on other sites More sharing options...
pjf Posted March 13, 2016 Author Share Posted March 13, 2016 1 hour ago, politas said: That's a good question. I'm wondering what you have set up that allows you to just run ckan.exe without putting "mono " before it. Could you be running the CLI in WINE or emu or some such? You shouldn't have any "z:" showing up if things are working normally. That's a really good theory. The CKAN executable would work fine both under wine/.NET and mono, but those systems would present different views to the code itself. It would *also* result in registry settings being stored in different locations (~/.mono/registry under Linux, and the emulated Windows registry under wine). Wine would also present a `Z:` drive to provide a shim to your Linux filesystems. If you start the process with `mono ckan.exe` (for the GUI) or `mono ckan.exe <cmd>` (for the cmdline, with <cmd> being your command), then that should make sure it's always running in the same environment, and using the same KSP directory locations. Link to comment Share on other sites More sharing options...
jdcr Posted March 13, 2016 Share Posted March 13, 2016 4 hours ago, politas said: That's a good question. I'm wondering what you have set up that allows you to just run ckan.exe without putting "mono " before it. Could you be running the CLI in WINE or emu or some such? You shouldn't have any "z:" showing up if things are working normally. You are exactly right. I thought I had set up my system to always run .exe with mono but apparently the console still uses wine, whereas the desktop correctly takes mono as a default. When I start the GUI via wine, I find exactly the values that I entered on the console and if I use mono ckan.exe on the console, I get to set the path for the mono GUI version. Rather embarrassing that I didn't think of that. Anyway, thank you all very much for your help! Link to comment Share on other sites More sharing options...
jdcr Posted March 13, 2016 Share Posted March 13, 2016 4 hours ago, pjf said: There's also a super-easy option of just copying ckan.exe to the install you'd like it to use, and starting it from there. We *always* look in the same directory as the executable for an install first, which is convenient for all sorts of things like mobile installs that may not have a stable path. I just tested that and it seems that if there is a valid Steam install and the registry key does not exist, the Steam install gets picked over ckan.exe's directory. Link to comment Share on other sites More sharing options...
pjf Posted March 13, 2016 Author Share Posted March 13, 2016 1 hour ago, jdcr said: I just tested that and it seems that if there is a valid Steam install and the registry key does not exist, the Steam install gets picked over ckan.exe's directory. Oh drat. That's a bug. I've opened an issue for us to track it. But with that aside, you're now able to use CKAN with your preferred install? Link to comment Share on other sites More sharing options...
Recommended Posts