Main Menu

Self-Extracting Programs?

Started by Flexico, Mar 18, 2025, 11:30 PM

Previous topic - Next topic

Flexico

I have around 8 interacting programs that I want to share, but Pastebinning them separately is annoying and fiddly. I've been thinking about writing a script that can combine them into one file, then extract itself on the target system. The idea I have currently is to just generate a whole load of "file.writeLine(" commands, but I feel like there has GOT to be a more efficient/reliable way. Any ideas?

Purrcival

Quote from: Flexico on Mar 18, 2025, 11:30 PMI have around 8 interacting programs that I want to share, but Pastebinning them separately is annoying and fiddly. I've been thinking about writing a script that can combine them into one file, then extract itself on the target system. The idea I have currently is to just generate a whole load of "file.writeLine(" commands, but I feel like there has GOT to be a more efficient/reliable way. Any ideas?

You can try reading each file, and putting it all into one single table using textutils and putting it into a file. You can create a custom installer that can install which one. Or you can use another method, which I highly recommend, is to store it on Github and then use URLs to grab each one that is fully updated at your disposal. If you look at the wget command's code on grabbing HTTP, this should be no biggie.