Short: Indent C-source in GoldEd4 Author: Thomas Aglassinger Uploader: Thomas Aglassinger Version: 1.1 Type: dev/c Kurz: C-Quellcode in GoldEd4 einruecken Requires: GoldEd 4.x, GNUindent TITLE ged4indent VERSION 1.1 AUTHOR Thomas Aglassinger DESCRIPTION Ged4indent is an ARexx-script which indents a C-source currently displayed by GoldEd using GNUindent. FEATURES None; simply does it's job. SPECIAL REQUIREMENTS o GoldEd, Version 4.x (aminet:text/edit/) o GNUindent (aminet:dev/c/) AVAILABILITY aminet:dev/c/ged4indent.lha PRICE Freeware DISTRIBUTABILITY This stuff is Public Domain. DISCLAIMER No responsibilities are taken for trashed sources, damaged Amigas or any other components or data involved while using ged4indent. CREDITS This script is based on material written by Michael Bauer. His scripts are available from `aminet:dev/c/GEDindent.lha', but does no longer work with GoldEd, release 4. As the original author did not update them for more than two years, and his email-address does not seem to be valid any more, someone else had to write this. INSTALLATION Copy the ARexx-script `ged4indent.ged' to `GoldEd:ARexx/', and build up a new menu entry for it, for example: COMMAND: GoldEd:Arexx/ged4indent.ged TYPE : Arexx OUTPUT : CON:0/2048/384/128/indent/AUTO/WAIT/CLOSE/SCREENGOLDED.1 Error messages will then appear on the screen of GoldEd. CONFIGURATION By default, `indent' will be invoked using options which will match the style GoldEd supports in it's initial configuration. If you do not like this style, you can set an environment variable named `ged4indent.prefs' with your preferred style, for example: setenv ged4indent.prefs "-bl -bli0 -i4 -sob -sc -npsl -npcs -lp" You can add a line like the above to your s:user-startup. Refer to the manual of indent for the meaning of these options. ERROR HANDLING In case of `indent' shows up any error messages, a window will open and display these messages. The source code in the current editor window remains untouched. The corrupt output file will remain as `t:ged4indent.XXXX' for further examination. However, it is recommended to run a compiler on the faulty source, as this will usually result in more detailed messages. You can do a delete t:ged4indent.#? from time to time to save some memory. (If `indent' did not return any errors, the temporary file is removed automatically.) PROBLEMS The version of `indent' included with the Geek Gadgets v1 always opens an output window on the screen, even if indent does not show any messages. I do not know why. Use the SAS-compiled port in aminet:dev/c. HISTORY v1.1, 11-Jun-1997 - added support for environment variable `ged4indent.prefs' - indented version is first created in a temporary file, and only read into editor again if no error occurred v1.0, 26-Jan-1997 - initial release