Reintegrated Thor

This commit is contained in:
Lutz
2023-12-05 12:54:31 +01:00
parent 0363d644af
commit 17c23c2733
16 changed files with 559 additions and 37 deletions

View File

@@ -23,7 +23,7 @@ Start reading our code and you'll get the hang of it. We optimize for readabilit
- Keywords: Mixed case
- Symbols: First occurence
- Indentation Tabs, 1
- Indent anything then comments
- Indent anything then Comments
- Please do not run BeautifyX with mDots insertion against the code.
- We ALWAYS put spaces after list items and method parameters (`[1, 2, 3]`, not `[1,2,3]`), around operators (`x = 1`, not `x=1`).
- This is open source software. Consider the people who will read your code, and make it look nice for them. It's sort of like driving a car: Perhaps you love doing donuts when you're alone, but with passengers the goal is to make the ride as smooth as possible.
@@ -37,7 +37,7 @@ Stuff is a bit scattered, so this is where to look up.
- See this [guide](https://www.dataschool.io/how-to-contribute-on-github/) for setting up and using a fork
2. clone your fork to your computer
- Existing fork
1. If allready forked, gather the recent state of the master to your fork (for example: "Sync fork" in github on top of your repository)
1. If already forked, gather the recent state of the master to your fork (for example: "Sync fork" in github on top of your repository)
2. Pull the recent state,
3. or get most recent version otherwise.
**Note: You must run FoxBin2Prg against itself to create the binaries and exes:**
@@ -57,7 +57,7 @@ DO ReCreate_FoxBin2Prg.prg
**Do not** alter the **1.21** part. This is written to the text files.
Alteration might force that the files must be newly commited, what is not everybodies taste.
The value might be altered, if the file structure of the text files is changed.
6. Add a meaningfull description of the change in the changes list on top of _FoxBin2Prg.prg_.
6. Add a meaningful description of the change in the changes list on top of _FoxBin2Prg.prg_.
The most recent entries for changes in the middle of this section around _* </HISTORIAL DE CAMBIOS Y NOTAS IMPORTANTES>_,
The most recent bugs are listed above _* </TESTEO Y REPORTE DE BUGS (AGRADECIMIENTOS)>_
7. Alter version in _README.md_
@@ -67,33 +67,33 @@ DO ReCreate_FoxBin2Prg.prg
- _C_FOXBIN2PRG_SYNTAX_INFO_EXAMPLE_LOC_tab_cfg:_ for settings per table
10. If a change to the parameters is made, change _C_FOXBIN2PRG_SYNTAX_INFO_EXAMPLE_LOC_ properties.
11. For changed functionality, add descriptive text on the appropriate _.md_ file in _docs_ folder.
13. Please alter the footer of \*.md files touched to recent date.
14. Alter the version number of the EXE to the version used above.
15. Create the text representation of the binary sources running like
12. Please alter the footer of \*.md files touched to recent date.
13. Alter the version number for the EXE to the version used above.
14. Create the text representation of the binary sources running like
```
CD "path_to_FoxBin2Prg"
*This uses a special configuration
DO Create_FoxBin2Prg.prg
```
**Note: Do not run FoxBin2Prg.prg directly.**
16. **The following steps are not neccesary, if you use *VPXDeployment* to create a new version that is applicable for Thor use.**
17. Compile to EXE **in VFP9 SP2**
18. Change Thor ([see below](#thor-conventions))
19. commit
20. push to your fork
21. Create a pull request
15. **The following steps are not neccesary, if you use *VPXDeployment* to create a new version that is applicable for Thor use.**
16. Compile to EXE **in VFP9 SP2**
17. Change Thor ([see below](#thor-conventions))
18. commit
19. push to your fork
20. Create a pull request
## Thor conventions
This project is part of [VFPX](https://vfpx.github.io/) and published via [Thor](https://github.com/VFPX/Thor).
Some steps must be done to create the information for Thor
### Using VFPXDeployment
The standard procedure to create the Thor files is runing VFPXDeployment via Thor.
1. If you add or remove files to FoxBin2Prg, that you need in the release:
<comment>1. If you add or remove files to FoxBin2Prg, that you need in the release:
- alter *BuildProcess/installedfiles.txt*, see [here](https://github.com/VFPX/VFPXDeployment/blob/main/docs/Documentation.md#installedfilestxt)
- open the *Helper/Clean_ThorFolder.prg* file
- navigate to *Get_CompareFiles procedure*
- alter the TEXT .. ENDTEXT section to remove all files deleted and add new files, check the block for examples.
- There is a programm *Helper/GetRevisions.prg* to create the list, but this need to run VFPXDeployment one time to create the INSTALLEDFILES directory before.
- There is a programm *Helper/GetRevisions.prg* to create the list, but this need to run VFPXDeployment one time to create the INSTALLEDFILES directory before.</comment>
2. Run VFPXDeployment. It will set version number to EXE, compile, set several documentation and create the files for Thor.
3. commit
4. push to your fork
@@ -105,7 +105,7 @@ There are some considerations to make to add a new version to Thor.
Please check [Supporting Thor Updater](https://vfpx.github.io/thorupdate/)
In special:
- Update _Project.txt_, in special the version number
- update the *Helper/Clean_ThorFolder.prg* file, see above
<comment>- update the *Helper/Clean_ThorFolder.prg* file, see above
- add files to _FoxBin2Prg.zip_, namely
- FoxBin2Prg.prg,
- FoxBin2Prg.exe,
@@ -113,9 +113,10 @@ In special:
- Clean_ThorFolder.prg
- Update the version number in _FoxBin2PrgVersion.txt_
- Update the changelog in _FoxBin2PrgVersion.txt_
- The use of CreateThorUpdate.ps1 is not longer recommended.
- The use of CreateThorUpdate.ps1 is not longer recommended.</comment>
- Right-click CreateThorUpdate.ps1 in the ThorUpdater folder and choose *Run with PowerShell*.
Thanks
----
Last changed: _2023/11/26_ ![Picture](../docs/pictures/vfpxpoweredby_alternative.gif)
Last changed: _2023/12/05_ ![Picture](../docs/pictures/vfpxpoweredby_alternative.gif)

8
.gitignore vendored
View File

@@ -48,6 +48,7 @@
!data/*.jpg
!/FileName_Caps.EXE
!/Fb2P_Diff.EXE
!/"CLEAR ALL.exe"
#gitlab
!*.md
@@ -82,3 +83,10 @@ bin2txt.*
#re-include
#!foxbin2prg_keywords.*
#Thor special
!/BuildProcess/*.prg
!/BuildProcess/*.txt
!/BuildProcess/*.md
!/BuildProcess/*.gitignore
!/ThorUpdater/*.*

View File

@@ -0,0 +1,2 @@
#List of additional files that will be substituded when running VFPXDeployment for FoxBin2PRG
docs\ChangeLog.md

View File

@@ -0,0 +1,160 @@
@@@ Edit this template if necessary. Note the use of placeholders such as
{APPNAME} and {APPID}; they are substituted with the correct values when
the deployment process is run, so no need to edit those. Also, this file is
textmerged so some text may not appear in the generated {APPID}Version.txt.
Also, any text between @@@ and \\\ is removed.
\\\lparameters toUpdateObject
* Set the properties of the passed updater object.@@@ You likely won't need to
* edit this code. One possible change is versioning: if you want to use the
* Julian date as a minor version number, edit the AvailableVersion setting to:
*
* .AvailableVersion = '{APPNAME}-{VERSION}.{JULIAN}-update-{VERSIONDATE}'
*
* or possibly:
*
* .AvailableVersion = '{APPNAME}-{VERSION}-{JULIAN}-{VERSIONDATE}'\\\
with toUpdateObject
.VersionNumber = '{VERSION} - {VERSIONDATE}'
.AvailableVersion = '{APPNAME}-{VERSION}-update-{VERSIONDATE}'
.Notes = GetNotes()
.RegisterWithThor = GetRegisterWithThor()
endwith
return toUpdateObject
*!* procedure GetRegisterWithThor
*!* local lcCommand
*!* text to lcCommand noshow
*!* lcBase = EXECSCRIPT(_SCREEN.cThorDispatcher, 'Thor_Proc_GetFoxBin2PrgFolder')
*!* IF FILE(m.lcBase+"clean_copied_memo.prg") THEN
*!* *remove old crap
*!* DO m.lcBase+"clean_thorfolder.prg" WITH lcBase
*!* ENDIF &&FILE(m.lcBase+"clean_copied_memo.prg")
*!*
*!* DELETE FILE (m.lcBase+"clean_thorfolder.*")
*!*
*!* endtext
*!*
*!* return lcCommand
*!* endproc &&GetRegisterWithThor
* Get the notes for the project.@@@ Edit this code as necessary. If you specify
* the name of a change log file as the ChangeLog setting in ProjectSettings.txt,
* the contents of that file are substituted for the CHANGELOG placeholder so
* there's no need to edit this.\\\
procedure GetNotes
local lcNotes
text to lcNotes noshow
A 2-way conversor for Visual FoxPro 9 binary files intended to be used with SCM tools (Full or only Diff and Merge operations) or just for backup
Supported formats are: PJX, PJM, SCX, VCX, FRX, LBX, MNX, DBC, DBF, FKY, MEM
To fix a bug, this version changes the text file header. It is suggested to create all text files and commit in one step.
Developed by Fernando D. Bozzo - GitHub: https://github.com/fdbozzo/foxbin2prg
{CHANGELOG}
endtext
return lcNotes
@@@* Register the tool with Thor. This template code assumes the tool is an APP
* file named {AppID}.app, where AppID is the AppID setting in ProjectSettings.txt.
* If that isn't the case, edit the Code property as necessary.
\\\* Register the tool with Thor. Note: Thor replaces ##InstallFolder## with the
* installation path for the tool when this code is executed.
<<iif('{COMPONENT}' = 'No', '', '@@@')>>
procedure GetRegisterWithThor
local lcCommand
text to lcCommand noshow
* "{APPNAME}" is a tool created by VFPX Deployment:
* Create the tool under Thor Tools.
loThorInfo = Execscript (_Screen.cThorDispatcher, 'Thor Register=')
with loThorInfo
* Required properties.
.PRGName = 'Thor_Tool_{APPID}'
.FolderName = '##InstallFolder##'
.Prompt = '{APPNAME}'
* Optional properties.
.Description = '{APPNAME}'
* These are used to group and sort tools when they are displayed in menus or
* the Thor form.
.Category = '{CATEGORY}'
.CanRunAtStartUp = .F.
* This is the code to execute when the tool is selected.
.Code = "do ('##InstallFolder##{APPID}.app')"
* Register the tool with Thor.
llRegister = .Register()
endwith
endtext
return lcCommand
endproc &&GetRegisterWithThor
<<iif('{COMPONENT}' = 'No', '', '\\\')>><<iif('{COMPONENT}' = 'No', '@@@', '')>>
* "{APPNAME}" is a Component. No procedure GetRegisterWithThor created by VFPX Deployment
<<iif('{COMPONENT}' = 'No', '\\\', '')>>
@@@* Register the tool with Thor. This template code assumes the tool is an APP
* file named {AppID}.app, where AppID is the AppID setting in ProjectSettings.txt.
* If that isn't the case, edit the Code property as necessary.
\\\* Register the tool with Thor. Note: Thor replaces ##InstallFolder## with the
* installation path for the tool when this code is executed.
procedure GetRegisterWithThor
local lcCommand
text to lcCommand noshow
<<iif('{COMPONENT}' = 'No', '', '@@@')>>
* "{APPNAME}" is a tool created by VFPX Deployment:
* Create the tool under Thor Tools.
loThorInfo = Execscript (_Screen.cThorDispatcher, 'Thor Register=')
with loThorInfo
* Required properties.
.PRGName = 'Thor_Tool_{APPID}'
.FolderName = '##InstallFolder##'
.Prompt = '{APPNAME}'
* Optional properties.
.Description = '{APPNAME}'
* These are used to group and sort tools when they are displayed in menus or
* the Thor form.
.Category = '{CATEGORY}'
.CanRunAtStartUp = .F.
* This is the code to execute when the tool is selected.
.Code = "do ('##InstallFolder##{APPID}.app')"
* Register the tool with Thor.
llRegister = .Register()
endwith
<<iif('{COMPONENT}' = 'No', '', '\\\')>>
<<iif('{COMPONENT}' = 'No', '@@@', '')>>
* "{APPNAME}" is a Component. No code created by VFPX Deployment
<<iif('{COMPONENT}' = 'No', '\\\', '')>>
endtext
return lcCommand
*created by VFPX Deployment, <<DATETIME()>>

View File

@@ -0,0 +1,69 @@
#Folder
#.git/
#.github/
#.gitignore
#BuildProcess/
#CONFIG/
#Documentacion/
#FileName_Caps/
#INSTALLEDFILES/
#TESTS/
#ThorUpdater/
#WinMergePortable/
#data/
#docs/
#tool/
#xThorUpdater/
#to ignore
#.gitattributes
#VFP9RENU.dll*
#vfp9r.dll*
#filetypes.conf
#ignore.conf
#to move
#FoxBin2PRGVersionFile.txt
#----------------------
#Fb2P_Diff
Fb2P_Diff\Fb2P_Diff.exe||\Fb2P_Diff.exe
#FileName_Caps
\FileName_Caps.exe
\FileName_Caps.cfg
#fb2p_diff.exe
\fb2p_diff.exe
#CLEAR ALL.exe
\CLEAR ALL.exe
#Foxbin2prg
#default
\*.vbs
#config
\FOXBIN2PRG.CFG.TXT
\FOXBIN2PRG.DBF.CFG.TXT
Config\config.fpw
#prg
\foxbin2prg.exe
\foxbin2prg.ico
\foxbin2prg.jpg
#we ignore the pjx for Thor, if somebody needs it, he can clone the repo
#\foxbin2prg.pjt
#\foxbin2prg.pjx
\foxbin2prg.prg
\foxbin2prg_keywords.cdx
\foxbin2prg_keywords.dbf
\props_*.txt
\LICENSE
########
\readme.md
WinMergePortable\

View File

@@ -0,0 +1,73 @@
*ProjectSettings.txt to create Thor deployment
*See https://github.com/VFPX/VFPXDeployment/blob/main/docs/Documentation.md for help.
*Paths relative are based on git toplevel folder
*The name to show in Thor. Mandatory
AppName = FoxBin2PRG
*The ID for Thor operation. Mandatory
AppID = FoxBin2PRG
*Version number
*A string, or enter pjx to use _VFP.ActiveProject.VersionNumber or, if defined PJXFile
*SF 20230806: <20>berdenken, wie das hier und pjx und prg zusammengeht
Version = 1.0
*Component of Thor or Tool. Use No for Tool.
Component = Yes
*Remote repository on a git server. There are two ways for the remote repository.
*- the builder assumes https://github.com/VFPX/{AppId}
*- or enter the URL here (uncomment to use):
Repository = https://github.com/fdbozzo/foxbin2prg
*The changelog file. Might be merged into the {AppID}Version.txt
*The file installed as template (uncomment to use):
*ChangeLog = docs\ChangeLog.md
*Create VFPX community folders and files. Will not overwrite existing files.
*Include_VFPX = Yes
*Do not create Thor folders and files (uncomment to use):
*Include_Thor = No
* The remaining lines are options to are not mandatory uncomment the options to use *
*"Yes" to auto run FoxBin2prg (Default), else "No" to not run.
RunBin2Prg = No
*"Yes" to auto run git (Default), else "No" to not run.
RunGit = No
*The release date formatted as YYYY-MM-DD; if omitted, today
*VersionDate = 1973-09-11
*Yes (Default) to prompt for Version if not specified
*Prompt = Yes
*The category to use when adding to the Thor menu. If omitted, "Applications". only when Component is No.
*Category = {My}
*The relative path to the PJX file to compile. Omit this if that isn't required.
PJXFile = FoxBin2Prg.pjx
*The path to the APP or EXE to build from the project, with the extension
AppFile = FoxBin2Prg.exe
*Builds the project specified in PJXFile without the RECOMPILE clause.
*Recompile = No
*A comma-separated list of relative paths to which FoxBin2PRG is to be applied.
*Bin2PRGFolder = {MySource1,MySource1}
*A different name for the staging folder.
*InstalledFilesFolder = {MyInstallFolder}
*Remove all files from InstalledFiles folder if InstalledFiles.txt is given
*Clear_InstalledFiles = No
*add a gitignore to InstalledFiles directory to not add this directory to git repository
gitIgnore_InstalledFiles = Yes
*A different name for version file used to publish info on the remote server.
*A help with old projects using a different name for the version file
*VersionFile_Remote = {AppID}Version.txt

BIN
CLEAR ALL.exe Normal file

Binary file not shown.

View File

@@ -4,10 +4,8 @@
## Lutz Scheffler
This is the perpetuation of [Fernando D. Bozzo](https://github.com/fdbozzo) foxbin2prg.
It's the main tool with some bugs fixes and some new functions.
I now maintain only [this project](https://github.com/lscheffler/foxbin2prg), https://github.com/fdbozzo/foxbin2prg is no longer in sync.
The spanish documentation is not longer maintained - it would fade.
The spanish documentation is not longer maintained.
Remind yourself to compile the exe first.
## Regenerate after download / clone / pull
@@ -32,6 +30,11 @@ If you like to see Fernandos blog, or value his work:
Thank you for your support!
----
## Important Note
To fix a bug, this version changes the text file header.
It is suggested to create all text files and commit in one step.
----
## Contribution
See [contribution](./.github/CONTRIBUTING.md)
@@ -131,7 +134,6 @@ I will try to fix bugs if my obligations let me do it.
This work is licensed under the Creative Commons Attribution 4.0 International License.
To view a copy of this license, visit http://creativecommons.org/licenses/by/4.0/.
---
---
## Changes
See [Changes](./docs/ChangeLog.md)
@@ -155,17 +157,21 @@ See [issue #93](https://github.com/fdbozzo/foxbin2prg/issues/93).
For usage see [documentation](./docs/FoxBin2Prg.md)
----
![VFPX logo](https://vfpx.github.io/images/vfpxbanner_small.gif)
This project is part of [VFPX](https://vfpx.github.io/).
## Helping with FoxBin2PRG
See [contribution](./.github/CONTRIBUTING.md)
---
## Note
The spanish documentation is not longer maintained - it would fade.
For fast access a quick run is [introduced](#use-foxbin2prg), more [complex](./docs/FoxBin2Prg_Run.md#usage-1), and a large [documentation](./docs/FoxBin2Prg.md) exists too.
If you do not access FoxBin2Prg via [Thor](https://github.com/VFPX/Thor) remind yourself to compile the exe first.
If you like to see Fernando's blog, or value his work:
- Blog: http://fdbozzo.blogspot.com.es/
- [![DONATE!](http://www.pngall.com/wp-content/uploads/2016/05/PayPal-Donate-Button-PNG-File-180x100.png)](https://www.paypal.com/cgi-bin/webscr?cmd=_donations&amp;business=fdbozzo%40gmail%2ecom&amp;lc=ES&amp;item_name=FoxBin2Prg&amp;item_number=FoxBin2Prg&amp;currency_code=USD&amp;bn=PP%2dDonationsBF%3abtn_donateCC_LG%2egif%3aNonHosted)
----
Last changed: _<!--CVERSIONDATE-->2023-08-09<!--/CVERSIONDATE-->_ ![Picture](./docs/pictures/vfpxpoweredby_alternative.gif)
<comment>
Rework Thor_Update_FoxBin2Prg.prg, GetNotes() useless or to much.
location der Dateien
- remotes version file (version auf github) lcAppID + 'Version.txt'
- locales version file (version im localen thor) lcAppID + 'VersionFile.txt'
das muss nicht in der Wurzel liegen
</comment>
Last changed: _2023/12/05_ ![Picture](./docs/pictures/vfpxpoweredby_alternative.gif)

BIN
ThorUpdater/FoxBin2PRG.zip Normal file

Binary file not shown.

View File

@@ -0,0 +1,66 @@
lparameters toUpdateObject
* Set the properties of the passed updater object.
with toUpdateObject
.VersionNumber = '1.21.01 - 20231205'
.AvailableVersion = 'FoxBin2PRG-1.21.01-update-20231205'
.Notes = GetNotes()
.RegisterWithThor = GetRegisterWithThor()
endwith
return toUpdateObject
*!* procedure GetRegisterWithThor
*!* local lcCommand
*!* text to lcCommand noshow
*!* lcBase = EXECSCRIPT(_SCREEN.cThorDispatcher, 'Thor_Proc_GetFoxBin2PrgFolder')
*!* IF FILE(m.lcBase+"clean_copied_memo.prg") THEN
*!* *remove old crap
*!* DO m.lcBase+"clean_thorfolder.prg" WITH lcBase
*!* ENDIF &&FILE(m.lcBase+"clean_copied_memo.prg")
*!*
*!* DELETE FILE (m.lcBase+"clean_thorfolder.*")
*!*
*!* endtext
*!*
*!* return lcCommand
*!* endproc &&GetRegisterWithThor
* Get the notes for the project.
procedure GetNotes
local lcNotes
text to lcNotes noshow
A 2-way conversor for Visual FoxPro 9 binary files intended to be used with SCM tools (Full or only Diff and Merge operations) or just for backup
Supported formats are: PJX, PJM, SCX, VCX, FRX, LBX, MNX, DBC, DBF, FKY, MEM
To fix a bug, this version changes the text file header. It is suggested to create all text files and commit in one step.
Developed by Fernando D. Bozzo - GitHub: https://github.com/fdbozzo/foxbin2prg
endtext
return lcNotes
* Register the tool with Thor. Note: Thor replaces ##InstallFolder## with the
* installation path for the tool when this code is executed.
* "FoxBin2PRG" is a Component. No procedure GetRegisterWithThor created by VFPX Deployment
* Register the tool with Thor. Note: Thor replaces ##InstallFolder## with the
* installation path for the tool when this code is executed.
procedure GetRegisterWithThor
local lcCommand
text to lcCommand noshow
* "FoxBin2PRG" is a Component. No code created by VFPX Deployment
endtext
return lcCommand
*created by VFPX Deployment, 05.12.2023 16:03:02

View File

@@ -0,0 +1,137 @@
'---------------------------------------------------------------------------------------------------
' VFP9_FoxBin2Prg.vbs (VFPx: https://vfpx.codeplex.com/wikipage?title=FoxBin2Prg)
' 08/10/2014 - Fernando D. Bozzo (fdbozzo@gmail.com - Blog: http://fdbozzo.blogspot.com.es/)
'
'---------------------------------------------------------------------------------------------------
' ENGLISH:
' - Copy this file in the same directory of FoxBin2prg and create a shortcut
' on user's "SendTo" folder
' - Now you can select files or directories, right click and "SendTo" FoxBin2prg for batch conversion
'
' ESPA<50>OL:
' - Copie este archivo en el mismo directorio que FoxBin2prg y cree un acceso directo
' en la carpeta "SendTo" del usuario
' - Ahora puede seleccionar archivos o directorios, pulsar click derecho y "Enviar a" FoxBin2prg para conversiones batch
'---------------------------------------------------------------------------------------------------
Dim WSHShell, FileSystemObject, cEndOfProcessMsg, cWithErrorsMsg, cConvCancelByUserMsg, nProcessedFilesCount
Dim nExitCode, cEXETool, cEXETool2, nDebug
Set wshShell = CreateObject( "WScript.Shell" )
Set FileSystemObject = WScript.CreateObject("Scripting.FileSystemObject")
Set oVFP9 = CreateObject("VisualFoxPro.Application.9")
nExitCode = 0
'---------------------------------------------------------------------------------------------------
'Cumulative Flags:
' 0=OFF
' 1=Create FoxBin2prg LOG
' 2=Only show script calls (for testing without executing)
' 4=Don't show FoxBin2prg error modal messages
' 8=Show end of process message
' 16=Empty timestamps
nDebug = 1+0+4+8
'---------------------------------------------------------------------------------------------------
If WScript.Arguments.Count = 0 Then
'SIN PAR<41>METROS
nExitCode = 1
cErrMsg = "nDebug = " & nDebug
If GetBit(nDebug, 1) Then
cErrMsg = cErrMsg & Chr(13) & "Bit 0 ON: (1) Create FoxBin2prg LOG"
End If
If GetBit(nDebug, 2) Then
cErrMsg = cErrMsg & Chr(13) & "Bit 1 ON: (2) Only show script calls"
End If
If GetBit(nDebug, 3) Then
cErrMsg = cErrMsg & Chr(13) & "Bit 2 ON: (4) Don't show FoxBin2prg error modal messages"
End If
If GetBit(nDebug, 4) Then
cErrMsg = cErrMsg & Chr(13) & "Bit 3 ON: (8) Show End of Process message"
End If
If GetBit(nDebug, 5) Then
cErrMsg = cErrMsg & Chr(13) & "Bit 4 ON: (16) Empty timestamps"
End If
MsgBox cErrMsg, 64, "No parameters - Debug Status"
ElseIf WScript.Arguments.Count > 1 Then
MsgBox cErrMsg, 64, "You can select just ONE file with this script!"
Else
'CON PAR<41>METROS
cEXETool = Replace(WScript.ScriptFullName, WScript.ScriptName, "foxbin2prg.exe")
nFile_Count = 0
oVFP9.DoCmd( "SET PROCEDURE TO '" & cEXETool & "'" )
oVFP9.DoCmd( "PUBLIC oFoxBin2prg" )
oVFP9.DoCmd( "oFoxBin2prg = CREATEOBJECT('c_foxbin2prg')" )
oVFP9.DoCmd( "oFoxBin2prg.loadProgressbarForm()" )
oVFP9.DoCmd( "oFoxBin2prg.o_frm_avance.Caption = '" & FileSystemObject.GetBaseName( WScript.ScriptName ) & " - ' + oFoxBin2Prg.c_loc_process_progress" )
cFlagGenerateLog = "'0'"
cFlagDontShowErrMsg = "'0'"
cFlagShowCall = "'0'"
cFlagRecompile = "'1'"
If GetBit(nDebug, 1) Then
cFlagGenerateLog = "'1'"
End If
If GetBit(nDebug, 2) Then
cFlagJustShowCall = "1"
End If
If GetBit(nDebug, 3) Then
cFlagDontShowErrMsg = "'1'"
End If
If GetBit(nDebug, 5) Then
cNoTimestamps = "'1'"
End If
cFlagRecompile = "'" & FileSystemObject.GetParentFolderName( WScript.Arguments(0) ) & "'"
oVFP9.DoCmd( "oFoxBin2prg.o_frm_avance.Caption = '" & FileSystemObject.GetBaseName( WScript.ScriptName ) & " - ' + oFoxBin2Prg.c_loc_process_progress + ' (Press Esc to Cancel)'" )
If nDebug = 0 Or nDebug = 2 Then
cCMD = "oFoxBin2prg.execute( '" & WScript.Arguments(0) & "' )"
Else
cCMD = "oFoxBin2prg.execute( '" & WScript.Arguments(0) & "','INTERACTIVE','0','0'," _
& cFlagDontShowErrMsg & "," & cFlagGenerateLog & ",'1','','',.F.,''," _
& cFlagRecompile & "," & cNoTimestamps & " )"
End If
If cFlagJustShowCall = "1" Then
MsgBox cCMD, 64, "PARAMETERS"
Else
oVFP9.DoCmd( cCMD )
nExitCode = oVFP9.Eval("_SCREEN.ExitCode")
End If
If GetBit(nDebug, 4) Then
cEndOfProcessMsg = oVFP9.Eval("_SCREEN.o_FoxBin2Prg_Lang.C_END_OF_PROCESS_LOC")
cWithErrorsMsg = oVFP9.Eval("_SCREEN.o_FoxBin2Prg_Lang.C_WITH_ERRORS_LOC")
cConvCancelByUserMsg = oVFP9.Eval("_SCREEN.o_FoxBin2Prg_Lang.C_CONVERSION_CANCELLED_BY_USER_LOC")
nProcessedFilesCount = oVFP9.Eval("oFoxBin2prg.n_ProcessedFilesCount")
If nExitCode = 1799 Then
MsgBox cConvCancelByUserMsg & "! [p:" & nProcessedFilesCount & "]", 48+4096, WScript.ScriptName & " (" & oVFP9.Eval("oFoxBin2prg.c_FB2PRG_EXE_Version") & ")"
oVFP9.DoCmd("oFoxBin2prg.writeErrorLog_Flush()")
cErrFile = oVFP9.Eval("oFoxBin2prg.c_ErrorLogFile")
WSHShell.run cErrFile,3
ElseIf oVFP9.Eval("oFoxBin2prg.l_Error") Then
MsgBox cEndOfProcessMsg & "! (" & cWithErrorsMsg & ") [p:" & nProcessedFilesCount & "]", 48+4096, WScript.ScriptName & " (" & oVFP9.Eval("oFoxBin2prg.c_FB2PRG_EXE_Version") & ")"
oVFP9.DoCmd("oFoxBin2prg.writeErrorLog_Flush()")
cErrFile = oVFP9.Eval("oFoxBin2prg.c_ErrorLogFile")
WSHShell.run cErrFile,3
Else
MsgBox cEndOfProcessMsg & "! [p:" & nProcessedFilesCount & "]", 64+4096, WScript.ScriptName & " (" & oVFP9.Eval("oFoxBin2prg.c_FB2PRG_EXE_Version") & ")"
End If
End If
oVFP9.DoCmd( "oFoxBin2prg = NULL" )
oVFP9.DoCmd( "CLEAR ALL" )
Set oVFP9 = Nothing
End If
WScript.Quit nExitCode
Function GetBit(lngValue, BitNum)
Dim BitMask
If BitNum < 32 Then BitMask = 2 ^ (BitNum - 1) Else BitMask = "&H80000000"
GetBit = CBool(lngValue AND BitMask)
End Function

View File

@@ -27,6 +27,7 @@ _**Note:** you can click on the version number for downloading this version from
| Rel.Date | Developer | Version | Details |
| - | - | - | - |
| 2023/11/19 | LScheffler | [v1.21.01](https://github.com/lscheffler/foxbin2prg/releases/tag/v1.21.01) | **Enhancement**: Source files not longer included in Thor. The file you will found are old and will be removed with subsequent installs. (LScheffler) |
| 2023/11/19 | LScheffler | [v1.21.01](https://github.com/lscheffler/foxbin2prg/releases/tag/v1.21.01) | **Bug Fix**: Problems regenerating databases with splited contents due to the removed Spanish characters in comment. (LScheffler) |
| 2023/10/20 | LScheffler | [v1.21.00](https://github.com/lscheffler/foxbin2prg/releases/tag/v1.21.00) | **Bug Fix**: Problems with Spanish characters in comment. (ccantrell72) |
| 2023/09/06 | LScheffler | [v1.20.07](https://github.com/lscheffler/foxbin2prg/releases/tag/v1.20.07) | **Enhancement**: Option to block processing of directories. If file ".FoxBin2Prg_Ignore" is existing, this directories and all subdirectries will be ignored. (Mainly set up to ignore local GoFish settings) (LScheffler) |

View File

@@ -24,7 +24,7 @@ Original repository at https://github.com/fdbozzo/foxbin2prg.
Or install via [Thor](https://github.com/VFPX/Thor/blob/master/Docs/Thor_install.md), this keeps you on the latest version.
## Download
Regenerate after download / clone / pull from https://github.com/lscheffler/foxbin2prg.
Regenerate after download / clone / pull from https://github.com/fdbozzo/foxbin2prg.
**Note: You you must run FoxBin2Prg against itself to create the binaries and exes.**
Run:
```
@@ -101,4 +101,4 @@ FoxBin2Prg can be used in tree ways:
This project is part of [VFPX](https://vfpx.github.io/).
----
Last changed: _2023/11/26_ ![Picture](./pictures/vfpxpoweredby_alternative.gif)
Last changed: _2023/12/05_ ![Picture](./pictures/vfpxpoweredby_alternative.gif)

View File

@@ -101,7 +101,6 @@ The _BIN2PRG, PRG2BIN, INTERACTIVE, SHOWMSG_ cTypes might be mixed freely like:
Return value is 0=OK, 1=Error.
----
Last changed: _2023/09/01_
![VFPX logo](https://vfpx.github.io/images/vfpxbanner_small.gif)
This project is part of [VFPX](https://vfpx.github.io/).

View File

@@ -38,7 +38,7 @@ CTRL+C, CTRL+V on Explorer might save the day. ;)
## Requirements
### #1
A copy of FoxBin2Prg.
Or install via [Thor](https://github.com/VFPX/Thor/blob/master/Docs/Thor_install.md), this keeps you on the latest version.
Or Install via [Thor](https://github.com/VFPX/Thor/blob/master/Docs/Thor_install.md), this keeps you on the latest version.
### #2
It might be a good idea to have a copy of git.

View File

@@ -11,4 +11,4 @@ and my spanish is good enough to order a beer.
- [FoxBin2Prg](./FoxBin2Prg.md)
----
Last changed: _2023/08/26_
Last changed: _2021/08/30_ ![Picture](./pictures/vfpxpoweredby_alternative.gif)