Build 20171225
ChangelogFixed:
- Fix FileBox to handle root directory path correctly.
- Encode command no longer duplicate entry under [EncodedFolders]
- Launcher.exe will alert user to update .Net Framework if 4.7.1 is not installed.
- Prevent crash in PluginEditButton.
Added
- ShellExecuteSlow, a variant of ShellExecute to run process in BelowNormal Priority.
- ShellExecute's Standard Output Redirect TextBox will be autoscrolled.
- ShellExecute's Standard Output Redirect can be hidden in Setting.
- Implemented EchoFile command.
- .db files are moved info database directory.
- Implemented System,SetLocal|EndLocal, and #r.
- Implemented System,Load.
- System,LoadAll as a new alias of System,RescanScripts.
- New setting to let user choose custom code editor.
- Display line number in error or warning log.
- Implemented INIReadSection.
1. Alert user to install .Net Framework 4.7.1Launcher.exe now depends on .Net Framework 4.6.2, and alert user to install .Net Framework 4.7.1 if not installed.
4.6.2 was chosen because it is the minimal version supports HiDPI natively.
- Speculations
Launcher.exe's target framework can be lowered more, minimum 4.0 (Windows 8 has this by default).
.Net Framework 4.0 is not installed in Windows 7 by default, but it cannot be trageted.
It is because starting from Windows 8, Microsoft ommited .Net Framework 3.5 in default install.
2. Display Line Number in Error LogsPEBakery will display line number along with code in error logs.
It will help troubleshooting bugs in .script files.
3. [New] System,SetLocal|EndLocal, #rI noticed Macro Library relies on section parameters rather than local variables.
I guessed it is because using local variable in macro call can affect other plugins.
Using section parameter as a free memory slot can also cause PackParam to malfunction, unable to count parameter number (#a).
To solve these problem, System,SetLocal and System,EndLocal is introduced from cmd syntax.
After calling System,SetLocal, all modification to local variables are isolated.
To end isolation call System,EndLocal. System,EndLocal will be called automatically when a section exits.
System,EndLocal will revert local variable state to before calling System,SetLocal.
Its logic is similar with how Windows isolate envrionment variable in batch file.
New token #r is introduced to be used as return value.
#r is not affected by SetLocal and EndLocal, and it does not affect parameter number counting in PackParam or #a.
Its value cannot be guaranteed to survive another macro/section call, so copy value into local variables to preserve.
(Think how EAX hold return value in x86 assembly language).
[Process]
Set,%B%,F
Run,%ScriptFile%,A
Echo,B = %B%
Echo,C = %C%
Echo,R = #r
[A]
System,SETLOCAL
Set,%B%,T
Set,%C%,T
Set,#r,T
System,ENDLOCAL
Result:
B = F
C = %C%
R = T
4. [New] System,LoadNew syntax to refresh/load plugin introduced.
System,Load,<FilePath>,[NOREC]
In FilePath, wildcard can be used. Unless NOREC flag is used, PEBakery will search for file recursively.
System,RescanScripts now have an alias, to match terminoloy with System,Load.
System,LoadAll
- Limitation
PEBakery cannot fully refresh current plugin.
System,Load,%ScriptFile%
Refreshed plugin is applied in next build run, not in current build run.
-> Using System,Load,%ScriptFile% in interface button is okay.
-> Using System,Load,%ScriptFile% in project building is not okay.
It is due to PEBakery's internal design, modifing architecture will require many changes.
Discussed in
this topic.
5. [New] INIReadSectionSee the manual in
GitHub.