public
Description: The Git TextMate Bundle
Homepage: http://tim.theenchanter.com/
Clone URL: git://github.com/timcharper/git-tmbundle.git
restore modules even if there weren't any modules to start with
timcharper (author)
Tue Apr 29 18:12:14 -0700 2008
commit  f02ee2ff4262c4ca37a3c68af012a0dcf474e339
tree    159cdf6e8df45ac4aa274b707a6c7af7a2556efd
parent  5249ba96c1dc262b69aa9eec8a15052b97a519fb
...
1
2
3
4
5
 
 
6
7
8
9
10
11
12
13
14
15
 
 
16
 
 
17
18
19
...
1
2
3
 
 
4
5
6
 
 
 
 
 
 
 
 
 
7
8
9
10
11
12
13
14
0
@@ -1,19 +1,14 @@
0
 module SubmoduleHelper
0
   module Update
0
     def with_submodule_stashing(&block)
0
- modules = git.submodule.all
0
- if modules.empty?
0
+ git.submodule.all.each { |m| m.stash }
0
+ begin
0
         yield
0
- else
0
- modules.each { |m| m.stash }
0
- begin
0
- yield
0
- ensure
0
- git.submodule.all.each { |m| m.restore }
0
- end
0
-
0
- update_submodules_si_hay
0
+ ensure
0
+ git.submodule.all.each { |m| m.restore }
0
       end
0
+
0
+ update_submodules_si_hay
0
     end
0
     
0
     def update_submodules_si_hay

Comments

    No one has commented yet.