• Dear Cerberus X User!

    As we prepare to transition the forum ownership from Mike to Phil (TripleHead GmbH), we need your explicit consent to transfer your user data in accordance with our amended Terms and Rules in order to be compliant with data protection laws.

    Important: If you accept the amended Terms and Rules, you agree to the transfer of your user data to the future forum owner!

    Please read the new Terms and Rules below, check the box to agree, and click "Accept" to continue enjoying your Cerberus X Forum experience. The deadline for consent is April 5, 2024.

    Do not accept the amended Terms and Rules if you do not wish your personal data to be transferred to the future forum owner!

    Accepting ensures:

    - Continued access to your account with a short break for the actual transfer.

    - Retention of your data under the same terms.

    Without consent:

    - You don't have further access to your forum user account.

    - Your account and personal data will be deleted after April 5, 2024.

    - Public posts remain, but usernames indicating real identity will be anonymized. If you disagree with a fictitious name you have the option to contact us so we can find a name that is acceptable to you.

    We hope to keep you in our community and see you on the forum soon!

    All the best

    Your Cerberus X Team

DevLog App or plugin for easy deployment

Phil7

Moderator
CX Code Contributor
3rd Party Tool Dev
Joined
Jun 26, 2017
Messages
886
I am trying to create an App that makes it more convenient to create the finished package of your game.
One click deployment is my goal.
For now I am targeting html, Windows desktop (and later Android)

1. !Only test in a copy of your project folder!
3. Start the app with "python .\CX-Deploy.py"
4. Select the main .cxs file of your CerberusX project.


Binary Download:
Dropbox Link to a single executable of CXDeploy for Windows. Should work without any python or Qt on your system.

Source Download:
You need the following on your system to test with the source code:
- Python 3 with PyQt5
-Cerberus X installation with release builds html and glfw of your app
-Innosetup for Unicode (preprocessor enabled during installation)

The zip below is the python project file
 

Attachments

  • CX-Deploy2019-08-01.zip
    31.7 KB · Views: 188
Last edited:
As I plan to edit the first post to provide the latest news and downloads, this post is the start of the discussion.
For now I am hacking a tool (Named CXDeploy) together that does the job somehow in Purebasic, because this is the easiest way for me to provide an app with Gui.
Later I can switch to Qt with python to make the source useful for everyone. I think it could be helpful to have a working tool, to get a feeling of how it could look and feel, and how things could work together with the new Ide.

Maybe I have a download to test at the end of the week.
For now it does the following:
1. You put the exe in your CX project folder.
2. It creates one Folder called !CXDeploy with necessary files and a folder for the resulting products

Html Target:
1. It copies the build into the products folder (default dir)
2. Adds a html file with a maximized game canvas and no debugger textfield
2. Changes the favicon to a selected one.
3. Changes the title tag of the html file.

Windows Glfw Target through minGW:
1. Changes the Icon of the exe through the process of : windres(icon.ico +icon.rc)= icon.res / change makefile / rebuild
2. Runs a InnoSetup script (needs a unicode + preprocessor install of innoSetup) to make a install package exe . You can change a lot of variables for that in the GUI (as seen in the screenshot).

Problems:
To rebuild the desktop target I need the path of trans somehow and don't want the user to insert it.
Same with windres. How do I make sure that I can access windres64.exe through the windres command.
Maybe there should be an easy way for the tool to get access to config.winnt.txt of the cerberus installation?!


1550088054810.png
 
YES, finally a user dev log! THANK YOU!!!

Looking good so far. Regarding the path to CX, well that is one the user has to select right now. One wish... let it be able to start wih the path to cx as a parameter. ;) Any I think it is no problem that the user would have to select the installation of CX. Do it once at the very first start and store it. Regarding copying the tool in every project folder.... why don't you just store it where you want to? Then let the user select the project and store a config file in it which holds all the info needed to work on the distribution.
 
Regarding copying the tool in every project folder.... why don't you just store it where you want to?
My mindset creating this tool is all about less user decisions, better tool and more likely people will test it. In the long run it should be either a part of the Ide as a plugin or a standalone tool that is installed the conventional way (to programs ...)

