@@ -644,8 +644,9 @@ def __init__(self, repo, path=_HEAD_NAME):
644
644
super (HEAD , self ).__init__ (repo , path )
645
645
646
646
def orig_head (self ):
647
- """:return: SymbolicReference pointing at the ORIG_HEAD, which is maintained
648
- to contain the previous value of HEAD"""
647
+ """
648
+ :return: SymbolicReference pointing at the ORIG_HEAD, which is maintained
649
+ to contain the previous value of HEAD"""
649
650
return SymbolicReference (self .repo , self ._ORIG_HEAD_NAME )
650
651
651
652
def _set_reference (self , ref ):
@@ -795,8 +796,10 @@ def delete(cls, repo, *heads, **kwargs):
795
796
796
797
797
798
def set_tracking_branch (self , remote_reference ):
798
- """Configure this branch to track the given remote reference. This will alter
799
- this branch's configuration accordingly.
799
+ """
800
+ Configure this branch to track the given remote reference. This will alter
801
+ this branch's configuration accordingly.
802
+
800
803
:param remote_reference: The remote reference to track or None to untrack
801
804
any references
802
805
:return: self"""
@@ -820,7 +823,8 @@ def set_tracking_branch(self, remote_reference):
820
823
821
824
822
825
def tracking_branch (self ):
823
- """:return: The remote_reference we are tracking, or None if we are
826
+ """
827
+ :return: The remote_reference we are tracking, or None if we are
824
828
not a tracking branch"""
825
829
reader = self .config_reader ()
826
830
if reader .has_option (self .k_config_remote ) and reader .has_option (self .k_config_remote_ref ):
@@ -896,12 +900,14 @@ def _config_parser(self, read_only):
896
900
return SectionConstraint (parser , 'branch "%s"' % self .name )
897
901
898
902
def config_reader (self ):
899
- """:return: A configuration parser instance constrained to only read
900
- this instance's values"""
903
+ """
904
+ :return: A configuration parser instance constrained to only read
905
+ this instance's values"""
901
906
return self ._config_parser (read_only = True )
902
907
903
908
def config_writer (self ):
904
- """:return: A configuration writer instance with read-and write acccess
909
+ """
910
+ :return: A configuration writer instance with read-and write acccess
905
911
to options of this head"""
906
912
return self ._config_parser (read_only = False )
907
913
0 commit comments