diff -r 5cc256ed28a1 -r 237ed0ed6c49 mercurial/HGCommand.st --- a/mercurial/HGCommand.st Wed Mar 19 23:19:22 2014 +0000 +++ b/mercurial/HGCommand.st Fri Mar 21 11:23:30 2014 +0000 @@ -33,6 +33,20 @@ privateIn:HGCommand ! +HGCommand subclass:#bookmark + instanceVariableNames:'revision name' + classVariableNames:'' + poolDictionaries:'' + privateIn:HGCommand +! + +HGCommand subclass:#bookmark_delete + instanceVariableNames:'revision name' + classVariableNames:'' + poolDictionaries:'' + privateIn:HGCommand +! + HGCommand subclass:#branches instanceVariableNames:'active closed' classVariableNames:'' @@ -419,6 +433,21 @@ "Created: / 15-11-2012 / 00:06:15 / Jan Vrany " ! +bookmark + "raise an error: this method should be implemented (TODO)" + + ^ bookmark new + + "Created: / 20-03-2014 / 17:25:11 / Jan Vrany " +! + +bookmark_delete + + ^ bookmark_delete new + + "Created: / 21-03-2014 / 01:14:45 / Jan Vrany " +! + branches ^branches new @@ -933,6 +962,103 @@ "Modified: / 15-11-2012 / 00:38:43 / Jan Vrany " ! ! +!HGCommand::bookmark methodsFor:'accessing'! + +name + ^ name +! + +name:something + name := something. +! + +revision + ^ revision +! + +revision:something + revision := something. +! ! + +!HGCommand::bookmark methodsFor:'private'! + +argumentsCommandOn:stream + revision notNil ifTrue:[ + stream + nextPut: '-r'; + nextPut: revision asString. + ]. + stream + nextPut: name. + + "Created: / 20-03-2014 / 17:26:50 / Jan Vrany " + "Modified: / 20-03-2014 / 18:43:11 / Jan Vrany " +! + +parseError:stream + ^ (self parserOn: stream) parseErrorBookmark + + "Created: / 20-03-2014 / 17:27:34 / Jan Vrany " +! + +parseOutput:stream + "Parses output of 'hg' command, i.e. commit, log, update, checkout, + etc." + + ^ nil + + "Created: / 20-03-2014 / 17:27:16 / Jan Vrany " +! ! + +!HGCommand::bookmark_delete methodsFor:'accessing'! + +name + ^ name +! + +name:something + name := something. +! ! + +!HGCommand::bookmark_delete methodsFor:'private'! + +argumentsCommandOn:stream + stream + nextPut: '--delete'; + nextPut: name. + + "Created: / 20-03-2014 / 17:26:50 / Jan Vrany " + "Modified: / 21-03-2014 / 01:14:10 / Jan Vrany " +! + +command + "Returns the hg 'command' option, i.e. commit, + push, pull, ..." + + ^ 'bookmark' + + " + HGCommand::push basicNew command + " + + "Created: / 21-03-2014 / 01:21:00 / Jan Vrany " +! + +parseError:stream + ^ (self parserOn: stream) parseErrorBookmark + + "Created: / 20-03-2014 / 17:27:34 / Jan Vrany " +! + +parseOutput:stream + "Parses output of 'hg' command, i.e. commit, log, update, checkout, + etc." + + ^ nil + + "Created: / 20-03-2014 / 17:27:16 / Jan Vrany " +! ! + !HGCommand::branches methodsFor:'accessing'! active