Ok, it seems it creates a copy of the source. So my request is invalid. You can delete this topic.
Hi Roberto,
I think it is dangerous to have the obfuscate option checked by default in the thinbundle dialog, or? I can easily loose the source if I don't save after it, I guess.
If that is true, then I would suggest to have it unchecked by default.
Michael
Ok, it seems it creates a copy of the source. So my request is invalid. You can delete this topic.
Mike,
your indication is interesting because it can really be dangerous that flag. When? When you do not obfuscate!
Why? thinBundle create and exe that is like a black box filled with all the needed files for the engine to work plus the script to be executed.
If the script to be executed is bundled in obfuscated way, its name is different from the original one but if not obfuscated, its name will be the same.
Now, if you create the bundled exe in the same directory of the original script and you do not flag obfuscate flag, when bundled exe is executed, bundled script overwrite your master script and delete it after execution (if flag "Delete after run" was ON). In this case you will loose you script!
So, better and safer solution is to leave Obfuscate flag always on
We have to better think about that.
An idea can be to generate a random name for the bundled script source even if obfuscated. File extension will remain the same. This will make quite impossible to overwrite original scripts even if there in clear or obfuscated form.
Thanks for pointing it.
Eros
www.thinbasic.com | www.thinbasic.com/community/ | help.thinbasic.com
Windows 10 Pro for Workstations 64bit - 32 GB - Intel(R) Xeon(R) W-10855M CPU @ 2.80GHz - NVIDIA Quadro RTX 3000
Ouch, indeed, that is bad. Creating a radom name doens't help much with include files, or? I would say use a random named folder where the bundled exe extracts the sources to. Or like you said, have obfuscating allways on and not be optional.
I think for the moment obfuscate flag always on is the best.
Also for another important reason: obfuscated scripts have all included files already exploded inside the main script so even if your script uses many #INCLUDE directives, the obfuscated version is the sum of all included sources and there will be no dependancies.
What do you think Roberto?
www.thinbasic.com | www.thinbasic.com/community/ | help.thinbasic.com
Windows 10 Pro for Workstations 64bit - 32 GB - Intel(R) Xeon(R) W-10855M CPU @ 2.80GHz - NVIDIA Quadro RTX 3000
First of all my idea is add a new Bundle option tab where user can specify the four bundles' flag, BUNDLE CREATION FOLDER and BUNDLE EXTRACTION FOLDER, so this can make more comfortable the bunde use since all of these settings are already configurable by thinBasic_Bundle.dll.
Then in addition I can do one of following things:
- Do not delete eventually existing main script but just rename it (MyExistingScript.tbasic -> MyExistingScript.tbasic.bak)
- Add a string or a counter to the main script name before bundled it (MyMainScript.tbasic -> MyMainScript_@_.tbasic)
Ciao,
Roberto
http://www.thinbasic.com
Sounds good to me.
Roberto,
adding more tabs in thinBundle is good. More oprions will come so having a tab control can simplify a lot. Thanks
Regarding script name, we have to think that original script is property of the programmer who made it so we have to do all we can in order to avoid to touch it in any way. I do not like programs of any type touching my personal files and I'm sure you think the same. Something more: we have to think about the possibility to have 2 bundled exe executed at the same time from the same directory. A not so far possibility.
Keeping that in mind and thinking that the name of the script when bundled is not important (because generally it will be hidden to user when executed) option number 2 is ok. I still prefer to generate a random unique name of the script before bundling it but adding a number is better than nothing.
Thanks a lot
Eros
www.thinbasic.com | www.thinbasic.com/community/ | help.thinbasic.com
Windows 10 Pro for Workstations 64bit - 32 GB - Intel(R) Xeon(R) W-10855M CPU @ 2.80GHz - NVIDIA Quadro RTX 3000
Eros,
you are right, better avoid to limitate multiple bundled executiones, so opaque unique name is generate for the script, I'm still working on bundle's option.
Ciao,
Roberto
http://www.thinbasic.com
Also fineshed to add bundle option tab in ThinAir, so you can choose your favourites default values for bundle window.
You'll find these update in the next ThinBASIC release.
Regards,
Roberto
http://www.thinbasic.com
Bookmarks