2009-05-25 10:30 UTC+0300 Alexander Kresin <alex at belacy.belgorod.su>
This commit is contained in:
@@ -17,6 +17,24 @@
|
||||
past entries belonging to these authors: Viktor Szakats.
|
||||
*/
|
||||
|
||||
2009-05-25 10:30 UTC+0300 Alexander Kresin <alex at belacy.belgorod.su>
|
||||
+ utils/hbformat
|
||||
+ utils/hbformat/hbformat.prg
|
||||
+ utils/hbformat/hbformat.ini
|
||||
+ utils/hbformat/Makefile
|
||||
+ Harbour source formatter utility has been added. The command line to call it:
|
||||
hbformat [-r] [options] [@config.ini] file[s]
|
||||
|
||||
-r option ( recursive ) forces formatting files in all nested directories.
|
||||
Default options ( their values you may find commented in a provided hbformat.ini )
|
||||
provides the style, accepted in Harbour prgs. The hbformat.ini must be in the same
|
||||
directory, where the hbformat.exe is. You can use additional ini file and point to
|
||||
it in a command line with the '@' before it. Options in a command line are the same,
|
||||
which are in ini file - for example, -lCase=no forces to not make case conversion.
|
||||
|
||||
* utils/Makefile
|
||||
* Makefile has been changed to build the hbformat
|
||||
|
||||
2009-05-24 13:44 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
|
||||
* INSTALL
|
||||
* Minor cleanups.
|
||||
|
||||
@@ -9,6 +9,7 @@ DIRS=\
|
||||
hbmk2 \
|
||||
hbi18n \
|
||||
hbtest \
|
||||
hbformat \
|
||||
$(HB_UTILS) \
|
||||
|
||||
# hbextern \
|
||||
|
||||
37
harbour/utils/hbformat/Makefile
Normal file
37
harbour/utils/hbformat/Makefile
Normal file
@@ -0,0 +1,37 @@
|
||||
#
|
||||
# $Id: Makefile 10963 2009-04-30 13:18:04Z druzus $
|
||||
#
|
||||
|
||||
ifeq ($(HB_MAIN),)
|
||||
HB_MAIN = std
|
||||
endif
|
||||
|
||||
HVMLIB = hbvm
|
||||
ifneq ($(HB_ARCHITECTURE),dos)
|
||||
ifneq ($(HB_MT),no)
|
||||
HVMLIB = hbvmmt
|
||||
endif
|
||||
endif
|
||||
|
||||
ROOT = ../../
|
||||
|
||||
PRG_SOURCES=\
|
||||
hbformat.prg \
|
||||
|
||||
PRG_MAIN=hbformat.prg
|
||||
|
||||
LIBS=\
|
||||
hbdebug \
|
||||
$(HVMLIB) \
|
||||
hbrtl \
|
||||
hblang \
|
||||
hbcpage \
|
||||
hbnulrdd \
|
||||
hbrtl \
|
||||
$(HVMLIB) \
|
||||
hbmacro \
|
||||
hbcommon \
|
||||
hbpp \
|
||||
hbcplr \
|
||||
|
||||
include $(TOP)$(ROOT)config/bin.cf
|
||||
90
harbour/utils/hbformat/hbformat.ini
Normal file
90
harbour/utils/hbformat/hbformat.ini
Normal file
@@ -0,0 +1,90 @@
|
||||
#
|
||||
# $Id: $
|
||||
#
|
||||
|
||||
# Eol: -1 - no change, 1 - DOS, 2 - UNIX
|
||||
#nEol = -1
|
||||
|
||||
# If yes, converts all tabs to spaces
|
||||
#lNoTabs = yes
|
||||
|
||||
# If yes, indent code
|
||||
#lIndent = yes
|
||||
|
||||
# If yes, make case conversion
|
||||
#lCase = yes
|
||||
|
||||
# If yes, reformat spaces
|
||||
#lSpaces = yes
|
||||
|
||||
# If yes, indent "Function", "Procedure", "Class", "Method"
|
||||
#lIndFunc = no
|
||||
|
||||
# If yes, indent "Local", "Private", etc. in a function beginning
|
||||
#lIndVar = yes
|
||||
|
||||
# If yes, indent directives
|
||||
#lIndDrt = no
|
||||
|
||||
# If yes, indent "Return"
|
||||
#lIndRet = yes
|
||||
|
||||
# Leftmost indent - amount of spaces
|
||||
#nIndLeft = 3
|
||||
|
||||
# indent - amount of spaces
|
||||
#nIndNext = 3
|
||||
|
||||
# Indent for continuation ( after ';' ) lines - amount of spaces
|
||||
#nIndCont = 3
|
||||
|
||||
# If yes, convert asterisk '*' to '//'
|
||||
#lCnvAst = yes
|
||||
|
||||
# If yes, convert '&&' to '//'
|
||||
#lCnvAmp = yes
|
||||
|
||||
# If yes, convert .NOT. TO !
|
||||
#lCnvNot = yes
|
||||
|
||||
# Case of commands ( -1 - no change, 1 - upper, 2 - lower, 3 - title )
|
||||
#nCaseCmd = 1
|
||||
|
||||
# Case of boolean operators ( -1 - no change, 1 - upper, 2 - lower, 3 - title )
|
||||
#nCaseBoo = 1
|
||||
|
||||
# Case of functions ( -1 - no change, 1 - upper, 2 - lower, 3 - title, 4 - as in pattern )
|
||||
#nCaseFnc = 4
|
||||
|
||||
# Case of functions ( -1 - no change, 1 - upper, 2 - lower, 3 - title )
|
||||
#nCaseUnk = -1
|
||||
|
||||
# Case of directives ( -1 - no change, 1 - upper, 2 - lower, 3 - title )
|
||||
#nCaseDrt = 2
|
||||
|
||||
# Number of spaces after # in directives ( -1 - no change )
|
||||
nSpaceDrt = 0
|
||||
|
||||
# -1 - no change, 1 - insert empty line before a function ( procedure,class ) declaration, 2 - remove it
|
||||
#nLineFnc = 1
|
||||
|
||||
# -1 - no change, 1 - insert empty line before return, 2 - remove it
|
||||
#nLineRet = 1
|
||||
|
||||
# -1 - no change, 1 - insert empty line before variables declaration, 2 - remove it
|
||||
#nLineVar = 1
|
||||
|
||||
# -1 - no change, 1 - insert empty line before code in function, 2 - remove it
|
||||
#nLineCode = 1
|
||||
|
||||
# Max level of nesting in brackets, while space is added after a comma
|
||||
#nBr4Comma = 1
|
||||
|
||||
# Max level of nesting in brackets, while space is added after/before a bracket
|
||||
#nBr4Brac = 2
|
||||
|
||||
# Extension for a formatted file ( if empty - replace original )
|
||||
#cExtSave =
|
||||
|
||||
# Extension for a backup file
|
||||
#cExtBack = bak
|
||||
1048
harbour/utils/hbformat/hbformat.prg
Normal file
1048
harbour/utils/hbformat/hbformat.prg
Normal file
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user