Jump to content

Request for comments: A package manager for KSP mods


Autochton

Recommended Posts

This is a request for comments, and a gauge of interest for a package manager for KSP mods. I'm looking to find if this is feasible, desired, and a good use of my time.

The word 'mod' can mean both 'modification' and 'module'. We've gotten very far on the former meaning, but there are some things holding us back on the latter front, namely that mods often depend on each other, or on parts of each other, and that these dependencies may be on different versions of mods. As well, there's little way to be sure you have the up-to-date versions of mods installed (apart from a couple small mods that check version numbers), and no way to verify dependencies. There is also, for modders, no way to integrate mods with each other in a robust and stable manner, other than to distribute the mods together - not always an option.

I am looking to provide a cross-platform, outside-KSP tool to allow modders to easily define their mods as packages, and to depend on their own and others' packages, to allow players to easily install and manage installed mods, and to share mod configurations between them. I am drawing on lessons learned and conclusions drawn during the creation and use of the npm utility (widely used in Node.js applications - I work with it on a daily basis), as well as on a few other such package managers (chiefly rubygems and apt/dpkg, other tools I have worked with). It will involve a bit of work to adapt a mod to work with this system, mainly the creation of a manifest file that tells the package manager how to work with the mod, what version it is, etc., but I aim to keep the need for modification of distributions minimal. Ideally, all you'd need to do would be to create a manifest. If your mod consists of a plugin and a set of parts, it would be useful to split it up into two packages, so other mods can depend on your plugin without needing to also depend on your parts (c.f. the relationship between B9 Aerospace or KAX, and Firespitter).

So how would people feel about such a piece of software? Especially, I am interested in the thoughts of modders, without whose support this would largely be a waste of time and effort. :)

Some responses to the first questions and/or objections I suspect anyone will have:

What's the advantage, here?

As mentioned, we are currently facing a bit of a mess, where mods depend on parts (or entire wholes) of other mods, but the dependencies are not clearly formulated and difficult-to-impossible to verify or control. The typical solution is to distribute the mods with the depended-upon bits included (e.g. B9 Aerospace depending on Firespitter, Kinetech, etc., Karbonite depending on ORS), or to note the dependency on the mod download page (e.g. 6.4*Kerbin depending on Real Solar System). The former approach opens up problems with outdated plugin versions and part configurations, the latter approach can be confusing to users, and may cause glitches when a depended-upon mod updates. A package manager allows for a graceful solution to this, in that a modder can define a dependency on a mod, and the package manager will (depending on strategy/licensing/etc.) download the needed mod, or inform the user to take action.

For players, a package manager allows ease of configuration, checking for updated versions of mods, and sharing of mod configurations. The popularity of mod installers (and the headaches this causes modders) are due, simply, to the ease with which they allow installing mods. This package manager aims to provide that ease of use and functionality without modders' hair turning grey over it.

Isn't this just another mod installer/manager? Those never work.

Not at all. The specific problem with most mod managers is that they do nothing to ensure version integrity, and are not able to do anything complex (i.e. pre- and post-install scripting, etc.). They usually require a highly standardized distribution architecture to be truly useful, as well.

A package manager deals in well-defined packages and controls them against each other to ensure that the correct versions are installed. There are ways to loosen the package architecture so developer preferences can be accomodated, which are intended for inclusion here. A package manager is not going to have the problems of a mod installer, because it is a solution to those problems, and others.

This would mean making yet another distribution package, or even several. No way. Too much work.

Or you could use the package manager to build your distribution files. One thing the package manager can potentially do is to pull together the needed dependencies (as chosen by the developer) into a normal-style zip-file with a well-defined name, which can then be uploaded to wherever. For that matter, I intend to set the package manager up so it becomes a useful tool for mod development, and can be used to configure your dependencies and package suite easily and smartly.

Link to comment
Share on other sites

I'm too small a modder to make a significant difference, but I'd use it if

  • it didn't require significant changes to my workflow: currently it's just (build -> copy -> zip), if this required more than a couple steps or was difficult to automate, I wouldn't use it;
  • it didn't require me to change my hosting: right now I'm hosting on kerbalstuff, and might use github as a backup. If I had to keep track of yet another channel, I wouldn't use it.

That's really it for me. Then again, my projects have more developers than users, so we'll need the opinion of the real modders out there :)

Link to comment
Share on other sites

To begin with, I was thinking to let people handle their own hosting. I'll have to figure out the infrastructure of it (in terms of getting the information to the package manager), but basically letting a mod refer to an URL (Maybe a backup) for downloading from seems a good start.

Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...