Skip to content

Commit

Permalink
Updated to comply with Chef lint tool foodcritic
Browse files Browse the repository at this point in the history
  • Loading branch information
joevartuli committed Oct 30, 2015
1 parent 79321cd commit 999c445
Show file tree
Hide file tree
Showing 6 changed files with 50 additions and 60 deletions.
24 changes: 21 additions & 3 deletions .gitignore
@@ -1,4 +1,22 @@
*~
#~
.rbx
*.class
*#
.#*
\#*#
.*.sw[a-z]
*.un~
pkg/

# Berkshelf
.vagrant
/cookbooks
Berksfile.lock

# Bundler
Gemfile.lock
bin/*
.bundle/*

.berkshelf
.chef
.kitchen/
.kitchen.local.yml
5 changes: 5 additions & 0 deletions Berksfile
@@ -0,0 +1,5 @@
source 'https://api.berkshelf.com'

metadata

cookbook 'ark'
8 changes: 4 additions & 4 deletions attributes/default.rb
@@ -1,4 +1,4 @@
default[:gradle][:name] = "gradle"
default[:gradle][:version] = "2.8"
default[:gradle][:home_dir] = "/usr/local"
default[:gradle][:release_url] = "http://services.gradle.org/distributions/gradle-#{node[:gradle][:version]}-bin.zip"
default['gradle']['name'] = 'gradle'
default['gradle']['version'] = '2.8'
default['gradle']['home_dir'] = '/usr/local'
default['gradle']['release_url'] = "http://services.gradle.org/distributions/gradle-#{node['gradle']['version']}-bin.zip"
33 changes: 0 additions & 33 deletions metadata.json

This file was deleted.

15 changes: 8 additions & 7 deletions metadata.rb
@@ -1,9 +1,10 @@
name "gradle"
maintainer "Michael S. Klishin"
maintainer_email "michael@clojurewerkz.org"
license "MIT"
name 'gradle'
maintainer 'Michael S. Klishin'
maintainer_email 'michael@clojurewerkz.org'
license 'MIT'
description 'Installs Gradle'
long_description IO.read(File.join(File.dirname(__FILE__), 'README.md'))
version "1.0.0"
description "Installs Gradle"
recipe "gradle::tarball", "installs gradle from tarball"
recipe 'gradle::tarball', 'installs gradle from tarball'
version '1.0.0'

depends 'ark', '>= 0.0.0'
25 changes: 12 additions & 13 deletions recipes/tarball.rb
Expand Up @@ -22,19 +22,18 @@

include_recipe 'ark'

ark node[:gradle][:name] do
url node[:gradle][:release_url]
version node[:gradle][:version]
prefix_home node[:gradle][:home_dir]
prefix_root node[:gradle][:home_dir]
prefix_bin "#{node[:gradle][:home_dir]}/bin"
action :install
end
ark node['gradle']['name'] do
url node['gradle']['release_url']
version node['gradle']['version']
prefix_home node['gradle']['home_dir']
prefix_root node['gradle']['home_dir']
prefix_bin "#{node['gradle']['home_dir']}/bin"
action :install
end

cookbook_file "/etc/profile.d/gradle.sh" do
owner "root"
group "root"
cookbook_file '/etc/profile.d/gradle.sh' do
owner 'root'
group 'root'
mode 0644

source "etc/profile.d/gradle.sh"
source 'etc/profile.d/gradle.sh'
end

0 comments on commit 999c445

Please sign in to comment.