firebelley / godot-export

Automatically exports your Godot games.
MIT License
461 stars 53 forks source link

Add auxiliary files to release archive #44

Closed outfrost closed 2 years ago

outfrost commented 3 years ago

This is a (hopefully small) feature request.

I am packaging a Godot project, and would like to include extra files, namely README.md and LICENSE, in the archive.

Using this action, it's possible to do that in workflow artifacts (by simply running cp before actions/upload-artifact). However, it is not easy, or at least not obvious how to do it in releases that this action creates.

In my example use case, I would like to achieve

LinuxX11.zip
|- LICENSE
|- README.md
|- project.pck
|- project.x86

It would be lovely if godot-export had either an input to specify files to be added to the archive, or a plain shell hook to execute a user-provided script in between exporting and archiving.

firebelley commented 3 years ago

I like both of those ideas. The pre-archive hook would open up a ton of possibilities for further extensibility as well.

The tricky part is Mac builds are automatically exported as archived, so there needs to be additional logic to open the archive up, copy the files, then archive it again.

In the meantime, I believe you can accomplish what you want within Godot by utilizing the EditorExportPlugin API. See this comment https://github.com/godotengine/godot/issues/22950#issuecomment-429369247

This will allow you to copy files alongside your export during the Godot export process, which will work just fine with this action.

outfrost commented 3 years ago

Thanks a lot for pointing me to that script! I had searched through issues in godot but couldn't find that.

firebelley commented 2 years ago

This action has changed quite a bit with 4.0.0. I now believe it's possible to do a lot more with this action. Feel free to reopen if this is an issue that's still worth discussing!