author | fm |
Thu, 08 Oct 2009 14:00:56 +0200 | |
changeset 322 | edc4da7b7e84 |
parent 160 | 1e872a62c0f6 |
child 479 | 483685f53715 |
permissions | -rw-r--r-- |
95 | 1 |
"{ Package: 'cvut:stx/goodies/libsvn' }" |
2 |
||
3 |
"{ NameSpace: SVN }" |
|
4 |
||
5 |
Command subclass:#WCCommand |
|
6 |
instanceVariableNames:'alreadyCleaned workingCopy' |
|
7 |
classVariableNames:'' |
|
8 |
poolDictionaries:'' |
|
9 |
category:'SVN-Private-Commands' |
|
10 |
! |
|
11 |
||
12 |
||
13 |
!WCCommand methodsFor:'accessing'! |
|
14 |
||
15 |
workingCopy |
|
16 |
^ workingCopy |
|
17 |
||
18 |
"Created: / 16-03-2008 / 10:10:38 / janfrog" |
|
19 |
! |
|
20 |
||
21 |
workingCopy:aSVNWorkingCopy |
|
22 |
||
23 |
self assert: (aSVNWorkingCopy isKindOf: SVN::WorkingCopy). |
|
24 |
||
25 |
workingCopy := aSVNWorkingCopy. |
|
26 |
||
27 |
"Created: / 16-03-2008 / 10:10:38 / janfrog" |
|
28 |
"Modified: / 19-08-2009 / 11:28:58 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
29 |
! ! |
|
30 |
||
31 |
!WCCommand methodsFor:'executing'! |
|
32 |
||
33 |
execute |
|
34 |
^[super execute] on:SVN::WorkingCopyLockedError do: |
|
35 |
[:ex | |
|
36 |
alreadyCleaned |
|
37 |
ifTrue: |
|
38 |
[ex pass] |
|
39 |
ifFalse: |
|
40 |
[self svnCleanup. |
|
41 |
alreadyCleaned := true. |
|
42 |
self execute]] |
|
43 |
||
44 |
"Created: / 08-11-2008 / 08:30:34 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
45 |
! ! |
|
46 |
||
47 |
!WCCommand methodsFor:'executing - private'! |
|
48 |
||
49 |
svnCleanup |
|
50 |
||
51 |
^CleanupCommand new |
|
52 |
workingCopy: workingCopy; |
|
53 |
execute. |
|
54 |
||
55 |
"Created: / 08-11-2008 / 08:14:29 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
56 |
! |
|
57 |
||
58 |
svnCmdArgumentsOn:arg |
|
59 |
||
60 |
"arg nextPut:'-m'; nextPut: (message ? '')" |
|
61 |
||
62 |
"Created: / 16-03-2008 / 10:18:46 / janfrog" |
|
63 |
"Modified: / 19-03-2008 / 15:58:57 / janfrog" |
|
64 |
! |
|
65 |
||
66 |
svnCmdWorkdir |
|
67 |
"raise an error: must be redefined in concrete subclass(es)" |
|
68 |
||
69 |
^workingCopy path pathName |
|
70 |
||
71 |
"Created: / 16-03-2008 / 10:10:34 / janfrog" |
|
72 |
"Modified: / 19-08-2009 / 11:29:10 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
73 |
! |
|
74 |
||
75 |
svnProcessCommandOutput:out err:err |
|
76 |
^ out contents |
|
77 |
||
78 |
"Created: / 03-10-2008 / 16:31:45 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
79 |
! ! |
|
80 |
||
81 |
!WCCommand methodsFor:'initialization'! |
|
82 |
||
83 |
initialize |
|
84 |
||
85 |
super initialize. |
|
86 |
alreadyCleaned := false |
|
87 |
||
88 |
"Created: / 08-11-2008 / 08:15:55 / Jan Vrany <vranyj1@fel.cvut.cz>" |
|
89 |
! ! |
|
90 |
||
91 |
!WCCommand class methodsFor:'documentation'! |
|
92 |
||
93 |
version |
|
94 |
^ '$Header$' |
|
160 | 95 |
! |
96 |
||
97 |
version_CVS |
|
98 |
^ '$Header$' |
|
99 |
! |
|
100 |
||
101 |
version_SVN |
|
322
edc4da7b7e84
update #version_SVN with § as keyword expansion character
fm
parents:
160
diff
changeset
|
102 |
^'§Id: SVN__WCCommand.st 110 2009-08-19 13:21:10Z vranyj1 §' |
95 | 103 |
! ! |