vcs 0.2.148 → 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- data/AUTHORS +6 -0
- data/NEWS +9 -0
- data/README +82 -0
- data/Rakefile +7 -72
- data/SPEC.dyn.yml +10 -0
- data/SPEC.gemspec +14 -0
- data/SPEC.yml +39 -0
- data/bin/vcs +18 -16
- data/lib/vcs/changelog.rb +164 -0
- data/lib/vcs/conflict.rb +21 -0
- data/{src → lib/vcs}/cvs.rb +1 -1
- data/{src → lib/vcs}/diff.rb +2 -2
- data/lib/vcs/diffstat.rb +28 -0
- data/lib/vcs/edit.rb +16 -0
- data/{src → lib/vcs}/last_changed_date.rb +3 -5
- data/{src → lib/vcs}/mail.rb +4 -4
- data/lib/vcs/message.rb +79 -0
- data/{src → lib/vcs}/mycommit.rb +15 -15
- data/{src → lib/vcs}/news.rb +6 -6
- data/{src → lib/vcs}/prcs.rb +1 -1
- data/{src → lib/vcs}/revision.rb +3 -4
- data/lib/vcs/script.rb +19 -0
- data/{src → lib/vcs}/status.rb +1 -1
- data/{src → lib/vcs}/svn.rb +3 -5
- data/lib/vcs/url.rb +16 -0
- data/lib/vcs/vcs.rb +279 -0
- metadata +52 -150
- data/TODO +0 -19
- data/doc/jamis.rb +0 -564
- data/ruby_ex/abstract.rb +0 -254
- data/ruby_ex/abstract_node.rb +0 -85
- data/ruby_ex/algorithms/simulated_annealing.rb +0 -140
- data/ruby_ex/array_each_pair.rb +0 -18
- data/ruby_ex/ask.rb +0 -101
- data/ruby_ex/attributed_class.rb +0 -302
- data/ruby_ex/cache.rb +0 -373
- data/ruby_ex/checkout.rb +0 -12
- data/ruby_ex/choose.rb +0 -271
- data/ruby_ex/commands.rb +0 -18
- data/ruby_ex/commands/command.rb +0 -401
- data/ruby_ex/commands/datas.rb +0 -16
- data/ruby_ex/commands/datas/data.rb +0 -33
- data/ruby_ex/commands/datas/factory.rb +0 -66
- data/ruby_ex/commands/factory.rb +0 -66
- data/ruby_ex/commands/helpers.rb +0 -67
- data/ruby_ex/commands/pipe.rb +0 -64
- data/ruby_ex/commands/runners.rb +0 -17
- data/ruby_ex/commands/runners/exec.rb +0 -49
- data/ruby_ex/commands/runners/fork.rb +0 -97
- data/ruby_ex/commands/runners/runner.rb +0 -107
- data/ruby_ex/commands/seq.rb +0 -27
- data/ruby_ex/config_file.rb +0 -96
- data/ruby_ex/const_regexp.rb +0 -59
- data/ruby_ex/daemon.rb +0 -134
- data/ruby_ex/diff.rb +0 -667
- data/ruby_ex/dlogger.rb +0 -62
- data/ruby_ex/drb/dispatcher.rb +0 -252
- data/ruby_ex/drb/dispatcher_server_test.rb +0 -29
- data/ruby_ex/drb/drb_observable.rb +0 -97
- data/ruby_ex/drb/drb_observable_pool.rb +0 -27
- data/ruby_ex/drb/drb_service.rb +0 -43
- data/ruby_ex/drb/drb_undumped_attributes.rb +0 -55
- data/ruby_ex/drb/drb_undumped_indexed_object.rb +0 -54
- data/ruby_ex/drb/insecure_protected_methods.rb +0 -103
- data/ruby_ex/drb/session_client_test.rb +0 -40
- data/ruby_ex/drb/session_manager.rb +0 -246
- data/ruby_ex/drb/session_server.rb +0 -53
- data/ruby_ex/dtime.rb +0 -143
- data/ruby_ex/dumpable_proc.rb +0 -63
- data/ruby_ex/exception.rb +0 -32
- data/ruby_ex/filetype.rb +0 -229
- data/ruby_ex/fileutils_ex.rb +0 -44
- data/ruby_ex/fold.rb +0 -58
- data/ruby_ex/generate_id.rb +0 -44
- data/ruby_ex/hookable.rb +0 -262
- data/ruby_ex/hooker.rb +0 -54
- data/ruby_ex/inactive_timeout.rb +0 -137
- data/ruby_ex/indexed_node.rb +0 -66
- data/ruby_ex/io_marshal.rb +0 -100
- data/ruby_ex/ioo.rb +0 -194
- data/ruby_ex/labeled_node.rb +0 -63
- data/ruby_ex/logger_observer.rb +0 -23
- data/ruby_ex/md5sum.rb +0 -66
- data/ruby_ex/mktemp.rb +0 -208
- data/ruby_ex/module/attr_once.rb +0 -36
- data/ruby_ex/module/autoload_tree.rb +0 -75
- data/ruby_ex/module/hierarchy.rb +0 -335
- data/ruby_ex/module/instance_method_visibility.rb +0 -73
- data/ruby_ex/module_ex.rb +0 -11
- data/ruby_ex/node.rb +0 -80
- data/ruby_ex/object_monitor.rb +0 -145
- data/ruby_ex/object_monitor_activity.rb +0 -33
- data/ruby_ex/observable.rb +0 -140
- data/ruby_ex/observable_pool.rb +0 -293
- data/ruby_ex/orderedhash.rb +0 -252
- data/ruby_ex/pathname_ex.rb +0 -152
- data/ruby_ex/pp_hierarchy.rb +0 -29
- data/ruby_ex/pseudo_cache.rb +0 -190
- data/ruby_ex/queue.rb +0 -56
- data/ruby_ex/random_generators.rb +0 -25
- data/ruby_ex/random_generators/random_generator.rb +0 -31
- data/ruby_ex/random_generators/ruby.rb +0 -23
- data/ruby_ex/safe_eval.rb +0 -348
- data/ruby_ex/sendmail.rb +0 -215
- data/ruby_ex/service_manager.rb +0 -121
- data/ruby_ex/session/administrable.rb +0 -120
- data/ruby_ex/session/client.rb +0 -153
- data/ruby_ex/session/const.rb +0 -18
- data/ruby_ex/session/dispatcher.rb +0 -184
- data/ruby_ex/session/error.rb +0 -21
- data/ruby_ex/session/fetchable.rb +0 -57
- data/ruby_ex/session/fetcher.rb +0 -62
- data/ruby_ex/session/hookable.rb +0 -26
- data/ruby_ex/session/profile.rb +0 -110
- data/ruby_ex/session/server.rb +0 -582
- data/ruby_ex/session/test/administrable_test.rb +0 -337
- data/ruby_ex/session/test/basic_test.rb +0 -523
- data/ruby_ex/session/test/dispatcher_test.rb +0 -409
- data/ruby_ex/session/test/fetchable_test.rb +0 -119
- data/ruby_ex/session/test/sub_server_test.rb +0 -188
- data/ruby_ex/shuffle.rb +0 -30
- data/ruby_ex/spring.rb +0 -136
- data/ruby_ex/spring_set.rb +0 -137
- data/ruby_ex/string_ex.rb +0 -28
- data/ruby_ex/symtbl.rb +0 -106
- data/ruby_ex/synflow.rb +0 -474
- data/ruby_ex/test/unit/ui/yaml/testrunner.rb +0 -164
- data/ruby_ex/thread_mutex.rb +0 -10
- data/ruby_ex/timeout_ex.rb +0 -81
- data/ruby_ex/top_down.rb +0 -73
- data/ruby_ex/trace.rb +0 -26
- data/ruby_ex/uri/druby.rb +0 -81
- data/ruby_ex/uri/file.rb +0 -65
- data/ruby_ex/uri/ftp_ex.rb +0 -37
- data/ruby_ex/uri/http_ex.rb +0 -43
- data/ruby_ex/uri/ssh.rb +0 -92
- data/ruby_ex/uri/svn.rb +0 -118
- data/ruby_ex/uri_ex.rb +0 -45
- data/ruby_ex/verbose_object.rb +0 -30
- data/ruby_ex/version.rb +0 -66
- data/ruby_ex/yaml/basenode_ext.rb +0 -63
- data/ruby_ex/yaml/chop_header.rb +0 -23
- data/ruby_ex/yaml/transform.rb +0 -449
- data/ruby_ex/yaml/yregexpath.rb +0 -76
- data/src/ask.rb +0 -101
- data/src/changelog.rb +0 -117
- data/src/conflict.rb +0 -20
- data/src/diffstat.rb +0 -42
- data/src/message.rb +0 -64
- data/src/reply-mail.rb +0 -14
- data/src/tools.rb +0 -22
- data/src/vcs.rb +0 -176
data/src/vcs.rb
DELETED
@@ -1,176 +0,0 @@
|
|
1
|
-
# Author:: Nicolas Pouillard <ertai@lrde.epita.fr>.
|
2
|
-
# Copyright:: Copyright (c) 2004 LRDE. All rights reserved.
|
3
|
-
# License:: GNU General Public License (GPL).
|
4
|
-
|
5
|
-
# $LastChangedBy: ertai $
|
6
|
-
# $Id: header 98 2004-09-29 12:07:43Z ertai $
|
7
|
-
|
8
|
-
require 'set'
|
9
|
-
|
10
|
-
class Class # :nodoc:
|
11
|
-
|
12
|
-
def add_basic_method ( meth )
|
13
|
-
class_eval <<-end_eval
|
14
|
-
def #{meth} ( *args )
|
15
|
-
run("#{meth}", *args)
|
16
|
-
end
|
17
|
-
def #{meth}_ ( *args )
|
18
|
-
run("#{meth}", *args)
|
19
|
-
end
|
20
|
-
end_eval
|
21
|
-
end
|
22
|
-
|
23
|
-
def add_basic_method! ( meth )
|
24
|
-
class_eval <<-end_eval
|
25
|
-
def #{meth}! ( *args )
|
26
|
-
run!("#{meth}", *args)
|
27
|
-
end
|
28
|
-
def #{meth}_! ( *args )
|
29
|
-
run!("#{meth}", *args)
|
30
|
-
end
|
31
|
-
end_eval
|
32
|
-
end
|
33
|
-
|
34
|
-
def alias_command ( m1, m2 )
|
35
|
-
class_eval <<-end_eval
|
36
|
-
def #{m1} ( *args )
|
37
|
-
#{m2}(*args)
|
38
|
-
end
|
39
|
-
def #{m1}_ ( *args )
|
40
|
-
#{m2}_(*args)
|
41
|
-
end
|
42
|
-
def #{m1}! ( *args )
|
43
|
-
#{m2}!(*args)
|
44
|
-
end
|
45
|
-
def #{m1}_! ( *args )
|
46
|
-
#{m2}_!(*args)
|
47
|
-
end
|
48
|
-
end_eval
|
49
|
-
end
|
50
|
-
|
51
|
-
end # class Class
|
52
|
-
|
53
|
-
# The abstract class for a Vcs wrapper.
|
54
|
-
# Conventions:
|
55
|
-
# example:
|
56
|
-
# svn checkout http://foo.bar/proj # normal command
|
57
|
-
# xrcs checkout http://foo.bar/proj # normal
|
58
|
-
#
|
59
|
-
# checkout
|
60
|
-
# checkout_
|
61
|
-
# checkout!
|
62
|
-
# checkout_!
|
63
|
-
#
|
64
|
-
class Vcs
|
65
|
-
|
66
|
-
class Failure < Exception
|
67
|
-
end
|
68
|
-
|
69
|
-
def initialize ( aCmd )
|
70
|
-
@cmd = aCmd
|
71
|
-
@handlers = Set.new
|
72
|
-
end
|
73
|
-
|
74
|
-
@@checkers = Set.new
|
75
|
-
|
76
|
-
def common_run ( args )
|
77
|
-
cmd = @cmd + ' "' + args.join('" "') + '"'
|
78
|
-
LOG.debug { "running: #{cmd}" }
|
79
|
-
cmd
|
80
|
-
end
|
81
|
-
private :common_run
|
82
|
-
|
83
|
-
def run ( *args )
|
84
|
-
IO.popen(common_run(args))
|
85
|
-
end
|
86
|
-
|
87
|
-
def run! ( *args )
|
88
|
-
system(common_run(args))
|
89
|
-
end
|
90
|
-
|
91
|
-
%w[ checkout delete diff help status log add update ].each do |m|
|
92
|
-
add_basic_method(m)
|
93
|
-
end
|
94
|
-
|
95
|
-
add_basic_method!(:commit)
|
96
|
-
|
97
|
-
def method_missing ( meth, *args )
|
98
|
-
meth = meth.to_s
|
99
|
-
if meth =~ /^(.*)!$/
|
100
|
-
if respond_to? $1
|
101
|
-
send($1, *args).each do |line|
|
102
|
-
puts line
|
103
|
-
end
|
104
|
-
else
|
105
|
-
LOG.warn { "unknown method #{meth}" }
|
106
|
-
run!($1.sub(/_$/, ''), *args)
|
107
|
-
end
|
108
|
-
else
|
109
|
-
LOG.warn { "unknown method #{meth}" }
|
110
|
-
run(meth.sub(/_$/, ''), *args)
|
111
|
-
end
|
112
|
-
end
|
113
|
-
|
114
|
-
alias_command :ann, :blame
|
115
|
-
alias_command :annotate, :blame
|
116
|
-
alias_command :praise, :blame
|
117
|
-
alias_command :co, :checkout
|
118
|
-
alias_command :ci, :commit
|
119
|
-
alias_command :cp, :copy
|
120
|
-
alias_command :del, :delete
|
121
|
-
alias_command :remove, :delete
|
122
|
-
alias_command :rm, :delete
|
123
|
-
alias_command :di, :diff
|
124
|
-
alias_command :h, :help
|
125
|
-
alias_command :ls, :list
|
126
|
-
alias_command :mv, :move
|
127
|
-
alias_command :rename, :move
|
128
|
-
alias_command :ren, :move
|
129
|
-
alias_command :pdel, :propdel
|
130
|
-
alias_command :pd, :propdel
|
131
|
-
alias_command :pedit, :propedit
|
132
|
-
alias_command :pe, :propedit
|
133
|
-
alias_command :pget, :propget
|
134
|
-
alias_command :pg, :propget
|
135
|
-
alias_command :plist, :proplist
|
136
|
-
alias_command :pl, :proplist
|
137
|
-
alias_command :pset, :propset
|
138
|
-
alias_command :ps, :propset
|
139
|
-
alias_command :st, :status
|
140
|
-
alias_command :stat, :status
|
141
|
-
alias_command :sw, :switch
|
142
|
-
alias_command :up, :update
|
143
|
-
|
144
|
-
# Cvs Alias
|
145
|
-
alias_command :new, :add
|
146
|
-
alias_command :rcs, :admin
|
147
|
-
alias_command :get, :checkout
|
148
|
-
alias_command :rlog, :log
|
149
|
-
alias_command :patch, :rdiff
|
150
|
-
alias_command :remove, :delete
|
151
|
-
alias_command :rm, :delete
|
152
|
-
alias_command :rfreeze, :rtag
|
153
|
-
alias_command :freeze, :tag
|
154
|
-
|
155
|
-
# Prcs Alias
|
156
|
-
alias_command :checkin, :commit
|
157
|
-
alias_command :populate, :add
|
158
|
-
|
159
|
-
def error_handling ( meth )
|
160
|
-
@handlers << meth
|
161
|
-
end
|
162
|
-
|
163
|
-
def call_handlers
|
164
|
-
@handlers.each { |meth| send(meth) }
|
165
|
-
end
|
166
|
-
|
167
|
-
def self.add_conf_checker ( meth )
|
168
|
-
@@checkers << meth
|
169
|
-
end
|
170
|
-
|
171
|
-
def call_conf_checkers
|
172
|
-
@@checkers.each { |meth| send(meth) }
|
173
|
-
end
|
174
|
-
|
175
|
-
end # class Vcs
|
176
|
-
|