2013-04-04 04:30 UTC+0200 Viktor Szakats (harbour syenar.net)
* bin/commit.hb
+ added code to launch default git editor with ChangeLog.txt
(not yet activated)
* contrib/hbexpat/hbexpat.hbc
- reverted these two:
2013-04-03 16:01 UTC+0200
2013-03-27 16:29 UTC+0100
It seems that expat.hbc is always installed regardless
of local or system copy is used along the build/install
process
* utils/hbmk2/hbmk2.prg
! fixed -run on Darwin after 2013-03-15 13:57 UTC+0100
(untested)
This commit is contained in:
@@ -109,6 +109,7 @@ PROCEDURE Main()
|
||||
hb_MemoWrit( cLogName, cLog )
|
||||
|
||||
OutStd( hb_ProgName() + ": " + hb_StrFormat( "Edit %1$s and commit", cLogName ) + hb_eol() )
|
||||
// LaunchCommand( GitEditor(), cLogName )
|
||||
ErrorLevel( 0 )
|
||||
ELSE
|
||||
OutStd( hb_ProgName() + ": " + "Please correct errors listed above and re-run" + hb_eol() )
|
||||
@@ -255,4 +256,40 @@ STATIC FUNCTION GitUser()
|
||||
AllTrim( hb_StrReplace( cName, Chr( 10 ) + Chr( 13 ), "" ) ), ;
|
||||
StrTran( AllTrim( hb_StrReplace( cEMail, Chr( 10 ) + Chr( 13 ), "" ) ), "@", " " ) )
|
||||
|
||||
STATIC FUNCTION GitEditor()
|
||||
|
||||
LOCAL cValue := ""
|
||||
|
||||
hb_processRun( Shell() + " " + CmdEscape( "git config --global core.editor" ),, @cValue )
|
||||
|
||||
cValue := hb_StrReplace( cValue, Chr( 10 ) + Chr( 13 ), "" )
|
||||
|
||||
IF Left( cValue, 1 ) == "'" .AND. Right( cValue, 1 ) == "'"
|
||||
cValue := hb_StrShrink( SubStr( cValue, 2 ), 1 )
|
||||
ENDIF
|
||||
|
||||
IF Lower( cValue ) == "notepad.exe" /* banned, use notepad2.exe or else */
|
||||
cValue := ""
|
||||
ENDIF
|
||||
|
||||
RETURN cValue
|
||||
|
||||
STATIC FUNCTION LaunchCommand( cCommand, cArg )
|
||||
|
||||
IF Empty( cCommand )
|
||||
RETURN -1
|
||||
ENDIF
|
||||
|
||||
#if defined( __PLATFORM__WINDOWS )
|
||||
IF hb_osIsWinNT()
|
||||
cCommand := 'start "" "' + cCommand + '"'
|
||||
ELSE
|
||||
cCommand := "start " + cCommand
|
||||
ENDIF
|
||||
#elif defined( __PLATFORM__OS2 )
|
||||
cCommand := 'start "" "' + cCommand + '"'
|
||||
#endif
|
||||
|
||||
RETURN hb_run( cCommand + " " + cArg )
|
||||
|
||||
#include "check.hb"
|
||||
|
||||
Reference in New Issue
Block a user