specinfra 1.27.3 → 1.27.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 355b5a2e8127dd8307a13dd3448aae847ccd7695
4
- data.tar.gz: e1cb6ddf6b727a8c24487f7eae112184f37c3611
3
+ metadata.gz: bb53bcdc6b8fa3bcf2763e9c321e3868d770a96a
4
+ data.tar.gz: 26af8d172a50207a96074ffdb70faef4243d4179
5
5
  SHA512:
6
- metadata.gz: 23ebf9e8ff3712c0d2a497b70e44f6a68f7491f5dcaf798885524c58c004c78804a95fb722e980d5d174f81c0c3d071ede2a58293fdc2995039fc5bbd9dc8cf5
7
- data.tar.gz: a390eeb4e2f959ea5fa4cb7e1c286ab12fd6d2905523b8a4cbf529e6cb3fcda6d8663adfc2ab0c9861a728e666c41906c0fa13691115d1632a6a1b335f09013f
6
+ metadata.gz: 8e3cd40dd560d850666b03dccadbe4a6a16899603c8417739424e7701ba79ebafde2a902e7f94f883c16e4d5a8a7c979ec9c4c1cf6bc291c2c5fd3d384229655
7
+ data.tar.gz: 0f5d3ea9248909408d62ab2f48d15996e17e54efe84e123e9396300365388790fa29e712908cb03454a2e78e93ac487c2b81efb6f8b77c6f41240891b8168706
@@ -7,7 +7,7 @@ module SpecInfra
7
7
 
8
8
  def check_enabled(service, level)
9
9
  level = "multi-user.target" if level == 3
10
- "systemctl --plain list-dependencies #{level} | grep '^#{escape(service)}.service$'"
10
+ "systemctl --plain list-dependencies #{level} | grep '^● #{escape(service)}.service$'"
11
11
  end
12
12
 
13
13
  def check_running(service)
@@ -16,12 +16,12 @@ module SpecInfra
16
16
 
17
17
  def check_installed(package,version=nil)
18
18
  if version
19
- "pacman -Q | grep #{escape(package)} #{escape(version)}"
19
+ grep = version.include?('-') ? "^#{escape(version)}$" : "^#{escape(version)}-"
20
+ "pacman -Q #{escape(package)} | awk '{print $2}' | grep '#{grep}'"
20
21
  else
21
- "pacman -Q | grep #{escape(package)}"
22
+ "pacman -Q #{escape(package)}"
22
23
  end
23
24
  end
24
-
25
25
  def sync_repos
26
26
  "pacman -Syy"
27
27
  end
@@ -1,3 +1,3 @@
1
1
  module SpecInfra
2
- VERSION = "1.27.3"
2
+ VERSION = "1.27.4"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: specinfra
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.27.3
4
+ version: 1.27.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gosuke Miyashita
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-09-24 00:00:00.000000000 Z
11
+ date: 2014-09-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler