aliens

Author Topic: ModPack Installer  (Read 12799 times)

Offline myk002

  • Colonel
  • ****
  • Posts: 227
    • View Profile
Re: ModPack Installer
« Reply #15 on: April 30, 2015, 08:19:24 pm »
just FYI, mod formats will be getting a makeover soon.  the new package format includes a metadata file that will contain a url.  we can use that to drive autoupdate.

Offline DoxaLogos (JG)

  • Colonel
  • ****
  • Posts: 358
  • Squaddie cautiously peering through the breach
    • View Profile
Re: ModPack Installer
« Reply #16 on: May 01, 2015, 04:58:47 am »
just FYI, mod formats will be getting a makeover soon.  the new package format includes a metadata file that will contain a url.  we can use that to drive autoupdate.

That would be great!  Did you have a rough ETA of the makeover? 

Should I continue down my path of making an installer/updater?

 I've gotten most of the web scraping done as the site stands now(in all it's flaws), and I starting to work on determining the mods and versions installed on a local system.

Offline myk002

  • Colonel
  • ****
  • Posts: 227
    • View Profile
Re: ModPack Installer
« Reply #17 on: May 01, 2015, 06:23:07 am »
well, I'm not sure.  adding autoupdate functionality to openxcom itself would require pulling in a bunch of libraries, which I'm not sure the devs want to do.  the url metadata attached to the mod would certainly take the guesswork out of your code, though, so perhaps we can just work together a bit to make sure the info you need is available to your tool.

Offline hellrazor

  • Commander
  • *****
  • Posts: 2027
  • Deep Ruleset Digger & Bughunter
    • View Profile
    • Github Account
Re: ModPack Installer
« Reply #18 on: May 01, 2015, 12:47:02 pm »
well, I'm not sure.  adding autoupdate functionality to openxcom itself would require pulling in a bunch of libraries, which I'm not sure the devs want to do.  the url metadata attached to the mod would certainly take the guesswork out of your code, though, so perhaps we can just work together a bit to make sure the info you need is available to your tool.

How is the metadata structured? Maybe as a XML file or something similar?

Which reminds me of something. Loading a Ruleset from a folder at the moment gives you kinda a problem if you receive YAML errors. Because it doesn't tell you the file the error was found in but only the overall line number (treating the directory as a single large file i guess) not so good for debugging mods.
« Last Edit: May 01, 2015, 12:52:09 pm by hellrazor »

Offline DoxaLogos (JG)

  • Colonel
  • ****
  • Posts: 358
  • Squaddie cautiously peering through the breach
    • View Profile
Re: ModPack Installer
« Reply #19 on: May 01, 2015, 03:21:10 pm »
well, I'm not sure.  adding autoupdate functionality to openxcom itself would require pulling in a bunch of libraries, which I'm not sure the devs want to do.  the url metadata attached to the mod would certainly take the guesswork out of your code, though, so perhaps we can just work together a bit to make sure the info you need is available to your tool.

Okay, I'll just plug away on what I have and change it when the new mod format appears.   

I understand about the libraries things. Even though it's easier to pull in 3rd party libraries in python, I've had to make some decisions on what I depend upon for ease of installation (some 3rd party libs require a compiler installed for python).  I bet OXC would need things like lxml, xsl, and a slew of networking libs to support the feature.

Offline Yankes

  • Global Moderator
  • Commander
  • *****
  • Posts: 3350
    • View Profile
Re: ModPack Installer
« Reply #20 on: May 01, 2015, 03:38:59 pm »
I think it should be separate app. This would be required by Windows because its tricky to replace exe that is now running.

Offline jackstraw2323

  • Colonel
  • ****
  • Posts: 206
    • View Profile
Re: ModPack Installer
« Reply #21 on: May 01, 2015, 04:12:28 pm »
What if open com could check the rule file for an alternate base directory for terrain, maps, etc. that way those resources could live under the /Resources/modpack/ directory. That would make more sense as you would then have 2 folders to install. One under rules and one under resources, and hopefully you wouldn't have any collision between mods provided they were namespaced correctly.

Offline DoxaLogos (JG)

  • Colonel
  • ****
  • Posts: 358
  • Squaddie cautiously peering through the breach
    • View Profile
Re: ModPack Installer
« Reply #22 on: May 01, 2015, 05:12:08 pm »
I think it should be separate app. This would be required by Windows because its tricky to replace exe that is now running.

Most excellent point indeed!

Offline DoxaLogos (JG)

  • Colonel
  • ****
  • Posts: 358
  • Squaddie cautiously peering through the breach
    • View Profile
Re: ModPack Installer
« Reply #23 on: May 01, 2015, 05:13:33 pm »
What if open com could check the rule file for an alternate base directory for terrain, maps, etc. that way those resources could live under the /Resources/modpack/ directory. That would make more sense as you would then have 2 folders to install. One under rules and one under resources, and hopefully you wouldn't have any collision between mods provided they were namespaced correctly.

Well, from what I'm learning, it looks like for the future, they have this worked out for when TFTD mod comes out.

Offline myk002

  • Colonel
  • ****
  • Posts: 227
    • View Profile
Re: ModPack Installer
« Reply #24 on: May 01, 2015, 05:28:43 pm »
How is the metadata structured? Maybe as a XML file or something similar?

Which reminds me of something. Loading a Ruleset from a folder at the moment gives you kinda a problem if you receive YAML errors. Because it doesn't tell you the file the error was found in but only the overall line number (treating the directory as a single large file i guess) not so good for debugging mods.
The metadata will be structured as a (very simple) yaml file.  Separate from the ruleset(s).  For loading errors, the log will show which file it was attempting to load when the yaml error happened.  It doesn't appear in the popup message (that would actually take a bit of work to make happen), but it will be in the log.