pkgforge 0.23.0 → 0.23.1

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
  SHA256:
3
- metadata.gz: 4db24a133a9a688a92dfbc9017cba8cdde98123bc2b7bb88d94352bc3ed4b0a8
4
- data.tar.gz: d75cd94be6a0ea2014da074c92958f6dbd044a02f9c7dd823b124cff3ea2a938
3
+ metadata.gz: 3a46943190b3aa875e389d9ce5732e5c4976403a8941df0ad0f0e7c02624b074
4
+ data.tar.gz: 32c019a9e8494e3f39a5655ad07b77695f2678ee48e1d05e9189bbe586143b26
5
5
  SHA512:
6
- metadata.gz: 2d2147a2fd21bc1fb1453acdc2de4df6cac77bf2e9046cd18ebe9c2f7653b52278268ac14017f835723c51578cfb3fe7411b4d10b91853bbc1c6a5b99f6810eb
7
- data.tar.gz: 4969fbe5fa550a486fb1854b14e49c78f2c6bfc5ae43620fb5d88e5092024aad9f43157de3a1ee0290a4318f2b3e6e5739ad37dbd287daae18b6cbedff0bd5e9
6
+ metadata.gz: 767547559d88d2f051d65c2f386c77842e6cdd9e7cae2952dd4315741a462f231e767d56a42626a8afd97f08ca80feaf8376550b0bb6964efd4c4487bf8d79b9
7
+ data.tar.gz: 8ee83d04bd3bebed48430a2d78b0b9ed56287b16bc1f68e6b726cff74558606243df7320c92af4c41b258bddc763d9cd0ff7fa4a6bd39da49f241d83ddbeb8b5
data/.circle-ruby CHANGED
@@ -1,4 +1,3 @@
1
1
  2.5.1
2
2
  2.4.4
3
3
  2.3.7
4
- 2.2.10
data/.prospectus CHANGED
@@ -1,11 +1,11 @@
1
1
  my_slug = 'akerl/pkgforge'
2
2
 
3
- Prospectus.extra_dep('file', 'prospectus_circleci')
3
+ Prospectus.extra_dep('file', 'prospectus_travis')
4
4
  Prospectus.extra_dep('file', 'prospectus_gems')
5
5
 
6
6
  item do
7
7
  noop
8
8
 
9
9
  extend ProspectusGems::Gemspec.new
10
- extend ProspectusCircleci::Build.new(my_slug)
10
+ extend ProspectusTravis::Build.new(my_slug)
11
11
  end
data/.travis.yml ADDED
@@ -0,0 +1,10 @@
1
+ dist: trusty
2
+ install:
3
+ - for i in $(cat .circle-ruby) ; do rvm install $i || exit 1 ; done
4
+ - for i in $(cat .circle-ruby) ; do rvm-exec $i bundle install || exit 1 ; done
5
+ script:
6
+ - for i in $(cat .circle-ruby) ; do rvm-exec $i bundle exec rake || exit 1 ; done
7
+ notifications:
8
+ email: false
9
+ slack:
10
+ secure: hiSpJYwTPJUSw9aS2AG28isKW8Sel209yOVRRwr5U0LV5XLsiMCIHjc8sUPliTIcHNEZgBkoBdVe9cEMpcIwV5oeHWJi/tPt0dMISJ5P8K1mG0i2ULk5Up7vOUDN0WctL8CzhiGCcMr/H1lk3VbHKsxgcozIitnocCIwZuswJqNwu2XpkRw5xxVIMAK9tIZGfH+XMwFZcLghQsAF55fHyKYUVVI5n7PMLVbiDY8u9cVlZKL4qa3dBuus903f/zPGSJXbLcPqnVbuyOlIewxSNaPDX7YjIAdgkNk4IE+gCO82FnNpkWqVdtGT8Nx0PLOkt5FICl7aBFjIanFV1NnMo7qVXj0XNRdIoMBqx5T3WKp9k1EaYnaZwDax1zEDamyUSikwc0BPjnW1gZX5Hv6bQAVMWoXIZz9xJVd1Opv2sH1v534e+eCdcqHBv5sIFbYofeN3KvBEfdFBE4YHorT0u/rtBOBoNBVwrstjvNs3W9CbGqgubH2JUtCky2W+4mXwpmndXTYG8DZkMZ7YCqlQYgJLyPuLdxUjSz6IdMVaz/g8c5/d71jlJuiBl+VX6vFMmtec0/e9ivwH5RhkcsYrGw6dkKh3qymmdoHgc65K5dOLluNvZf/AQyInVXZAivKb2ppIW1t9pjaWN2wX6hEP7Vb8516OwJYzuGHUJFrBpUY=
data/README.md CHANGED
@@ -2,8 +2,7 @@ pkgforge
2
2
  =========
