author | Jan Vrany <jan.vrany@fit.cvut.cz> |
Tue, 05 Feb 2013 15:24:24 +0100 | |
changeset 219 | 475366f8ba6f |
parent 212 | 8ec5884fba41 |
child 302 | e078bdcef149 |
permissions | -rw-r--r-- |
34 | 1 |
" |
210 | 2 |
COPYRIGHT (c) 2012-2013 by Jan Vrany |
3 |
All Rights Reserved |
|
34 | 4 |
|
210 | 5 |
This software is furnished under a license and may be used |
6 |
only in accordance with the terms of that license and with the |
|
7 |
inclusion of the above copyright notice. This software may not |
|
8 |
be provided or otherwise made available to, or used by, any |
|
9 |
other person. No title to or ownership of the software is |
|
10 |
hereby transferred. |
|
34 | 11 |
" |
12 |
"{ Package: 'stx:libscm/mercurial' }" |
|
13 |
||
14 |
TestResource subclass:#HGRepositoriesResource |
|
15 |
instanceVariableNames:'repositoryDirectory' |
|
16 |
classVariableNames:'HGRepositoriesArchiveDir' |
|
17 |
poolDictionaries:'' |
|
69
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
54
diff
changeset
|
18 |
category:'SCM-Mercurial-Tests' |
34 | 19 |
! |
20 |
||
21 |
!HGRepositoriesResource class methodsFor:'documentation'! |
|
22 |
||
23 |
copyright |
|
24 |
" |
|
210 | 25 |
COPYRIGHT (c) 2012-2013 by Jan Vrany |
26 |
All Rights Reserved |
|
34 | 27 |
|
210 | 28 |
This software is furnished under a license and may be used |
29 |
only in accordance with the terms of that license and with the |
|
30 |
inclusion of the above copyright notice. This software may not |
|
31 |
be provided or otherwise made available to, or used by, any |
|
32 |
other person. No title to or ownership of the software is |
|
33 |
hereby transferred. |
|
34 | 34 |
" |
35 |
! ! |
|
36 |
||
37 |
!HGRepositoriesResource class methodsFor:'class initialization'! |
|
38 |
||
39 |
initialize |
|
40 |
||
41 |
HGRepositoriesArchiveDir := (Smalltalk packageDirectoryForPackageId:self package) |
|
42 |
/ 'tests' / 'repositories' |
|
43 |
||
44 |
"Created: / 09-12-2010 / 23:07:08 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
45 |
"Modified (format): / 27-12-2011 / 18:07:34 / dundee" |
|
46 |
"Modified: / 17-10-2012 / 13:02:22 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
47 |
! ! |
|
48 |
||
49 |
!HGRepositoriesResource methodsFor:'accessing'! |
|
50 |
||
93
2579830f6b61
Tests fixed. Not-yet-supported tests marked as skipped.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
51 |
directoryForRepositories |
2579830f6b61
Tests fixed. Not-yet-supported tests marked as skipped.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
52 |
^repositoryDirectory |
2579830f6b61
Tests fixed. Not-yet-supported tests marked as skipped.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
53 |
|
2579830f6b61
Tests fixed. Not-yet-supported tests marked as skipped.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
54 |
"Created: / 22-11-2012 / 11:34:30 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
2579830f6b61
Tests fixed. Not-yet-supported tests marked as skipped.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
55 |
! |
2579830f6b61
Tests fixed. Not-yet-supported tests marked as skipped.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
56 |
|
34 | 57 |
directoryForRepositoryNamed: nm |
174
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
58 |
^self directoryForRepositoryNamed: nm unpack: true |
34 | 59 |
|
174
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
60 |
"Created: / 19-09-2012 / 18:57:49 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
61 |
"Modified: / 14-01-2013 / 13:13:19 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
62 |
! |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
63 |
|
212
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
64 |
directoryForRepositoryNamed: nm init: init |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
65 |
"Returns path to repository named nm. |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
66 |
|
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
67 |
If `init` is true, then the repository is created and initialized |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
68 |
(with no content at all). If 'init' is false, then only directory |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
69 |
name is returned (without creating it)." |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
70 |
|
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
71 |
^self directoryForRepositoryNamed: nm unpack: false init: init |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
72 |
|
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
73 |
"Created: / 01-02-2013 / 13:38:49 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
74 |
! |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
75 |
|
174
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
76 |
directoryForRepositoryNamed: nm unpack: unpack |
34 | 77 |
"Returns path to repository named nm. |
174
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
78 |
|
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
79 |
If `unpack` is true, then the repository is frechly created and thus |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
80 |
empty. If 'unpack' is true, then initial content of repository will |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
81 |
be loaded from zip archive located in |
34 | 82 |
<package path>/stx/libsvn/tests/repositories/<name>.git.zip |
174
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
83 |
If the files does not exists, an error is raised" |
34 | 84 |
|
212
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
85 |
^self directoryForRepositoryNamed: nm unpack: unpack init: true |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
86 |
|
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
87 |
"Created: / 14-01-2013 / 13:13:01 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
88 |
"Modified: / 01-02-2013 / 13:39:55 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
89 |
! |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
90 |
|
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
91 |
directoryForRepositoryNamed: nm unpack: unpack init: init |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
92 |
"Returns path to repository named nm. |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
93 |
|
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
94 |
If `unpack` is true, then the repository is frechly created and thus |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
95 |
empty, unless 'init' is false (in that case, only a name of directory |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
96 |
that does not exists yet ir returned. |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
97 |
|
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
98 |
If 'unpack' is true, then initial content of repository will |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
99 |
be loaded from zip archive located in |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
100 |
<package path>/stx/libsvn/tests/repositories/<name>.git.zip |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
101 |
If the files does not exists, an error is raised" |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
102 |
|
166
dbf0f7eb0dc9
Performance fix in HFSourceCodeManager revision log access.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
103 |
| archiveNm archive repo dir ok | |
212
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
104 |
|
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
105 |
unpack ifTrue:[ |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
106 |
self assert: init description: 'Cannot unpack non-initialized repo!!' |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
107 |
]. |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
108 |
|
69
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
54
diff
changeset
|
109 |
archiveNm := nm copy |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
54
diff
changeset
|
110 |
replaceAll:$/ with:$_; |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
54
diff
changeset
|
111 |
yourself. |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
54
diff
changeset
|
112 |
archive := HGRepositoriesArchiveDir / (archiveNm , '.hg.zip'). |
174
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
113 |
unpack ifTrue:[ |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
114 |
self assert:archive exists description:'dump file does not exist'. |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
115 |
]. |
34 | 116 |
self assert:repositoryDirectory exists description:'repository directory does not exist'. |
117 |
||
93
2579830f6b61
Tests fixed. Not-yet-supported tests marked as skipped.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
118 |
dir := "/Filename newTemporaryDirectoryIn: |
2579830f6b61
Tests fixed. Not-yet-supported tests marked as skipped.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
119 |
repositoryDirectory. |
2579830f6b61
Tests fixed. Not-yet-supported tests marked as skipped.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
120 |
|
212
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
121 |
init ifFalse:[ |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
122 |
^ (dir asAbsoluteFilename / nm) pathName. |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
123 |
]. |
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
124 |
|
174
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
125 |
unpack ifTrue:[ |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
126 |
ok := true. |
166
dbf0f7eb0dc9
Performance fix in HFSourceCodeManager revision log access.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
127 |
OperatingSystem |
dbf0f7eb0dc9
Performance fix in HFSourceCodeManager revision log access.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
128 |
executeCommand:('unzip %1' bindWith: (archive asAbsoluteFilename pathName)) |
dbf0f7eb0dc9
Performance fix in HFSourceCodeManager revision log access.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
129 |
inDirectory:dir |
174
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
130 |
onError:[:status | ok := false]. |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
131 |
ok ifFalse:[ |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
132 |
OperatingSystem |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
133 |
executeCommand:('unzip %1' bindWith: (archive asAbsoluteFilename pathName)) |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
134 |
inDirectory:dir |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
135 |
onError:[:status | self assert:false description:'unzip failed']. |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
136 |
]. |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
137 |
] ifFalse:[ |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
138 |
| repodir | |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
139 |
|
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
140 |
repodir := (dir asAbsoluteFilename / nm). |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
141 |
repodir directory recursiveMakeDirectory. |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
142 |
OperatingSystem |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
143 |
executeCommand:('hg init %1' bindWith: (repodir baseName)) |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
144 |
inDirectory:repodir directory pathName |
0d293012a897
Fixed commit to freshly created repository.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
166
diff
changeset
|
145 |
onError:[:status | self assert:false description:'hg init failed']. |
166
dbf0f7eb0dc9
Performance fix in HFSourceCodeManager revision log access.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
115
diff
changeset
|
146 |
]. |
34 | 147 |
|
93
2579830f6b61
Tests fixed. Not-yet-supported tests marked as skipped.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
69
diff
changeset
|
148 |
repo := (dir asAbsoluteFilename / nm). |
34 | 149 |
self assert: repo exists. |
150 |
self assert: (repo / '.hg') exists. |
|
151 |
||
152 |
^repo pathName |
|
153 |
||
212
8ec5884fba41
Fixed bugs introduced on 2013-01-22.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
210
diff
changeset
|
154 |
"Created: / 01-02-2013 / 13:35:30 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
34 | 155 |
! ! |
156 |
||
157 |
!HGRepositoriesResource methodsFor:'running'! |
|
158 |
||
159 |
setUp |
|
160 |
||
69
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
54
diff
changeset
|
161 |
repositoryDirectory := Filename newTemporaryDirectory. |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
54
diff
changeset
|
162 |
Smalltalk packagePath: (Smalltalk packagePath asOrderedCollection |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
54
diff
changeset
|
163 |
addFirst: repositoryDirectory pathName; |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
54
diff
changeset
|
164 |
yourself) |
34 | 165 |
|
166 |
"Created: / 09-12-2010 / 23:53:48 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
167 |
"Modified (format): / 27-12-2011 / 18:07:04 / dundee" |
|
69
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
54
diff
changeset
|
168 |
"Modified: / 16-11-2012 / 20:16:18 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
34 | 169 |
! |
170 |
||
171 |
tearDown |
|
69
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
54
diff
changeset
|
172 |
Smalltalk packagePath: (Smalltalk packagePath |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
54
diff
changeset
|
173 |
remove: repositoryDirectory pathName; |
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
54
diff
changeset
|
174 |
yourself). |
34 | 175 |
[ |
176 |
repositoryDirectory recursiveRemove |
|
177 |
] on: Error do:[ |
|
69
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
54
diff
changeset
|
178 |
"Stupid windows!!" |
34 | 179 |
] |
180 |
||
181 |
"Created: / 09-12-2010 / 23:54:03 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
182 |
"Modified: / 30-09-2012 / 05:26:04 / jv" |
|
69
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
54
diff
changeset
|
183 |
"Modified: / 16-11-2012 / 20:16:32 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
34 | 184 |
! ! |
185 |
||
186 |
!HGRepositoriesResource methodsFor:'testing'! |
|
187 |
||
188 |
isAvailable |
|
189 |
||
190 |
^HGRepositoriesArchiveDir exists and:[OperatingSystem canExecuteCommand:'unzip'] |
|
191 |
||
192 |
"Created: / 09-12-2010 / 23:06:42 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
193 |
"Modified (format): / 27-12-2011 / 18:05:57 / dundee" |
|
194 |
"Modified: / 17-10-2012 / 13:02:34 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
195 |
! ! |
|
196 |
||
197 |
!HGRepositoriesResource class methodsFor:'documentation'! |
|
198 |
||
54
66045198bfbc
More changes towards self hosting. Some work on model is still missing...
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
34
diff
changeset
|
199 |
version_HG |
115
b1ed2d29054b
version_HG changed to return string.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
93
diff
changeset
|
200 |
|
b1ed2d29054b
version_HG changed to return string.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
93
diff
changeset
|
201 |
^ '$Changeset: <not expanded> $' |
54
66045198bfbc
More changes towards self hosting. Some work on model is still missing...
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
34
diff
changeset
|
202 |
! |
66045198bfbc
More changes towards self hosting. Some work on model is still missing...
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
34
diff
changeset
|
203 |
|
34 | 204 |
version_SVN |
69
17045d49309f
Refactoring: preparation for accessing changeset contents.
vranyj1@bd9d3459-6c23-4dd9-91de-98eeebb81177
parents:
54
diff
changeset
|
205 |
^ '§Id:: §' |
34 | 206 |
! ! |
207 |
||
189
3d6c123a7295
HGChangesetId>>readFrom: now supports revno-only and hash-only form of CS IDs.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
174
diff
changeset
|
208 |
|
34 | 209 |
HGRepositoriesResource initialize! |