-
Notifications
You must be signed in to change notification settings - Fork 0
2.4 ‐ Updating Ruby Codes in the Compiled Executable
Technically, the Ruby codes are not compiled; it's just the Ruby interpreter gets compiled, and it executes the Ruby codes which are stored as data resources in the packed executable. Therefore, if we make changes to the Ruby codes, there is no need to re-compile the whole thing, but rather, we can just update the data resources in the executable according to the new Ruby codes.
Moreover, the tools introduced in this article can also change the version info, icon, and manifest in the executable file.
-
You must have compiled
tswKai3.exe
bycompile/rakefile.rb
.Or instead, you can download my precompiled
tswKai3.exe
, place it under tswKai3's main folder. -
You must have installed
Exerb
like discussed here in the first point.Or instead, have the
exerb-mingw
package available under thevendor
subfolder like discussed here in the last point.
Navigate to the compile
folder, and double click on updateExe.rb
. Then you are done!
You may want to take a look at the contents of updateExe.rb
and make some changes to the ICOFILE
, MANFILE
, and VER
constants according to your needs, so that you can also update the version info, icon, and manifest, respectively, in the executable file.
The compression of the Ruby codes into an archive is implemented in mkexa.rb
. This can be potentially used in your own projects if you want to convert your Ruby codes into a sharable executable and publish it.
Copyright © 2020-2024 丁香园主人 (Z.Sun) tswKai3 Project