Automating a packaging that replicates what UE4Editor Does

I’ve been trying to replicate the function that happens when you run the command in the screenshot:

312210-eg8eo5rxyaqfmlq.png

So far I’ve got: (GitBash running in Windows Terminal, don’t @ me) (paths edited for brevity)

/c/Program\ Files/Epic\ Games/UE_4.24/Engine/Build/BatchFiles/RunUAT.bat BuildCookRun -project=/c/Users/tingh/Controllers/Controllers.uproject -clientconfig=Development -platform=Win64 -cook -foreigndest=/c/Users/tingh/Controllers/Builds/ -package -build

Which runs, appears to be doing “the thing” but doesn’t update any binaries that I can find in my project structure. My suspicion is that it is putting the build output somewhere else; or nowhere (which I guess technically qualifies as somewhere.)

Ultimately I’m trying to put together a single shell script that packages an alpha build and uploads it through butler so I don’t have to menu-hunt anymore.

Thanks for any help.

Update:

Here’s the final bash script:

#!/bin/sh
 
# Build the package
/c/Program\ Files/Epic\ Games/UE_4.24/Engine/Build/BatchFiles/RunUAT.bat BuildCookRun -project=/c/Users/username/Controllers/Controllers.uproject -clientconfig=Development -platform=Win64 -cook -stage -pak -stagingdirectory=/c/Users/username/Controllers/Builds/ -package -build

# Push the build to itch.io
butler.exe push WindowsNoEditor/ username/controllers-prototypes:alpha

sleep 5

# Fetch the status of the package after a short break
butler status username/controllers-prototypes:alpha

It seems likely that there is a way to make it work with relative paths but that they just don’t work for some reason because of my environment (*nix shell inside of windows.) This does, however verbosely, package the project and upload to itch so that seems like a check in the win column for now.

Try adding these params: -stage -pak stagingdirectory=“PathWhereYouWantYourBuildSavedTo”

:chef’s kiss: