crash-watch 1.1.0 → 1.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/bin/crash-watch +6 -0
- data/crash-watch.gemspec +2 -2
- data/lib/crash_watch/gdb_controller.rb +10 -0
- data/lib/crash_watch/version.rb +1 -1
- metadata +7 -7
data/bin/crash-watch
CHANGED
@@ -42,6 +42,12 @@ elsif ARGV.size != 1
|
|
42
42
|
end
|
43
43
|
|
44
44
|
require 'crash_watch/gdb_controller'
|
45
|
+
if !CrashWatch::GdbController.gdb_installed?
|
46
|
+
abort "*** ERROR ***: 'gdb' isn't installed. Please install it first.\n" +
|
47
|
+
" Debian/Ubuntu: sudo apt-get install gdb\n" +
|
48
|
+
"RedHat/CentOS/Fedora: sudo yum install gdb\n" +
|
49
|
+
" Mac OS X: please install the Developer Tools or XCode\n"
|
50
|
+
end
|
45
51
|
gdb = CrashWatch::GdbController.new
|
46
52
|
begin
|
47
53
|
gdb.debug = options[:debug]
|
data/crash-watch.gemspec
CHANGED
@@ -4,7 +4,7 @@ Gem::Specification.new do |s|
|
|
4
4
|
s.name = "crash-watch"
|
5
5
|
s.version = CrashWatch::VERSION_STRING
|
6
6
|
s.authors = ["Hongli Lai"]
|
7
|
-
s.date = "
|
7
|
+
s.date = "2011-03-11"
|
8
8
|
s.description = "Monitor processes and display useful information when they crash."
|
9
9
|
s.summary = "Monitor processes and display useful information when they crash"
|
10
10
|
s.email = "hongli@phusion.nl"
|
@@ -16,7 +16,7 @@ Gem::Specification.new do |s|
|
|
16
16
|
"lib/**/*",
|
17
17
|
"test/**/*"
|
18
18
|
]
|
19
|
-
s.homepage = "
|
19
|
+
s.homepage = "https://github.com/FooBarWidget/crash-watch"
|
20
20
|
s.rdoc_options = ["--charset=UTF-8"]
|
21
21
|
s.executables = ["crash-watch"]
|
22
22
|
s.require_paths = ["lib"]
|
@@ -20,6 +20,16 @@ class GdbController
|
|
20
20
|
|
21
21
|
attr_accessor :debug
|
22
22
|
|
23
|
+
def self.gdb_installed?
|
24
|
+
ENV['PATH'].to_s.split(/:+/).each do |path|
|
25
|
+
filename = "#{path}/gdb"
|
26
|
+
if File.file?(filename) && File.executable?(filename)
|
27
|
+
return true
|
28
|
+
end
|
29
|
+
end
|
30
|
+
return false
|
31
|
+
end
|
32
|
+
|
23
33
|
def initialize
|
24
34
|
@pid, @in, @out = popen_command("gdb", "-n", "-q")
|
25
35
|
execute("set prompt ")
|
data/lib/crash_watch/version.rb
CHANGED
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: crash-watch
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
5
|
-
prerelease:
|
4
|
+
hash: 17
|
5
|
+
prerelease:
|
6
6
|
segments:
|
7
7
|
- 1
|
8
8
|
- 1
|
9
|
-
-
|
10
|
-
version: 1.1.
|
9
|
+
- 1
|
10
|
+
version: 1.1.1
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Hongli Lai
|
@@ -15,7 +15,7 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date:
|
18
|
+
date: 2011-03-11 00:00:00 +01:00
|
19
19
|
default_executable:
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|
@@ -63,7 +63,7 @@ files:
|
|
63
63
|
- lib/crash_watch/version.rb
|
64
64
|
- test/gdb_controller_spec.rb
|
65
65
|
has_rdoc: true
|
66
|
-
homepage:
|
66
|
+
homepage: https://github.com/FooBarWidget/crash-watch
|
67
67
|
licenses: []
|
68
68
|
|
69
69
|
post_install_message:
|
@@ -92,7 +92,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
92
92
|
requirements: []
|
93
93
|
|
94
94
|
rubyforge_project:
|
95
|
-
rubygems_version: 1.
|
95
|
+
rubygems_version: 1.5.2
|
96
96
|
signing_key:
|
97
97
|
specification_version: 3
|
98
98
|
summary: Monitor processes and display useful information when they crash
|