let it be able to start wih the path to cx as a parameter
I guess you are thinking about a way to start it from the Ide. Same Idea here. In this case it seems there are three parameters needed to avoid further mandatory user inputs:
1. dir of CX installation (For running trans and finding windres by the settings in config.winnt.txt )
2. dir of the project
3. Build folder (at least I don't know, how I get the .build folder name from within the CX installation)

let the user select the project and store a config file in it which holds all the info needed to work on the distribution.
Either that or one config file with all the settings for each project (needs more checking for consistency, I guess).
I am not keen on polluting the project folder with files and folders like JungleIDE used to do.
 
BTW Just another stupid idea that I came across making that tool.
It could be useful to have trans output a config-summary file that can be used by the deploy tool or for debugging settings. At the moment all the config settings are spread across all the default target config.cxs files -> overwritten by all the project config.cxs files -> overwritten by the in-source settings -> overwritten by the command line option settings for trans, right? :rolleyes:
 
Almost correct, the last one is settings to build a project, where the modules are located, etc.

You tool is about packaging, right? Not building!? Then you won't need to worry about the config files at all.
 
Almost correct ;)
I don't know if all config.cxs settings can also be set in trans command line, but the docs say:
Arguments starting with + can be used to specify app config settings. Such arguments must be of the form +key=value. Note that boolean settings made this way should be specified using 1 or 0, not True or False, eg: '+GLFW_AUTO_SUSPEND_ENABLED=1'.

tool is about packaging, right?
same thing here ;)
I try to fill the gap that is present in CX between the things you can accomplish with config settings etc. like #GLFW_WINDOW_TITLE to the point where it feels like a finished product with an icon and a installer package.

you won't need to worry about the config files
For changing the icon you need to be aware, if your build is 32 or 64 bit to choose the correct windres options and to rebuild afterwards.
And for convenience reasons it could be handy to set default titles etc. for the package or other targets if the user already specified one for glfw.

It was just an idea, I got around that by letting the user choose the glfwBuildfolder and therefor decide if 32 or 64 bit was correct.
Maybe it could be worth some thoughts, if trans + builder should take care of some additional work to avoid rebuilding from outside.
 
Short info about the progress. I implemented the idea of parameter support when starting from command line with cerberus installation dir and project dir.
Two things to do till I can upload something to test:
- saving and loading of preferences in a file using xml. It is the most convenient way to do in PB at the moment.
- getting windres.exe from the mingGW installation folder. For now you would have to set the bin dir as a PATH variable.
 
- getting windres.exe from the mingGW installation folder. For now you would have to set the bin dir as a PATH variable.
Please keep in mind that a user can also use MSVC and so not need to have mingw installed.
 
@MikeHart You're right. I haven't inserted icons in MSVC before, so I don't know how. Any resources?
I guess it is a different process than in MinGW.
I also guess that there are some changes if dawlanes overhaul is getting into the official release.
For now I am all about having a usable solution for the stuff I am using and getting some experience doing that.
... Maybe just getting myself started and away from waiting for a perfect solution or for someone else doing it.
 
Suggession: to rebuilding from outside by using Resource Hacker . You can also drive it via the command line.
The drawback: User need to download RH in separate install
 
@magic Thanks, I will consider this.

Version 2019-02-17 is out :) See first post.
I now fetch the minGW dir and therefor the location of windres.exe from config.winnt.txt, so no need for PATH settings.
@MikeHart For now minGW is mandatory, but it is a start. ...And the Tool in every project folder for testing
For commandline option you can just write the project dir. and -cxdir=... for the cerberus installation dir.
Example: CXDeploy.exe -cxdir=C:\cerberus C:\programs\myGame
 
Last edited:
Version 2019-03-05
- Updated the Innosetup script to enable writing to the cerberusstate file.
- some minor changes to the GUI and bug fixes
 
I rewrote the whole thing using python and Qt. While learning python and Qt from scratch...
So this is my first app in python ever. :oops:

commandline option changed to bare minimum, but you can get help by using -h option thanks to argparse library.

Ftp upload is implemented, but only gives feedback in the python console.

Current functionality:
- html target: setting of favicon, title, maximized window, filename, folder name)
- glfw Windows target: Creating an InnoSetup Installer package with the possibility of setting some values like app name, publisher etc.
- autofill functionality for easy to go default values
- save and load your settings in a json file inside your project folder

661
 
Last edited:
I just made a pyinstaller folder with a windows exe for easy testing.
You can find it in the first post.
Man, those files are getting big for such a small tool.
 
I guess you are right. Maybe I can strip off some things, but during developement, the last thing I want to think about, is to import every little piece by hand and discuss, if I really need it or not. I often ran into errors because I forgot this or that in the import section.
 
Yeah, I hear ya. That is the beauty of Python. And its ugly face at the same time.
 
New Version 2019-08-01 with just a few bug fixes.

Had a fight with pyinstaller to make it compile to a single executable with my seperate files bundled.
 
Back
Top Bottom