• We have updated our Community Code of Conduct. Please read through the new rules for the forum that are an integral part of Paradox Interactive’s User Agreement.

Ventessel

Second Lieutenant
8 Badges
Aug 31, 2014
193
114
  • Crusader Kings II
  • Darkest Hour
  • Europa Universalis IV
  • Hearts of Iron III
  • Pillars of Eternity
  • Stellaris
  • Hearts of Iron IV Sign-up
  • Hearts of Iron IV: Cadet
Question for any veteran modders out there. I created a github repository for my Ground Assault mod, and wondered if anyone had any better ideas for updating the mod than manually copying from the repo into the local mods folder, launching the game, and updating the mod under the tab in the launcher?

I feel as though there ought to be some way to link the github repo to the main mod folder via Steam, but I don't know where I would begin to look.
 
  • 2
Reactions:

Shaggo

New Horizons Team
23 Badges
May 19, 2016
375
266
  • Darkest Hour
  • Stellaris: Federations
  • PDXCON 2018 "The Emperor"
  • Stellaris: Synthetic Dawn
  • Stellaris - Path to Destruction bundle
  • Europa Universalis IV
  • Stellaris: Leviathans Story Pack
  • Stellaris
  • Pillars of Eternity
  • Europa Universalis III: Collection
  • Heir to the Throne
  • Magicka 2
  • Semper Fi
  • Majesty 2 Collection
  • Cities in Motion 2
  • Hearts of Iron III Collection
  • Hearts of Iron III: Their Finest Hour
  • Hearts of Iron III
  • For the Motherland
  • Divine Wind
  • Europa Universalis III
  • Crusader Kings II: The Old Gods
  • Crusader Kings II
you could use your mod directory as github directory. this would allow you to test everything you change instantly. the huge downside of this would be that the game generates "caching" files, everytime you want to publish your work you would need to clean up these files, first. Other than that, I always copy the content of my git into my mod folder when i have something new. this takes longer than directly starting from github directory but i dont have to clean it every time i release a new version. It also gets complicated with the "caching" files when there are more contributors working on the project. hope that helps and maybe someone else has a better solution
 
  • 1
Reactions:

Idhrendur

Keeper of the Converters
107 Badges
Feb 27, 2009
11.430
3.124
  • Hearts of Iron IV: No Step Back
  • Hearts of Iron IV: By Blood Alone
  • Crusader Kings II
  • Victoria 3 Sign Up
  • Stellaris: Nemesis
  • Sengoku
  • Pillars of Eternity
  • Tyranny: Archon Edition
  • Europa Universalis IV
  • March of the Eagles
  • Victoria 2
  • 500k Club
  • Stellaris: Galaxy Edition
  • Hearts of Iron IV: Colonel
  • Shadowrun Returns
  • Imperator: Rome Deluxe Edition
  • Crusader Kings III: Royal Edition
  • Commander: Conquest of the Americas
  • Darkest Hour
Ok, that was kind of what I wondered. I guess I'll stick to the 'ol copy/paste method for now.

Maybe I'll write a utility that removes the cache files and cleans up for me, since I'm learning C# anyways this summer.

I would highly recommend writing scripts/batch files that can handle the copying and cleaning up for you. It's always best to automate such things.

If you're on Windows and not familiar with writing batch files, you can use the following files from my own projects as examples:
 
  • 2
Reactions:

Ventessel

Second Lieutenant
8 Badges
Aug 31, 2014
193
114
  • Crusader Kings II
  • Darkest Hour
  • Europa Universalis IV
  • Hearts of Iron III
  • Pillars of Eternity
  • Stellaris
  • Hearts of Iron IV Sign-up
  • Hearts of Iron IV: Cadet
I would highly recommend writing scripts/batch files that can handle the copying and cleaning up for you. It's always best to automate such things.

If you're on Windows and not familiar with writing batch files, you can use the following files from my own projects as examples:
Aha, step one of writing a program - find out if someone else has already done it!
 

Moopli

Second Lieutenant
52 Badges
Aug 10, 2014
100
47
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Mare Nostrum
  • Stellaris - Path to Destruction bundle
  • Europa Universalis IV: Res Publica
  • Europa Universalis IV: Call to arms event
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Art of War
  • Crusader Kings II: Sword of Islam
  • Crusader Kings II
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: The Republic
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: Charlemagne
  • Stellaris: Nemesis
  • Europa Universalis IV: Mandate of Heaven
  • Stellaris: Synthetic Dawn
  • Hearts of Iron IV: No Step Back
  • Europa Universalis IV: Rule Britannia
  • Cities: Skylines - Parklife
  • Europa Universalis IV: Dharma
  • Cities: Skylines Industries
  • Stellaris: Megacorp
  • Crusader Kings II: Holy Fury
  • Imperator: Rome
  • Hearts of Iron IV: Expansion Pass
  • Cities: Skylines - Campus
  • Stellaris: Ancient Relics
  • Stellaris: Lithoids
  • Hearts of Iron IV: La Resistance
  • Stellaris: Federations
  • Crusader Kings III
  • Crusader Kings II: Monks and Mystics
  • Europa Universalis IV
  • Cities: Skylines
  • Europa Universalis IV: El Dorado
  • Crusader Kings II: Way of Life
  • Pillars of Eternity
  • Europa Universalis IV: Common Sense
  • Crusader Kings II: Horse Lords
  • Cities: Skylines - After Dark
  • Europa Universalis IV: Cossacks
  • Crusader Kings II: Conclave
  • Stellaris
  • Hearts of Iron IV: Cadet
  • Crusader Kings II: Reapers Due
  • Europa Universalis IV: Rights of Man
  • Tyranny: Archon Edition
  • Cities: Skylines - Mass Transit
Another way to deal with cache files is to gitignore them. The gitignore gets committed to the repo, so all contributors will be able to avoid committing cache files. That way, you can still keep your repo inside the mod directory.
 
  • 1
Reactions:

Ventessel

Second Lieutenant
8 Badges
Aug 31, 2014
193
114
  • Crusader Kings II
  • Darkest Hour
  • Europa Universalis IV
  • Hearts of Iron III
  • Pillars of Eternity
  • Stellaris
  • Hearts of Iron IV Sign-up
  • Hearts of Iron IV: Cadet
I'm looking at the file structure in the Documents/Paradox Interactive/Stellaris/mod folder, but I don't see any caching files being generated in there. Is there somewhere else you would recommend storing the mod, or could I keep the git repo there?
 

Moopli

Second Lieutenant
52 Badges
Aug 10, 2014
100
47
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Mare Nostrum
  • Stellaris - Path to Destruction bundle
  • Europa Universalis IV: Res Publica
  • Europa Universalis IV: Call to arms event
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Art of War
  • Crusader Kings II: Sword of Islam
  • Crusader Kings II
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: The Republic
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: Charlemagne
  • Stellaris: Nemesis
  • Europa Universalis IV: Mandate of Heaven
  • Stellaris: Synthetic Dawn
  • Hearts of Iron IV: No Step Back
  • Europa Universalis IV: Rule Britannia
  • Cities: Skylines - Parklife
  • Europa Universalis IV: Dharma
  • Cities: Skylines Industries
  • Stellaris: Megacorp
  • Crusader Kings II: Holy Fury
  • Imperator: Rome
  • Hearts of Iron IV: Expansion Pass
  • Cities: Skylines - Campus
  • Stellaris: Ancient Relics
  • Stellaris: Lithoids
  • Hearts of Iron IV: La Resistance
  • Stellaris: Federations
  • Crusader Kings III
  • Crusader Kings II: Monks and Mystics
  • Europa Universalis IV
  • Cities: Skylines
  • Europa Universalis IV: El Dorado
  • Crusader Kings II: Way of Life
  • Pillars of Eternity
  • Europa Universalis IV: Common Sense
  • Crusader Kings II: Horse Lords
  • Cities: Skylines - After Dark
  • Europa Universalis IV: Cossacks
  • Crusader Kings II: Conclave
  • Stellaris
  • Hearts of Iron IV: Cadet
  • Crusader Kings II: Reapers Due
  • Europa Universalis IV: Rights of Man
  • Tyranny: Archon Edition
  • Cities: Skylines - Mass Transit
I just tested using a symlink to let you keep the mod outside the mod folder, meaning you could keep your repo separate. So something like this:

Code:
$ ll .local/share/Paradox\ Interactive/Stellaris/mod/
...
lrwxrwxrwx 1 me me   18 Jul 18 17:23 test-mod -> ~/somewhere/else/test-mod//
-rw------- 1 me me   86 Jul 18 17:16 test-mod.mod
$ ls ~/somewhere/else/test-mod/
your-code-here

You could even have the link point to a folder within your git repo, in which case your repo can have other folders of, say, helper files, notes, and other things you wouldn't want Stellaris to attempt to load as mod files:

Code:
$ tree -a ~/somewhere/mod-repo/
mod-repo/
├── .git
│  └── ...
├── .gitignore
├── notes
│  └── notes-and-stuff.txt
└── test-mod
  └── mod-stuff-here
$ ll .local/share/Paradox\ Interactive/Stellaris/mod/
...
lrwxrwxrwx 1 me me   18 Jul 18 17:23 test-mod -> ~/somewhere/mod-repo/test-mod//
-rw------- 1 me me   86 Jul 18 17:16 test-mod.mod

