author | Jan Vrany <jan.vrany@fit.cvut.cz> |
Mon, 10 Dec 2012 02:49:43 +0000 | |
changeset 151 | 527a1e85aef8 |
parent 115 | b1ed2d29054b |
child 154 | c1221bf5f357 |
permissions | -rw-r--r-- |
69
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
1 |
"{ Package: 'stx:libscm/mercurial' }"! |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
2 |
|
88 | 3 |
!Annotation class methodsFor:'instance creation'! |
4 |
||
5 |
HGRevision: aString |
|
6 |
"Used by Mercurial to internally store revision info. Should never appear in source code!!" |
|
7 |
||
8 |
^HGRevisionAnnotation revision: aString |
|
9 |
||
10 |
"Created: / 20-11-2012 / 23:34:26 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
11 |
! ! |
|
12 |
||
69
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
13 |
!ByteArray methodsFor:'converting'! |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
14 |
|
103
04731ef44417
HGNodeId renamed to HGChangesetId
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
102
diff
changeset
|
15 |
asHGChangesetId |
04731ef44417
HGNodeId renamed to HGChangesetId
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
102
diff
changeset
|
16 |
^ HGChangesetId fromBytes:self. |
69
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
17 |
|
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
18 |
"Created: / 16-11-2012 / 21:33:32 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
19 |
! ! |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
20 |
|
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
21 |
!Integer methodsFor:'converting'! |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
22 |
|
103
04731ef44417
HGNodeId renamed to HGChangesetId
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
102
diff
changeset
|
23 |
asHGChangesetId |
04731ef44417
HGNodeId renamed to HGChangesetId
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
102
diff
changeset
|
24 |
^ (HGChangesetId new:0) revno:self. |
69
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
25 |
|
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
26 |
"Created: / 16-11-2012 / 21:23:33 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
27 |
! ! |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
28 |
|
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
29 |
!Object methodsFor:'converting'! |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
30 |
|
103
04731ef44417
HGNodeId renamed to HGChangesetId
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
102
diff
changeset
|
31 |
asHGChangesetId |
04731ef44417
HGNodeId renamed to HGChangesetId
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
102
diff
changeset
|
32 |
HGError |
04731ef44417
HGNodeId renamed to HGChangesetId
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
102
diff
changeset
|
33 |
raiseErrorString:'Cannot convert arbitrary object to Mercurial nodeid' |
69
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
34 |
|
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
35 |
"Created: / 16-11-2012 / 21:23:05 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
36 |
! ! |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
37 |
|
88 | 38 |
!Object methodsFor:'converting'! |
39 |
||
40 |
asHGRevision |
|
103
04731ef44417
HGNodeId renamed to HGChangesetId
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
102
diff
changeset
|
41 |
^self asHGChangesetId |
88 | 42 |
|
43 |
"Created: / 20-11-2012 / 23:32:47 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
103
04731ef44417
HGNodeId renamed to HGChangesetId
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
102
diff
changeset
|
44 |
"Modified: / 27-11-2012 / 17:56:55 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
88 | 45 |
! ! |
46 |
||
47 |
!ProjectDefinition class methodsFor:'accessing - hg'! |
|
48 |
||
49 |
hgBinaryRevision |
|
50 |
||
51 |
" |
|
52 |
Answers Mercurial revision from which the package was compiled. |
|
53 |
If no binary revision is available, returns nil." |
|
54 |
||
55 |
||
56 |
| revInfo | |
|
57 |
||
91 | 58 |
self binaryRevisionString notNil ifTrue:[ |
59 |
revInfo := HGRevisionInfo readFrom: self binaryRevisionString onError:[nil]. |
|
88 | 60 |
revInfo notNil ifTrue:[ |
61 |
^revInfo changesetId |
|
62 |
]. |
|
63 |
]. |
|
64 |
^nil |
|
65 |
||
66 |
||
67 |
" |
|
68 |
stx_libbasic hgBinaryRevision |
|
69 |
stx_libsvn hgBinaryRevision |
|
70 |
stx_libscm_mercurial hgBinaryRevision |
|
71 |
||
72 |
" |
|
73 |
||
74 |
"Created: / 20-11-2012 / 23:58:55 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
75 |
! ! |
|
76 |
||
77 |
!ProjectDefinition class methodsFor:'accessing - hg'! |
|
78 |
||
79 |
hgLogicalRevision |
|
80 |
||
81 |
" |
|
82 |
Answers Mercurial revision on which is this package based on logically. |
|
83 |
||
84 |
Revision is computed as follows: |
|
85 |
1) Look, if receiver's version_HG method has a (hidden) annotation HGRevision:, |
|
86 |
if so, return its value. |
|
87 |
2) If receiver's binary revision is not nil, return it. |
|
88 |
3) Look into a package directory and if there is a Mercurial repository, |
|
89 |
return working copy's revision" |
|
90 |
||
91 |
| versionMethod versionAnnotation revInfo pkgDir repoDir repo | |
|
92 |
||
93 |
"1 --- " |
|
94 |
||
102
16bc16d9e6d5
Update logical revision on commit,
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
93
diff
changeset
|
95 |
versionMethod := self class compiledMethodAt: HGSourceCodeManager nameOfVersionMethodInClasses. |
88 | 96 |
versionMethod notNil ifTrue:[ |
97 |
versionAnnotation := versionMethod annotationAt: #HGRevision:. |
|
98 |
versionAnnotation notNil ifTrue:[ |
|
99 |
^versionAnnotation revision |
|
100 |
]. |
|
101 |
]. |
|
102 |
||
103 |
"2 --- " |
|
91 | 104 |
self binaryRevisionString notNil ifTrue:[ |
105 |
revInfo := HGRevisionInfo readFrom: self binaryRevisionString onError:[nil]. |
|
88 | 106 |
revInfo notNil ifTrue:[ |
107 |
^revInfo changesetId |
|
108 |
]. |
|
109 |
]. |
|
110 |
||
111 |
"3 --- " |
|
112 |
pkgDir := Smalltalk getPackageDirectoryForPackage: self package. |
|
113 |
pkgDir notNil ifTrue:[ |
|
114 |
repoDir := HGRepository discover: pkgDir. |
|
115 |
repoDir notNil ifTrue:[ |
|
116 |
repo := HGRepository on: repoDir. |
|
117 |
^repo workingCopy changeset id |
|
118 |
] |
|
119 |
]. |
|
120 |
||
121 |
"4 --- " |
|
122 |
self breakPoint: #jv. |
|
123 |
^nil |
|
124 |
||
125 |
||
126 |
" |
|
127 |
stx_libbasic hgLogicalRevision |
|
128 |
stx_libsvn hgLogicalRevision |
|
129 |
stx_libscm_mercurial hgLogicalRevision |
|
130 |
||
131 |
" |
|
132 |
||
133 |
"Created: / 20-11-2012 / 23:54:24 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
102
16bc16d9e6d5
Update logical revision on commit,
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
93
diff
changeset
|
134 |
"Modified: / 23-11-2012 / 23:02:33 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
88 | 135 |
! ! |
136 |
||
107
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
137 |
!ProjectDefinition class methodsFor:'description - actions - hg'! |
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
138 |
|
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
139 |
hgPostLoad |
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
140 |
<postLoad> |
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
141 |
|
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
142 |
| dir repo versionMethod | |
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
143 |
"Eventually update an version_HG" |
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
144 |
|
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
145 |
self binaryRevisionString isNil ifTrue:[ |
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
146 |
dir := Smalltalk getPackageDirectoryForPackage: self package. |
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
147 |
dir := HGRepository discover: dir. |
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
148 |
dir notNil ifTrue:[ |
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
149 |
repo := HGRepository on: dir. |
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
150 |
versionMethod := HGSourceCodeManager ensureVersionMethodInClass: self package: self package. |
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
151 |
versionMethod annotateWith: |
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
152 |
(HGRevisionAnnotation revision: repo workingCopy changeset id) |
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
153 |
]. |
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
154 |
]. |
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
155 |
|
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
156 |
"Created: / 26-11-2012 / 13:06:06 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
157 |
"Modified: / 27-11-2012 / 22:14:41 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
158 |
! ! |
c92f7674485e
Fixed test StXTests>>test_commit_03c
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
103
diff
changeset
|
159 |
|
69
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
160 |
!String methodsFor:'converting'! |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
161 |
|
103
04731ef44417
HGNodeId renamed to HGChangesetId
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
102
diff
changeset
|
162 |
asHGChangesetId |
04731ef44417
HGNodeId renamed to HGChangesetId
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
102
diff
changeset
|
163 |
^ HGChangesetId fromString:self. |
69
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
164 |
|
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
165 |
"Created: / 16-11-2012 / 21:24:01 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
166 |
! ! |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
167 |
|
80
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
168 |
!UserPreferences methodsFor:'accessing-scm-mercurial'! |
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
169 |
|
151
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
170 |
hgAutopush |
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
171 |
"Return true, if changes should be automatically pushed |
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
172 |
to an upstream repository (autopush), false otherwise" |
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
173 |
|
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
174 |
^self at: #hgAutopush ifAbsent:[ false "or true?" ]. |
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
175 |
|
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
176 |
"Created: / 10-12-2012 / 01:23:44 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
177 |
! ! |
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
178 |
|
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
179 |
!UserPreferences methodsFor:'accessing-scm-mercurial'! |
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
180 |
|
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
181 |
hgAutopush: aBoolean |
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
182 |
"Set whether changes should be automatically pushed |
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
183 |
to an upstream repository (autopush)" |
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
184 |
|
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
185 |
^self at: #hgAutopush put: aBoolean. |
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
186 |
|
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
187 |
" |
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
188 |
UserPreferences current hgAutopush |
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
189 |
UserPreferences current hgAutopush: true |
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
190 |
UserPreferences current hgAutopush: false |
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
191 |
" |
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
192 |
|
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
193 |
"Created: / 10-12-2012 / 01:24:57 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
194 |
! ! |
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
195 |
|
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
196 |
!UserPreferences methodsFor:'accessing-scm-mercurial'! |
527a1e85aef8
Support for 'autopush' in commit dialog.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
197 |
|
80
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
198 |
hgCommand |
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
199 |
"Returns path svn executable" |
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
200 |
|
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
201 |
| cmd | |
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
202 |
|
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
203 |
cmd := self at:#hgCommand ifAbsent:[ nil ]. |
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
204 |
^cmd isEmptyOrNil ifTrue:[ nil ] ifFalse:[ cmd ] |
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
205 |
|
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
206 |
"Created: / 19-11-2012 / 21:39:12 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
207 |
! ! |
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
208 |
|
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
209 |
!UserPreferences methodsFor:'accessing-scm-mercurial'! |
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
210 |
|
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
211 |
hgCommand: aString |
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
212 |
"Set the command to 'hg' executable" |
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
213 |
|
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
214 |
self at:#hgCommand put: aString. |
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
215 |
HGCommand hgCommand: aString. |
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
216 |
|
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
217 |
" |
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
218 |
UserPreferences current hgCommand |
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
219 |
UserPreferences current hgCommand:'hg' |
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
220 |
UserPreferences current hgCommand:nil |
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
221 |
" |
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
222 |
|
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
223 |
"Created: / 19-11-2012 / 21:39:38 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
224 |
! ! |
8f300696b26b
Added configurable path to 'hg' command.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
225 |
|
69
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
226 |
!stx_libscm_mercurial class methodsFor:'documentation'! |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
227 |
|
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
diff
changeset
|
228 |
extensionsVersion_HG |
115
b1ed2d29054b
version_HG changed to return string.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
107
diff
changeset
|
229 |
|
b1ed2d29054b
version_HG changed to return string.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
107
diff
changeset
|
230 |
^ '$Changeset: <not expanded> $' |
93
2579830f6b61
Tests fixed. Not-yet-supported tests marked as skipped.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
91
diff
changeset
|
231 |
! ! |