serverkit-go 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 5ff7cbedd6a3e5951cc2203f0a2af726d50a041f
4
+ data.tar.gz: 6ac81ddbe547095a1a519ee11e07aa485af82b4e
5
+ SHA512:
6
+ metadata.gz: 3b3a35a63efbbf272a2c3eb14847992079c9bb6eb6d2f21363a74cec78cfd5ad216c63ea9efd275b4c6db7f8e8a9f3cb5bb4e91e630511a2329605eb6a3dd0eb
7
+ data.tar.gz: 15c1b8447f3bb8942aaf3bba7970db8fe02ecffaa33d3f018b46785502de78ad8c155400dcca9b282bd6a4386912573ec33609fa9669c3e0357361b7ff9e5e03
data/.gitignore ADDED
@@ -0,0 +1,10 @@
1
+ /.bundle/
2
+ /vendor
3
+ /.yardoc
4
+ /Gemfile.lock
5
+ /_yardoc/
6
+ /coverage/
7
+ /doc/
8
+ /pkg/
9
+ /spec/reports/
10
+ /tmp/
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in serverkit-go.gemspec
4
+ gemspec
data/LICENSE ADDED
@@ -0,0 +1,22 @@
1
+ Copyright (c) 2015 Tomohiro TAIRA
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,56 @@
1
+ serverkit-go
2
+ ================================================================================
3
+
4
+ [Serverkit](https://github.com/serverkit/serverkit) plug-in for Go package.
5
+
6
+
7
+ Installation
8
+ --------------------------------------------------------------------------------
9
+
10
+ ### Bundler
11
+
12
+ ```ruby
13
+ # Gemfile
14
+ gem 'serverkit-go'
15
+ ```
16
+
17
+
18
+ ### RubyGems
19
+
20
+ ```
21
+ $ gem install serverkit-go
22
+ ```
23
+
24
+
25
+ Usage
26
+ --------------------------------------------------------------------------------
27
+
28
+ ### Install a Go package
29
+
30
+ Use `go_package` resource in your serverkit recipe:
31
+
32
+ ```yaml
33
+ resources:
34
+ - type: go_package
35
+ path: golang.org/x/tools/cmd/godoc
36
+ ```
37
+
38
+
39
+ Resource
40
+ --------------------------------------------------------------------------------
41
+
42
+ ### go_package
43
+
44
+ Install specified Go package.
45
+
46
+ #### Attributes
47
+
48
+ - path - Path of the package (required)
49
+
50
+
51
+ LICENSE
52
+ --------------------------------------------------------------------------------
53
+
54
+ © 2015 Tomohiro TAIRA.
55
+
56
+ This project is licensed under the MIT license. See [LICENSE](LICENSE) for details.
data/Rakefile ADDED
@@ -0,0 +1 @@
1
+ require 'bundler/gem_tasks'
@@ -0,0 +1,2 @@
1
+ require 'serverkit/go/version'
2
+ require 'serverkit/resources/go_package'
@@ -0,0 +1,5 @@
1
+ module Serverkit
2
+ module Go
3
+ VERSION = '1.0.0'
4
+ end
5
+ end
@@ -0,0 +1,22 @@
1
+ require 'serverkit/resources/base'
2
+
3
+ module Serverkit
4
+ module Resources
5
+ class GoPackage < Base
6
+ attribute :path, required: true, type: String
7
+
8
+ # @note Override
9
+ def apply
10
+ run_command("go get -u #{path}")
11
+ end
12
+
13
+ # @note Override
14
+ def check
15
+ go_package_path = "#{ENV['GOPATH']}/src/#{path}"
16
+ check_command(
17
+ backend.command.get(:check_file_is_directory, go_package_path)
18
+ )
19
+ end
20
+ end
21
+ end
22
+ end
@@ -0,0 +1,23 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'serverkit/go/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = 'serverkit-go'
8
+ spec.version = Serverkit::Go::VERSION
9
+ spec.authors = ['Tomohiro TAIRA']
10
+ spec.email = ['tomohiro.t@gmail.com']
11
+
12
+ spec.summary = %q{Serverkit plug-in for Go package}
13
+ spec.description = %q{Serverkit plug-in for Go package}
14
+ spec.homepage = 'https://github.com/Tomohiro/serverkit-go'
15
+ spec.license = 'MIT'
16
+
17
+ spec.files = `git ls-files -z`.split("\x0")
18
+ spec.require_paths = ['lib']
19
+
20
+ spec.add_runtime_dependency 'serverkit', '~> 0.6.5'
21
+ spec.add_development_dependency 'bundler', '~> 1.10'
22
+ spec.add_development_dependency 'rake', '~> 10.0'
23
+ end
metadata ADDED
@@ -0,0 +1,95 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: serverkit-go
3
+ version: !ruby/object:Gem::Version
4
+ version: 1.0.0
5
+ platform: ruby
6
+ authors:
7
+ - Tomohiro TAIRA
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2015-12-01 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: serverkit
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: 0.6.5
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: 0.6.5
27
+ - !ruby/object:Gem::Dependency
28
+ name: bundler
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '1.10'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '1.10'
41
+ - !ruby/object:Gem::Dependency
42
+ name: rake
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '10.0'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '10.0'
55
+ description: Serverkit plug-in for Go package
56
+ email:
57
+ - tomohiro.t@gmail.com
58
+ executables: []
59
+ extensions: []
60
+ extra_rdoc_files: []
61
+ files:
62
+ - ".gitignore"
63
+ - Gemfile
64
+ - LICENSE
65
+ - README.md
66
+ - Rakefile
67
+ - lib/serverkit/go.rb
68
+ - lib/serverkit/go/version.rb
69
+ - lib/serverkit/resources/go_package.rb
70
+ - serverkit-go.gemspec
71
+ homepage: https://github.com/Tomohiro/serverkit-go
72
+ licenses:
73
+ - MIT
74
+ metadata: {}
75
+ post_install_message:
76
+ rdoc_options: []
77
+ require_paths:
78
+ - lib
79
+ required_ruby_version: !ruby/object:Gem::Requirement
80
+ requirements:
81
+ - - ">="
82
+ - !ruby/object:Gem::Version
83
+ version: '0'
84
+ required_rubygems_version: !ruby/object:Gem::Requirement
85
+ requirements:
86
+ - - ">="
87
+ - !ruby/object:Gem::Version
88
+ version: '0'
89
+ requirements: []
90
+ rubyforge_project:
91
+ rubygems_version: 2.4.5.1
92
+ signing_key:
93
+ specification_version: 4
94
+ summary: Serverkit plug-in for Go package
95
+ test_files: []