itamae-plugin-resource-cask 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/itamae-plugin-resource-cask.gemspec +1 -1
- data/lib/itamae/plugin/resource/cask.rb +3 -5
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2d76b9f9a04dfc2df27c641876731d30cefd9fca
|
4
|
+
data.tar.gz: d4d4315679f0f40c6d409d8a140943552ba2ec25
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 55f6ec36dc52c308845d3e9f0ba9837f629331f1254889c9dd2d1d1a4bde866deb816012b9f7062876240b148a7835337f0e201a15e29c087f3118ef1c7cbf6f
|
7
|
+
data.tar.gz: b3c756524d4ed5de154a54e749a9c7a0b8d6eef6a930b4943d78fdad860d1f1c91956ef070fe435db07f355269a4d3970702d67244e06b77ea40c73f9e6bd109
|
@@ -4,7 +4,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
|
4
4
|
|
5
5
|
Gem::Specification.new do |spec|
|
6
6
|
spec.name = "itamae-plugin-resource-cask"
|
7
|
-
spec.version = "0.2.
|
7
|
+
spec.version = "0.2.1"
|
8
8
|
spec.authors = ["Takashi Kokubun"]
|
9
9
|
spec.email = ["takashikkbn@gmail.com"]
|
10
10
|
spec.summary = %q{Itamae resource plugin to manage homebrew cask packages.}
|
@@ -4,8 +4,6 @@ module Itamae
|
|
4
4
|
module Plugin
|
5
5
|
module Resource
|
6
6
|
class Cask < Itamae::Resource::Base
|
7
|
-
BREW_CASK = 'brew-cask'
|
8
|
-
|
9
7
|
define_attribute :action, default: :install
|
10
8
|
define_attribute :target, type: String, default_name: true
|
11
9
|
define_attribute :options, type: String, default: "--appdir=/Applications"
|
@@ -20,12 +18,12 @@ module Itamae
|
|
20
18
|
|
21
19
|
def action_install(options)
|
22
20
|
unless current.exist
|
23
|
-
run_command([
|
21
|
+
run_command(["brew", "cask", "install", attributes.target])
|
24
22
|
end
|
25
23
|
end
|
26
24
|
|
27
25
|
def action_alfred(options)
|
28
|
-
run_command([
|
26
|
+
run_command(["brew", "cask", "alfred", attributes.target])
|
29
27
|
end
|
30
28
|
|
31
29
|
private
|
@@ -36,7 +34,7 @@ module Itamae
|
|
36
34
|
end
|
37
35
|
|
38
36
|
def ensure_brew_cask_availability
|
39
|
-
if run_command("
|
37
|
+
if run_command("test -d $(brew --prefix)/Library/Taps/caskroom/homebrew-cask", error: false).exit_status != 0
|
40
38
|
raise "`brew cask` command is not available. Please install brew cask."
|
41
39
|
end
|
42
40
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: itamae-plugin-resource-cask
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Takashi Kokubun
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-12-
|
11
|
+
date: 2015-12-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -86,7 +86,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
86
86
|
version: '0'
|
87
87
|
requirements: []
|
88
88
|
rubyforge_project:
|
89
|
-
rubygems_version: 2.
|
89
|
+
rubygems_version: 2.5.1
|
90
90
|
signing_key:
|
91
91
|
specification_version: 4
|
92
92
|
summary: Itamae resource plugin to manage homebrew cask packages.
|