Keep original container (file type) after converting

You don’t need to use customcommands for this one.

You can modify the profile to change the extension to your choice. I would recommend creating a new profile with a new name, you can copy all the settings from MP4 High Quality and then just add this line:

RenameExt=.mpg

Do remember, this doesn’t keep the original container but just the filename. The container is defined by your profile in this case it’s a MP4. It’s just changing the extension of the file, most players are smart enough to ignore the extension and look at the actual content to determine the container and the codecs within the container.

See this post:

and this for more advanced stuff: