Overview
The following information is intended for advanced users.
The Post-Make Command Section includes properties for specifying a command to run after the Make Site command completes successfully.
When GedSite executes the command, the working directory is set to the Output (-o) folder of the site.
The Post-Make Command section divides the command into two properties, File and Arguments. That is different from what users do when entering commands in a terminal window or when entering commands in the Run window opened via the MS Windows task bar. Internally, those tools work the same as GedSite. They have rules for deciding where in the text the File ends and the Arguments begin, and further rules for overcoming challenges where the parsing rules interfere with the goals of the end user. I chose to avoid those parsing rules and leave it up to the user to separate the File and Arguments.
Properties
File
Specify the filepath and filename of the file you want to execute in the File property.
If Use Shell Execute is checked, and if the File is in a folder included in the MS Windows %path%
environment variable, you can omit the path to the file.
If you specify a relative path, GedSite will resolve the path using the Output (-o) folder as the base path.
Arguments
Specify the arguments you want to pass to the command in the Arguments property.
Use Shell Execute
The Use Shell Execute property affects how MS Windows processes the command.
If Use Shell Execute is checked, and if the File is in a folder included in the MS Windows %path%
environment variable, you can omit the path to the file.
An explanation of how Use Shell Execute affects the command execution process is beyond the scope of this help page. You can read Raymond Chen's blog post about what ShellExecute does, but it's quite technical.
Seconds to Wait
The Seconds to Wait property sets the time, in seconds, that GedSite will wait for the command to finish running. While GedSite waits, the GedSite user interface will not respond to your input.
The default value for Seconds to Wait is zero, meaning that GedSite will not wait for the command to complete. This is usually the correct value; you do not want GedSite to be unresponsive and it should not matter to your external command whether GedSite is active or not except you should not use the Make Site command in GedSite if your external tool is still active and it accesses files in the Output (-o) folder.
If the command stops running before the timer elapses, GedSite will stop waiting and GedSite will resume responding to user input.
If the timer elapses and the command is still running, GedSite will stop waiting and GedSite will resume responding to user input.
Run Now...
Use the [Run Now...] button to execute the command.
If the Enabled checkbox is checked, GedSite will run the command automatically after the Make Site command completes. If you want to review the Make Site results before executing the command, leave the Enabled checkbox unchecked, and click the [Run Now...] button after your review.
Usage
Omit the quotes from the text values shown in these instructions.
To run an EXE program, set the File property to the name of the EXE, such as "notepad.exe". If the File is not in a folder included in the MS Windows %path%
environment variable, specify the full-path, such as "c:\Program Files\Some Program\SomeProgram.exe".
To run commands that you use in a command window, such as the "dir
" command:
- Set the File to "
cmd.exe
". - Set the Arguments to "
/C
" followed by the command. For the "dir
" command, for example, set Arguments to "/C dir
". - The cmd.exe window will close immediately after executing the command. To keep the window open so you can see the results, append "
& pause
" to the arguments.cmd.exe
will run thepause
command after thedir
command completes.pause
keeps the cmd.exe window open until you press a key.

If you have several commands to run, write a .bat (batch) file and set the File property to the path to the ".bat" file.