This, I'd say, is the cleanest option. One thing I didn't check, though, is whether uploading to steam workshop will upload the symlink or follow the symlink. But it seems like Stellaris itself follows the symlinks, so hopefully the upload would too.
 
  • 1
  • 1
Reactions:

SeeGee

Corporal
53 Badges
May 12, 2016
44
8
  • Dungeonland
  • Stellaris: Synthetic Dawn
  • The Showdown Effect
  • Crusader Kings II
  • Europa Universalis IV: Res Publica
  • Magicka
  • Leviathan: Warships
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV
  • Europa Universalis III
  • Europa Universalis IV: Call to arms event
  • Stellaris: Necroids
  • Cities: Skylines - Green Cities
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • Cities: Skylines - Parklife Pre-Order
  • Cities: Skylines - Parklife
  • Stellaris: Distant Stars
  • Shadowrun Returns
  • Shadowrun: Dragonfall
  • Cities: Skylines Industries
  • BATTLETECH: Flashpoint
  • Stellaris: Megacorp
  • Imperator: Rome Deluxe Edition
  • Imperator: Rome
  • Prison Architect
  • Stellaris: Ancient Relics
  • Age of Wonders: Planetfall
  • Age of Wonders: Planetfall Deluxe edition
  • Stellaris: Lithoids
  • Stellaris: Galaxy Edition
  • Teleglitch: Die More Edition
  • Warlock: Master of the Arcane
  • War of the Roses
  • Cities: Skylines
  • Cities: Skylines Deluxe Edition
  • Pillars of Eternity
  • Cities: Skylines - After Dark
  • Cities: Skylines - Snowfall
  • Stellaris
  • Surviving Mars
  • Stellaris: Galaxy Edition
  • Hearts of Iron IV: Cadet
  • Tyranny: Archon Edition
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Cities: Skylines - Natural Disasters
  • Stellaris - Path to Destruction bundle
  • Cities: Skylines - Mass Transit
This is helpful info! I use winmerge to point out differences between the Github repository and my current files. What caching files do you speak of, and how would I exclude them from the repo?
 

Moopli

Second Lieutenant
52 Badges
Aug 10, 2014
100
47
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Mare Nostrum
  • Stellaris - Path to Destruction bundle
  • Europa Universalis IV: Res Publica
  • Europa Universalis IV: Call to arms event
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Art of War
  • Crusader Kings II: Sword of Islam
  • Crusader Kings II
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: The Republic
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: Charlemagne
  • Stellaris: Nemesis
  • Europa Universalis IV: Mandate of Heaven
  • Stellaris: Synthetic Dawn
  • Hearts of Iron IV: No Step Back
  • Europa Universalis IV: Rule Britannia
  • Cities: Skylines - Parklife
  • Europa Universalis IV: Dharma
  • Cities: Skylines Industries
  • Stellaris: Megacorp
  • Crusader Kings II: Holy Fury
  • Imperator: Rome
  • Hearts of Iron IV: Expansion Pass
  • Cities: Skylines - Campus
  • Stellaris: Ancient Relics
  • Stellaris: Lithoids
  • Hearts of Iron IV: La Resistance
  • Stellaris: Federations
  • Crusader Kings III
  • Crusader Kings II: Monks and Mystics
  • Europa Universalis IV
  • Cities: Skylines
  • Europa Universalis IV: El Dorado
  • Crusader Kings II: Way of Life
  • Pillars of Eternity
  • Europa Universalis IV: Common Sense
  • Crusader Kings II: Horse Lords
  • Cities: Skylines - After Dark
  • Europa Universalis IV: Cossacks
  • Crusader Kings II: Conclave
  • Stellaris
  • Hearts of Iron IV: Cadet
  • Crusader Kings II: Reapers Due
  • Europa Universalis IV: Rights of Man
  • Tyranny: Archon Edition
  • Cities: Skylines - Mass Transit
I don't know what caching files Stellaris might generate (as I've barely looked into it), but you can simply keep an eye out as you work and if you see any cache files appearing in the output of git status, you would edit your .gitignore to make git ignore them.

Later, when you want to publish but don't want any cache files, or when you have made and committed big changes (and maybe invalidated cache files which you want to delete just to be sure), you can remove all the (cache) files that you've ignored as above (and even (cache) files that you didn't ignore) by running git clean -fxdn :/ to see what will be deleted (in case you forgot to commit some work which you of course do not want to lose forever, or in case you realize that you were keeping files in your repo that you were never planning on committing, you have a chance to move them somewhere else or just commit them already like a normal person) and then git clean -fxd :/ once you're sure.
 
  • 1
Reactions: