I say perfect, only you forgot the Bundle_Make method, ops sorry function!
Roberto
Roberto,
what I think is still missing in thinBundle module is the following:
- possibility to add files, so something like "Bundle_AddFile"
- possibility to reset, so something like "Bundle_Reset".
This functionality is needed in case with one script user wants to create more bundled exe. So after "Bundle_Builder" and testing all is ok, a "Bundle_Reset" will let user to restart a new bundle.
What do you think?
Ciao and thanks for the great job have already done.
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
I say perfect, only you forgot the Bundle_Make method, ops sorry function!
Roberto
http://www.thinbasic.com
Perfect!
So, Bundle_Make will create the exe and Bundle_Reset will let you restart a new bundling process.
Thanks
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
Added to thinbasic_bundle.dll the following functions:
- Bundle_Reset
- Bundle_Make
- Bundle_AddFile
So you should be able to run this script
[code=thinbasic]uses "BUNDLE"
dim i as long
' Put some garbage
Bundle_SetBundleName("Bundle")
Bundle_SetScriptName("c:\thinbasic\samplescripts\bundle\Bundle.tbasic")
Bundle_SetScriptParameters("Hello")
Bundle_SetCreationFolder("c:\Bundle")
Bundle_SetExtractionFolder("c:\temp")
Bundle_SetFlagCompressAllFiles(%TRUE)
Bundle_SetFlagAskBeforeExtract(%TRUE)
Bundle_SetFlagDeleteAfterRun(%TRUE)
Bundle_SetFlagObfuscateMainScript(%TRUE)
' Clean it up (code above is needed only for show the Bundle_Reset() use)
if Bundle_Reset() then msgbox 0, "Data Reset"
' Now set the correct data for the Smallest's bundle that is without additional modules
Bundle_SetBundleName("Smallest")
Bundle_SetScriptName("c:\thinbasic\samplescripts\bundle\Smallest.tbasic")
Bundle_SetScriptParameters("Hello")
Bundle_SetCreationFolder("c:\thinbasic\samplescripts\bundle\")
Bundle_SetExtractionFolder("c:\temp")
Bundle_SetFlagCompressAllFiles(%TRUE)
Bundle_SetFlagAskBeforeExtract(%TRUE)
Bundle_SetFlagDeleteAfterRun(%TRUE)
Bundle_SetFlagObfuscateMainScript(%TRUE)
' Make the bundle
DisplayResult(Bundle_Make())
' Now same of previous but also add thinAir.ini file
Bundle_SetBundleName("Smallest2")
Bundle_SetScriptName("c:\thinbasic\samplescripts\bundle\Smallest.tbasic")
Bundle_SetScriptParameters("Hello")
Bundle_SetCreationFolder("c:\thinbasic\samplescripts\bundle\")
Bundle_SetExtractionFolder("c:\temp")
Bundle_SetFlagCompressAllFiles(%TRUE)
Bundle_SetFlagAskBeforeExtract(%TRUE)
Bundle_SetFlagDeleteAfterRun(%TRUE)
Bundle_SetFlagObfuscateMainScript(%TRUE)
Bundle_AddFile("c:\thinbasic\thinair\thinair.ini")
' Invoke the Bundle_Builder
DisplayResult(Bundle_Builder())
SUB DisplayResult(i as long)
If i = 0 then
msgbox 0, "Bundled Executable Created."
else
if i = %BUNDLE_BUILDER_CANCELLED then
msgbox 0, "Bundle creation cancelled by user."
else
msgbox 0, "Error occured while creating bundle."
end if
end if
end sub[/code]
I'm still woarking to add the Bundle_AddFolder function and fixing some minor lacks.
Cheers,
Roberto
http://www.thinbasic.com
That looks very good! thank you for this
I'm finishing to fix a bugs that oblidge me to change some internal thinCore structures.
After that I will release all those important features Roberto added to thinBundle.
Thanks Roberto.
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
Added Bundle_AddFolder() function and set the readonly and system flag to the directories created with addfolder.
Ciao,
Roberto
http://www.thinbasic.com
This is great, thanks guys. Will make it very nice to share our work with others not into programming, but like using apps.
Acer Notebook: Win 10 Home 64 Bit, Core i7-4702MQ @ 2.2Ghz, 12 GB RAM, nVidia GTX 760M and Intel HD 4600
Raspberry Pi 3: Raspbian OS use for Home Samba Server and Test HTTP Server
Bookmarks