3
3
 
4
4
  [![Gem Version](https://img.shields.io/gem/v/pkgforge.svg)](https://rubygems.org/gems/pkgforge)
5
- [![Dependency Status](https://img.shields.io/gemnasium/akerl/pkgforge.svg)](https://gemnasium.com/akerl/pkgforge)
6
- [![Build Status](https://img.shields.io/circleci/project/akerl/pkgforge/master.svg)](https://circleci.com/gh/akerl/pkgforge)
5
+ [![Build Status](https://img.shields.io/travis/com/akerl/pkgforge.svg)](https://travis-ci.com/akerl/pkgforge)
7
6
  [![Coverage Status](https://img.shields.io/codecov/c/github/akerl/pkgforge.svg)](https://codecov.io/github/akerl/pkgforge)
8
7
  [![Code Quality](https://img.shields.io/codacy/fb7636f572b04067801ac9024ed71228.svg)](https://www.codacy.com/app/akerl/pkgforge)
9
8
  [![MIT Licensed](https://img.shields.io/badge/license-MIT-green.svg)](https://tldrlegal.com/license/mit-license)
@@ -17,7 +17,7 @@ module PkgForge
17
17
  patch_source!
18
18
  prepare_deps!
19
19
  builder = PkgForge::DSL::Build.new(self)
20
- builder.instance_eval(&build_block)
20
+ Dir.chdir(tmpdir(:build)) { builder.instance_eval(&build_block) }
21
21
  nil
22
22
  end
23
23
  end
@@ -70,7 +70,7 @@ module PkgForge
70
70
 
71
71
  Contract String, String => nil
72
72
  def extract_file(file, dir)
73
- run_local "tar -x -C #{dir} -f #{file}"
73
+ run "tar -x -C #{dir} -f #{file}"
74
74
  end
75
75
 
76
76
  Contract None => nil
@@ -23,6 +23,11 @@ module PkgForge
23
23
 
24
24
  private
25
25
 
26
+ Contract None => nil
27
+ def noop_prepare_package
28
+ nil
29
+ end
30
+
26
31
  Contract None => nil
27
32
  def file_prepare_package
28
33
  artifacts = package[:artifacts] || [package[:artifact]].compact
@@ -47,7 +52,7 @@ module PkgForge
47
52
  Contract None => nil
48
53
  def make_tarball!
49
54
  Dir.chdir(tmpdir(:release)) do
50
- run_local "tar -czvf #{tmpfile(:tarball)} *"
55
+ run "tar -czvf #{tmpfile(:tarball)} *"
51
56
  end
52
57
  nil
53
58
  end
@@ -11,7 +11,7 @@ module PkgForge
11
11
 
12
12
  Contract String => nil
13
13
  def run_patch(file)
14
- run_local "patch -d #{tmpdir(:build)} -p1 < patches/#{file}"
14
+ run "patch -d #{tmpdir(:build)} -p1 < patches/#{file}"
15
15
  end
16
16
 
17
17
  private
@@ -3,17 +3,7 @@ module PkgForge
3
3
  # Add run methods to Forge
4
4
  class Forge
5
5
  Contract Or[String, Array], Or[HashOf[String => String], {}, nil] => nil
6
- def run(*args)
7
- Dir.chdir(tmpdir(:build)) do
8
- run_local(*args)
9
- end
10
- nil
11
- end
12
-
13
- private
14
-
15
- Contract Or[String, Array], Or[HashOf[String => String], {}, nil] => nil
16
- def run_local(cmd, env = {})
6
+ def run(cmd, env = {})
17
7
  puts "Running command in #{Dir.pwd}: #{cmd}"
18
8
  puts "Using env: #{env}" unless env.empty?
19
9
  res = system env, *cmd
@@ -23,8 +23,8 @@ module PkgForge
23
23
 
24
24
  Contract None => nil
25
25
  def git_prepare_source
26
- run_local 'git submodule update --init --recursive'
27
- run_local "git clone --recursive '#{source[:path]}' #{tmpdir(:build)}"
26
+ run 'git submodule update --init --recursive'
27
+ run "git clone --recursive '#{source[:path]}' #{tmpdir(:build)}"
28
28
  end
29
29
 
30
30
  Contract None => nil
@@ -14,7 +14,7 @@ module PkgForge
14
14
  Contract None => nil
15
15
  def test!
16
16
  tester = PkgForge::DSL::Test.new(self)
17
- tester.instance_eval(&test_block)
17
+ Dir.chdir(tmpdir(:release)) { tester.instance_eval(&test_block) }
18
18
  nil
19
19
  end
20
20
 
@@ -24,9 +24,7 @@ module PkgForge
24
24
  cmd.prepend('/usr/bin/env ') if cmd.is_a? String
25
25
  env['PATH'] ||= './usr/bin'
26
26
  lib_override do
27
- Dir.chdir(tmpdir(:release)) do
28
- run_local(cmd, env)
29
- end
27
+ run(cmd, env)
30
28
  end
31
29
  end
32
30
 
@@ -43,7 +43,7 @@ module PkgForge
43
43
  args += ['--name', artifact[:name]]
44
44
  args += ['--endpoint', endpoint] if endpoint
45
45
  args += ["#{org}/#{name}", version, artifact[:source]]
46
- run_local args
46
+ run args
47
47
  end
48
48
  nil
49
49
  end
@@ -1,5 +1,5 @@
1
1
  ##
2
2
  # Declare version number
3
3
  module PkgForge
4
- VERSION = '0.23.0'.freeze
4
+ VERSION = '0.23.1'.freeze
5
5
  end
data/pkgforge.gemspec CHANGED
@@ -24,8 +24,8 @@ Gem::Specification.new do |s|
24
24
 
25
25
  s.add_development_dependency 'codecov', '~> 0.1.1'
26
26
  s.add_development_dependency 'fuubar', '~> 2.3.0'
27
- s.add_development_dependency 'goodcop', '~> 0.5.0'
27
+ s.add_development_dependency 'goodcop', '~> 0.6.0'
28
28
  s.add_development_dependency 'rake', '~> 12.3.0'
29
- s.add_development_dependency 'rspec', '~> 3.7.0'
30
- s.add_development_dependency 'rubocop', '~> 0.57.1'
29
+ s.add_development_dependency 'rspec', '~> 3.8.0'
30
+ s.add_development_dependency 'rubocop', '~> 0.59.0'
31
31
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pkgforge
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.23.0
4
+ version: 0.23.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Les Aker
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-06-22 00:00:00.000000000 Z
11
+ date: 2018-09-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: contracts
@@ -86,14 +86,14 @@ dependencies:
86
86
  requirements:
87
87
  - - "~>"
88
88
  - !ruby/object:Gem::Version
89
- version: 0.5.0
89
+ version: 0.6.0
90
90
  type: :development
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
94
  - - "~>"
95
95
  - !ruby/object:Gem::Version
96
- version: 0.5.0
96
+ version: 0.6.0
97
97
  - !ruby/object:Gem::Dependency
98
98
  name: rake
99
99
  requirement: !ruby/object:Gem::Requirement
@@ -114,28 +114,28 @@ dependencies:
114
114
  requirements:
115
115
  - - "~>"
116
116
  - !ruby/object:Gem::Version
117
- version: 3.7.0
117
+ version: 3.8.0
118
118
  type: :development
119
119
  prerelease: false
120
120
  version_requirements: !ruby/object:Gem::Requirement
121
121
  requirements:
122
122
  - - "~>"
123
123
  - !ruby/object:Gem::Version
124
- version: 3.7.0
124
+ version: 3.8.0
125
125
  - !ruby/object:Gem::Dependency
126
126
  name: rubocop
127
127
  requirement: !ruby/object:Gem::Requirement
128
128
  requirements:
129
129
  - - "~>"
130
130
  - !ruby/object:Gem::Version
131
- version: 0.57.1
131
+ version: 0.59.0
132
132
  type: :development
133
133
  prerelease: false
134
134
  version_requirements: !ruby/object:Gem::Requirement
135
135
  requirements:
136
136
  - - "~>"
137
137
  - !ruby/object:Gem::Version
138
- version: 0.57.1
138
+ version: 0.59.0
139
139
  description: DSL engine for building Arch packages
140
140
  email: me@lesaker.org
141
141
  executables:
@@ -148,12 +148,12 @@ files:
148
148
  - ".prospectus"
149
149
  - ".rspec"
150
150
  - ".rubocop.yml"
151
+ - ".travis.yml"
151
152
  - Gemfile
152
153
  - LICENSE
153
154
  - README.md
154
155
  - Rakefile
155
156
  - bin/pkgforge
156
- - circle.yml
157
157
  - lib/pkgforge.rb
158
158
  - lib/pkgforge/base.rb
159
159
  - lib/pkgforge/components/build.rb
data/circle.yml DELETED
@@ -1,7 +0,0 @@
1
- dependencies:
2
- override:
3
- - 'for i in $(cat .circle-ruby) ; do rvm-exec $i gem update --system --no-doc || exit 1 ; done'
4
- - 'for i in $(cat .circle-ruby) ; do rvm-exec $i bundle install || exit 1 ; done'
5
- test:
6
- override:
7
- - 'for i in $(cat .circle-ruby) ; do rvm-exec $i bundle exec rake || exit 1 ; done'