milkode 0.1.3 → 0.1.4

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,3 +1,7 @@
1
+ === 0.1.4 2011/08/01
2
+
3
+ * To act reasonably even if it fails to require 'readline'.
4
+
1
5
  === 0.1.3 2011/07/30
2
6
 
3
7
  * Change Icon.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.1.3
1
+ 0.1.4
data/bin/milk CHANGED
@@ -6,5 +6,5 @@
6
6
  require 'rubygems'
7
7
  require 'milkode/cdstk/cli_cdstk'
8
8
 
9
- Version = "0.1.3"
9
+ Version = "0.1.4"
10
10
  Milkode::CLI_Cdstk.execute(STDOUT, ARGV)
@@ -11,7 +11,11 @@ require 'milkode/common/grenfiletest'
11
11
  require 'milkode/common/util'
12
12
  include Milkode
13
13
  require 'kconv'
14
- require 'readline'
14
+ begin
15
+ require 'readline'
16
+ rescue LoadError
17
+ $no_readline = true
18
+ end
15
19
  require 'milkode/cdweb/lib/database'
16
20
  require 'open-uri'
17
21
 
@@ -200,7 +204,12 @@ module Milkode
200
204
  end
201
205
 
202
206
  def yes_or_no(msg)
203
- @out.puts msg
207
+ if ($no_readline)
208
+ @out.puts "Pass Cdstk#yes_or_no, because fail \"require 'readline'\"."
209
+ return true
210
+ end
211
+
212
+ @out.puts msg
204
213
  while buf = Readline.readline("> ")
205
214
  case buf
206
215
  when 'yes'
@@ -18,7 +18,7 @@ require 'milkode/cdweb/lib/mkurl'
18
18
  set :haml, :format => :html5
19
19
 
20
20
  get '/' do
21
- @version = "0.1.3"
21
+ @version = "0.1.4"
22
22
  @package_num = Database.instance.fileList('').size
23
23
  @file_num = Database.instance.fileNum
24
24
  haml :index
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{milkode}
8
- s.version = "0.1.3"
8
+ s.version = "0.1.4"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["ongaeshi"]
12
- s.date = %q{2011-07-30}
12
+ s.date = %q{2011-08-01}
13
13
  s.description = %q{Line based local source code search engine & web-app.}
14
14
  s.email = %q{ongaeshi0621@gmail.com}
15
15
  s.executables = ["cdv", "milk", "cdview"]
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 1
8
- - 3
9
- version: 0.1.3
8
+ - 4
9
+ version: 0.1.4
10
10
  platform: ruby
11
11
  authors:
12
12
  - ongaeshi
@@ -14,7 +14,7 @@ autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
16
 
17
- date: 2011-07-30 00:00:00 +09:00
17
+ date: 2011-08-01 00:00:00 +09:00
18
18
  default_executable:
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency