fulmar-shell 1.1.2 → 1.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/fulmar/shell.rb +7 -2
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4b1eecbc826fbdf7fb94816509ec2d7a21eb66ad
|
4
|
+
data.tar.gz: 7eab24649e0767fe10006485d54cd0b23ed8e705
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: bb282a8e9b650419a62981e5cca6eac1a219bd752a6b105e2ef8400dd98dd3951d9a7789b699b8b18adb69ec7d0a30f97b1adbd44e330c6bedf11ee0134c312e
|
7
|
+
data.tar.gz: 57e25a5635a7bc7d765c11eccfb9fb6c0335051ec9a79bd045c9770c5ce4b7efb16f3873faf32c012e184a37044db6585f8e917f75934e9ed9263b470fc074d7
|
data/lib/fulmar/shell.rb
CHANGED
@@ -5,12 +5,13 @@ require 'open3'
|
|
5
5
|
module Fulmar
|
6
6
|
# Implements simple access to shell commands
|
7
7
|
class Shell
|
8
|
-
VERSION = '1.
|
8
|
+
VERSION = '1.2.0'
|
9
9
|
|
10
10
|
attr_accessor :debug, :last_output, :last_error, :quiet
|
11
|
+
attr_reader :path
|
11
12
|
|
12
13
|
def initialize(path, host = 'localhost')
|
13
|
-
@path = (path.nil? || path.empty?) ? '.' : path
|
14
|
+
@path = File.expand_path((path.nil? || path.empty?) ? '.' : path)
|
14
15
|
@host = host
|
15
16
|
@last_output = []
|
16
17
|
@last_error = []
|
@@ -35,6 +36,10 @@ module Fulmar
|
|
35
36
|
@host == 'localhost'
|
36
37
|
end
|
37
38
|
|
39
|
+
def path=(path)
|
40
|
+
@path = File.expand_path(path)
|
41
|
+
end
|
42
|
+
|
38
43
|
protected
|
39
44
|
|
40
45
|
# Run the command and capture the output
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fulmar-shell
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gerrit Visscher
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-03-
|
11
|
+
date: 2015-03-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|