motion-sparkle-sandbox 2.0.1 → 2.1.0

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: cc179192e7aeb944a8e61d76dca931f1a3677d609f66cc07d0cce265fb3a528c
4
- data.tar.gz: fc45702a1cd7854e82bd73f90e90d76c824cea414dc5b67235eacf5843ea34cf
3
+ metadata.gz: df7c1845f67138c6774aab881d396058ee2041c1ed541ba0cc824bb48fac8839
4
+ data.tar.gz: eaaa9add1f9755ebf2858da7ee56781836c5aeb63cddb4483f2326ad7c5751bc
5
5
  SHA512:
6
- metadata.gz: ca8d5068be44227353ca57f476680f54c636006ae17b81766bfaf527c5ca8c51a5b5037284b370edcd9c6f951b3a151d97af794924ee51185d9ecd93bdf6bf95
7
- data.tar.gz: a30fa432e5d62eaa32f3da2d24fd63ce28b3a4c5b3eef9de14765fdd0d69d64a14bb9037fb6217368f5f0e3bf2ef3418c408341ffc949a81cfa45efabbd40d28
6
+ metadata.gz: 47b4434bdfdaa48004bdd4e70f4c1608548c204b001246609a8a25356aa9f5cbad502e6b0c14198e1161a0d319599b53361fb25f6de1284e0553914c13f9db96
7
+ data.tar.gz: 62a6a7bbee1cd82ebc2a414300db3d0307b75a052c9d480167cefc5401182cff2adcb7394eb119d2d7eafac52b7c2fb3bca6e9f31cc3d15fea2b9656691d58e1
data/README.md CHANGED
@@ -34,11 +34,11 @@ After building your app for release and running `rake sparkle:package`, all you
34
34
 
35
35
  - Use the latest version of **motion-sparkle-sandbox**
36
36
  - You will need RubyMotion version 5.0 or above
37
- - Sparkle 2 now requires Mac OS X 10.11 El Capitan) or later
37
+ - Sparkle 2 now requires Mac OS X 10.11 (El Capitan) or later
38
38
 
39
39
  ## Installation
40
40
 
41
- In your project's Gemfile, add:
41
+ In your project's `Gemfile`, add:
42
42
 
43
43
  ```ruby
44
44
  # Gemfile
@@ -104,8 +104,6 @@ If everything is OK, you should be informed that it's time to generate or config
104
104
 
105
105
  For security, Sparkle 2 allows you to sign your releases with a private certificate before distribution: when the user tries to install an update, Sparkle 2 will check the package using the signature provided in the XML file and the public certificate contained in the running application.
106
106
 
107
- _Currently, `motion-sparkle-sandbox` does not support configuring `EdDSA` signatures, only `DSA`._
108
-
109
107
  `motion-sparkle-sandbox` makes it very easy to handle this. In fact, after the first setup, it becomes completely transparent to you as all is handled when you run `rake sparkle:package`.
110
108
 
111
109
  You have two options: have Sparkle 2 generate the certificates for you, or follow the instructions to use your existing ones.
data/bin/bundle CHANGED
@@ -8,46 +8,46 @@
8
8
  # this file is here to facilitate running it.
9
9
  #
10
10
 
11
- require 'rubygems'
11
+ require "rubygems"
12
12
 
13
13
  m = Module.new do
14
- module_function
14
+ module_function
15
15
 
16
16
  def invoked_as_script?
17
17
  File.expand_path($0) == File.expand_path(__FILE__)
18
18
  end
19
19
 
20
20
  def env_var_version
21
- ENV['BUNDLER_VERSION']
21
+ ENV["BUNDLER_VERSION"]
22
22
  end
23
23
 
24
24
  def cli_arg_version
25
25
  return unless invoked_as_script? # don't want to hijack other binstubs
26
- return unless 'update'.start_with?(ARGV.first || ' ') # must be running `bundle update`
27
-
26
+ return unless "update".start_with?(ARGV.first || " ") # must be running `bundle update`
28
27
  bundler_version = nil
29
28
  update_index = nil
30
29
  ARGV.each_with_index do |a, i|
31
- bundler_version = a if update_index && update_index.succ == i && a =~ Gem::Version::ANCHORED_VERSION_PATTERN
30
+ if update_index && update_index.succ == i && a =~ Gem::Version::ANCHORED_VERSION_PATTERN
31
+ bundler_version = a
32
+ end
32
33
  next unless a =~ /\A--bundler(?:[= ](#{Gem::Version::VERSION_PATTERN}))?\z/
33
-
34
- bundler_version = Regexp.last_match(1) || '>= 0.a'
34
+ bundler_version = $1 || ">= 0.a"
35
35
  update_index = i
36
36
  end
37
37
  bundler_version
38
38
  end
39
39
 
40
40
  def gemfile
41
- gemfile = ENV['BUNDLE_GEMFILE']
41
+ gemfile = ENV["BUNDLE_GEMFILE"]
42
42
  return gemfile if gemfile && !gemfile.empty?
43
43
 
44
- File.expand_path('../Gemfile', __dir__)
44
+ File.expand_path("../../Gemfile", __FILE__)
45
45
  end
46
46
 
47
47
  def lockfile
48
48
  lockfile =
49
49
  case File.basename(gemfile)
50
- when 'gems.rb' then gemfile.sub(/\.rb$/, gemfile)
50
+ when "gems.rb" then gemfile.sub(/\.rb$/, gemfile)
51
51
  else "#{gemfile}.lock"
52
52
  end
53
53
  File.expand_path(lockfile)
@@ -55,37 +55,37 @@ m = Module.new do
55
55
 
56
56
  def lockfile_version
57
57
  return unless File.file?(lockfile)
58
-
59
58
  lockfile_contents = File.read(lockfile)
60
59
  return unless lockfile_contents =~ /\n\nBUNDLED WITH\n\s{2,}(#{Gem::Version::VERSION_PATTERN})\n/
61
-
62
60
  Regexp.last_match(1)
63
61
  end
64
62
 
65
63
  def bundler_version
66
- @bundler_version ||= env_var_version || cli_arg_version ||
67
- lockfile_version || "#{Gem::Requirement.default}.a"
64
+ @bundler_version ||= begin
65
+ env_var_version || cli_arg_version ||
66
+ lockfile_version || "#{Gem::Requirement.default}.a"
67
+ end
68
68
  end
69
69
 
70
70
  def load_bundler!
71
- ENV['BUNDLE_GEMFILE'] ||= gemfile
71
+ ENV["BUNDLE_GEMFILE"] ||= gemfile
72
72
 
73
73
  # must dup string for RG < 1.8 compatibility
74
74
  activate_bundler(bundler_version.dup)
75
75
  end
76
76
 
77
77
  def activate_bundler(bundler_version)
78
- bundler_version = '< 2' if Gem::Version.correct?(bundler_version) && Gem::Version.new(bundler_version).release < Gem::Version.new('2.0')
78
+ if Gem::Version.correct?(bundler_version) && Gem::Version.new(bundler_version).release < Gem::Version.new("2.0")
79
+ bundler_version = "< 2"
80
+ end
79
81
  gem_error = activation_error_handling do
80
- gem 'bundler', bundler_version
82
+ gem "bundler", bundler_version
81
83
  end
82
84
  return if gem_error.nil?
83
-
84
85
  require_error = activation_error_handling do
85
- require 'bundler/version'
86
+ require "bundler/version"
86
87
  end
87
88
  return if require_error.nil? && Gem::Requirement.new(bundler_version).satisfied_by?(Gem::Version.new(Bundler::VERSION))
88
-
89
89
  warn "Activating bundler (#{bundler_version}) failed:\n#{gem_error.message}\n\nTo install the version of bundler this project requires, run `gem install bundler -v '#{bundler_version}'`"
90
90
  exit 42
91
91
  end
@@ -100,4 +100,6 @@ end
100
100
 
101
101
  m.load_bundler!
102
102
 
103
- load Gem.bin_path('bundler', 'bundle') if m.invoked_as_script?
103
+ if m.invoked_as_script?
104
+ load Gem.bin_path("bundler", "bundle")
105
+ end
data/bin/byebug CHANGED
@@ -8,11 +8,11 @@
8
8
  # this file is here to facilitate running it.
9
9
  #
10
10
 
11
- require 'pathname'
12
- ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile',
13
- Pathname.new(__FILE__).realpath)
11
+ require "pathname"
12
+ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
13
+ Pathname.new(__FILE__).realpath)
14
14
 
15
- bundle_binstub = File.expand_path('bundle', __dir__)
15
+ bundle_binstub = File.expand_path("../bundle", __FILE__)
16
16
 
17
17
  if File.file?(bundle_binstub)
18
18
  if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
@@ -23,7 +23,7 @@ Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this
23
23
  end
24
24
  end
25
25
 
26
- require 'rubygems'
27
- require 'bundler/setup'
26
+ require "rubygems"
27
+ require "bundler/setup"
28
28
 
29
- load Gem.bin_path('byebug', 'byebug')
29
+ load Gem.bin_path("byebug", "byebug")
data/bin/coderay CHANGED
@@ -8,11 +8,11 @@
8
8
  # this file is here to facilitate running it.
9
9
  #
10
10
 
11
- require 'pathname'
12
- ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile',
13
- Pathname.new(__FILE__).realpath)
11
+ require "pathname"
12
+ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
13
+ Pathname.new(__FILE__).realpath)
14
14
 
15
- bundle_binstub = File.expand_path('bundle', __dir__)
15
+ bundle_binstub = File.expand_path("../bundle", __FILE__)
16
16
 
17
17
  if File.file?(bundle_binstub)
18
18
  if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
@@ -23,7 +23,7 @@ Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this
23
23
  end
24
24
  end
25
25
 
26
- require 'rubygems'
27
- require 'bundler/setup'
26
+ require "rubygems"
27
+ require "bundler/setup"
28
28
 
29
- load Gem.bin_path('coderay', 'coderay')
29
+ load Gem.bin_path("coderay", "coderay")
data/bin/fuzzy_match CHANGED
@@ -8,11 +8,11 @@
8
8
  # this file is here to facilitate running it.
9
9
  #
10
10
 
11
- require 'pathname'
12
- ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile',
13
- Pathname.new(__FILE__).realpath)
11
+ require "pathname"
12
+ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
13
+ Pathname.new(__FILE__).realpath)
14
14
 
15
- bundle_binstub = File.expand_path('bundle', __dir__)
15
+ bundle_binstub = File.expand_path("../bundle", __FILE__)
16
16
 
17
17
  if File.file?(bundle_binstub)
18
18
  if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
@@ -23,7 +23,7 @@ Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this
23
23
  end
24
24
  end
25
25
 
26
- require 'rubygems'
27
- require 'bundler/setup'
26
+ require "rubygems"
27
+ require "bundler/setup"
28
28
 
29
- load Gem.bin_path('fuzzy_match', 'fuzzy_match')
29
+ load Gem.bin_path("fuzzy_match", "fuzzy_match")
data/bin/htmldiff CHANGED
@@ -8,11 +8,11 @@
8
8
  # this file is here to facilitate running it.
9
9
  #
10
10
 
11
- require 'pathname'
12
- ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile',
13
- Pathname.new(__FILE__).realpath)
11
+ require "pathname"
12
+ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
13
+ Pathname.new(__FILE__).realpath)
14
14
 
15
- bundle_binstub = File.expand_path('bundle', __dir__)
15
+ bundle_binstub = File.expand_path("../bundle", __FILE__)
16
16
 
17
17
  if File.file?(bundle_binstub)
18
18
  if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
@@ -23,7 +23,7 @@ Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this
23
23
  end
24
24
  end
25
25
 
26
- require 'rubygems'
27
- require 'bundler/setup'
26
+ require "rubygems"
27
+ require "bundler/setup"
28
28
 
29
- load Gem.bin_path('diff-lcs', 'htmldiff')
29
+ load Gem.bin_path("diff-lcs", "htmldiff")
data/bin/httpclient CHANGED
@@ -8,11 +8,11 @@
8
8
  # this file is here to facilitate running it.
9
9
  #
10
10
 
11
- require 'pathname'
12
- ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile',
13
- Pathname.new(__FILE__).realpath)
11
+ require "pathname"
12
+ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
13
+ Pathname.new(__FILE__).realpath)
14
14
 
15
- bundle_binstub = File.expand_path('bundle', __dir__)
15
+ bundle_binstub = File.expand_path("../bundle", __FILE__)
16
16
 
17
17
  if File.file?(bundle_binstub)
18
18
  if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
@@ -23,7 +23,7 @@ Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this
23
23
  end
24
24
  end
25
25
 
26
- require 'rubygems'
27
- require 'bundler/setup'
26
+ require "rubygems"
27
+ require "bundler/setup"
28
28
 
29
- load Gem.bin_path('httpclient', 'httpclient')
29
+ load Gem.bin_path("httpclient", "httpclient")
data/bin/ldiff CHANGED
@@ -8,11 +8,11 @@
8
8
  # this file is here to facilitate running it.
9
9
  #
10
10
 
11
- require 'pathname'
12
- ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile',
13
- Pathname.new(__FILE__).realpath)
11
+ require "pathname"
12
+ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
13
+ Pathname.new(__FILE__).realpath)
14
14
 
15
- bundle_binstub = File.expand_path('bundle', __dir__)
15
+ bundle_binstub = File.expand_path("../bundle", __FILE__)
16
16
 
17
17
  if File.file?(bundle_binstub)
18
18
  if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
@@ -23,7 +23,7 @@ Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this
23
23
  end
24
24
  end
25
25
 
26
- require 'rubygems'
27
- require 'bundler/setup'
26
+ require "rubygems"
27
+ require "bundler/setup"
28
28
 
29
- load Gem.bin_path('diff-lcs', 'ldiff')
29
+ load Gem.bin_path("diff-lcs", "ldiff")
data/bin/pod CHANGED
@@ -8,11 +8,11 @@
8
8
  # this file is here to facilitate running it.
9
9
  #
10
10
 
11
- require 'pathname'
12
- ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile',
13
- Pathname.new(__FILE__).realpath)
11
+ require "pathname"
12
+ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
13
+ Pathname.new(__FILE__).realpath)
14
14
 
15
- bundle_binstub = File.expand_path('bundle', __dir__)
15
+ bundle_binstub = File.expand_path("../bundle", __FILE__)
16
16
 
17
17
  if File.file?(bundle_binstub)
18
18
  if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
@@ -23,7 +23,7 @@ Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this
23
23
  end
24
24
  end
25
25
 
26
- require 'rubygems'
27
- require 'bundler/setup'
26
+ require "rubygems"
27
+ require "bundler/setup"
28
28
 
29
- load Gem.bin_path('cocoapods', 'pod')
29
+ load Gem.bin_path("cocoapods", "pod")
data/bin/pry CHANGED
@@ -8,11 +8,11 @@
8
8
  # this file is here to facilitate running it.
9
9
  #
10
10
 
11
- require 'pathname'
12
- ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile',
13
- Pathname.new(__FILE__).realpath)
11
+ require "pathname"
12
+ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
13
+ Pathname.new(__FILE__).realpath)
14
14
 
15
- bundle_binstub = File.expand_path('bundle', __dir__)
15
+ bundle_binstub = File.expand_path("../bundle", __FILE__)
16
16
 
17
17
  if File.file?(bundle_binstub)
18
18
  if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
@@ -23,7 +23,7 @@ Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this
23
23
  end
24
24
  end
25
25
 
26
- require 'rubygems'
27
- require 'bundler/setup'
26
+ require "rubygems"
27
+ require "bundler/setup"
28
28
 
29
- load Gem.bin_path('pry', 'pry')
29
+ load Gem.bin_path("pry", "pry")
data/bin/rake CHANGED
@@ -8,11 +8,11 @@
8
8
  # this file is here to facilitate running it.
9
9
  #
10
10
 
11
- require 'pathname'
12
- ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile',
13
- Pathname.new(__FILE__).realpath)
11
+ require "pathname"
12
+ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
13
+ Pathname.new(__FILE__).realpath)
14
14
 
15
- bundle_binstub = File.expand_path('bundle', __dir__)
15
+ bundle_binstub = File.expand_path("../bundle", __FILE__)
16
16
 
17
17
  if File.file?(bundle_binstub)
18
18
  if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
@@ -23,7 +23,7 @@ Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this
23
23
  end
24
24
  end
25
25
 
26
- require 'rubygems'
27
- require 'bundler/setup'
26
+ require "rubygems"
27
+ require "bundler/setup"
28
28
 
29
- load Gem.bin_path('rake', 'rake')
29
+ load Gem.bin_path("rake", "rake")
data/bin/rspec CHANGED
@@ -8,11 +8,11 @@
8
8
  # this file is here to facilitate running it.
9
9
  #
10
10
 
11
- require 'pathname'
12
- ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile',
13
- Pathname.new(__FILE__).realpath)
11
+ require "pathname"
12
+ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
13
+ Pathname.new(__FILE__).realpath)
14
14
 
15
- bundle_binstub = File.expand_path('bundle', __dir__)
15
+ bundle_binstub = File.expand_path("../bundle", __FILE__)
16
16
 
17
17
  if File.file?(bundle_binstub)
18
18
  if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
@@ -23,7 +23,7 @@ Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this
23
23
  end
24
24
  end
25
25
 
26
- require 'rubygems'
27
- require 'bundler/setup'
26
+ require "rubygems"
27
+ require "bundler/setup"
28
28
 
29
- load Gem.bin_path('rspec-core', 'rspec')
29
+ load Gem.bin_path("rspec-core", "rspec")
data/bin/rubocop CHANGED
@@ -8,11 +8,11 @@
8
8
  # this file is here to facilitate running it.
9
9
  #
10
10
 
11
- require 'pathname'
12
- ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile',
13
- Pathname.new(__FILE__).realpath)
11
+ require "pathname"
12
+ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
13
+ Pathname.new(__FILE__).realpath)
14
14
 
15
- bundle_binstub = File.expand_path('bundle', __dir__)
15
+ bundle_binstub = File.expand_path("../bundle", __FILE__)
16
16
 
17
17
  if File.file?(bundle_binstub)
18
18
  if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
@@ -23,7 +23,7 @@ Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this
23
23
  end
24
24
  end
25
25
 
26
- require 'rubygems'
27
- require 'bundler/setup'
26
+ require "rubygems"
27
+ require "bundler/setup"
28
28
 
29
- load Gem.bin_path('rubocop', 'rubocop')
29
+ load Gem.bin_path("rubocop", "rubocop")
data/bin/ruby-parse CHANGED
@@ -8,11 +8,11 @@
8
8
  # this file is here to facilitate running it.
9
9
  #
10
10
 
11
- require 'pathname'
12
- ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile',
13
- Pathname.new(__FILE__).realpath)
11
+ require "pathname"
12
+ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
13
+ Pathname.new(__FILE__).realpath)
14
14
 
15
- bundle_binstub = File.expand_path('bundle', __dir__)
15
+ bundle_binstub = File.expand_path("../bundle", __FILE__)
16
16
 
17
17
  if File.file?(bundle_binstub)
18
18
  if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
@@ -23,7 +23,7 @@ Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this
23
23
  end
24
24
  end
25
25
 
26
- require 'rubygems'
27
- require 'bundler/setup'
26
+ require "rubygems"
27
+ require "bundler/setup"
28
28
 
29
- load Gem.bin_path('parser', 'ruby-parse')
29
+ load Gem.bin_path("parser", "ruby-parse")
data/bin/ruby-rewrite CHANGED
@@ -8,11 +8,11 @@
8
8
  # this file is here to facilitate running it.
9
9
  #
10
10
 
11
- require 'pathname'
12
- ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile',
13
- Pathname.new(__FILE__).realpath)
11
+ require "pathname"
12
+ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
13
+ Pathname.new(__FILE__).realpath)
14
14
 
15
- bundle_binstub = File.expand_path('bundle', __dir__)
15
+ bundle_binstub = File.expand_path("../bundle", __FILE__)
16
16
 
17
17
  if File.file?(bundle_binstub)
18
18
  if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
@@ -23,7 +23,7 @@ Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this
23
23
  end
24
24
  end
25
25
 
26
- require 'rubygems'
27
- require 'bundler/setup'
26
+ require "rubygems"
27
+ require "bundler/setup"
28
28
 
29
- load Gem.bin_path('parser', 'ruby-rewrite')
29
+ load Gem.bin_path("parser", "ruby-rewrite")
data/bin/sandbox-pod CHANGED
@@ -8,11 +8,11 @@
8
8
  # this file is here to facilitate running it.
9
9
  #
10
10
 
11
- require 'pathname'
12
- ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile',
13
- Pathname.new(__FILE__).realpath)
11
+ require "pathname"
12
+ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
13
+ Pathname.new(__FILE__).realpath)
14
14
 
15
- bundle_binstub = File.expand_path('bundle', __dir__)
15
+ bundle_binstub = File.expand_path("../bundle", __FILE__)
16
16
 
17
17
  if File.file?(bundle_binstub)
18
18
  if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
@@ -23,7 +23,7 @@ Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this
23
23
  end
24
24
  end
25
25
 
26
- require 'rubygems'
27
- require 'bundler/setup'
26
+ require "rubygems"
27
+ require "bundler/setup"
28
28
 
29
- load Gem.bin_path('cocoapods', 'sandbox-pod')
29
+ load Gem.bin_path("cocoapods", "sandbox-pod")
data/bin/xcodeproj CHANGED
@@ -8,11 +8,11 @@
8
8
  # this file is here to facilitate running it.
9
9
  #
10
10
 
11
- require 'pathname'
12
- ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile',
13
- Pathname.new(__FILE__).realpath)
11
+ require "pathname"
12
+ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
13
+ Pathname.new(__FILE__).realpath)
14
14
 
15
- bundle_binstub = File.expand_path('bundle', __dir__)
15
+ bundle_binstub = File.expand_path("../bundle", __FILE__)
16
16
 
17
17
  if File.file?(bundle_binstub)
18
18
  if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
@@ -23,7 +23,7 @@ Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this
23
23
  end
24
24
  end
25
25
 
26
- require 'rubygems'
27
- require 'bundler/setup'
26
+ require "rubygems"
27
+ require "bundler/setup"
28
28
 
29
- load Gem.bin_path('xcodeproj', 'xcodeproj')
29
+ load Gem.bin_path("xcodeproj", "xcodeproj")
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module MotionSparkleSandbox
4
- VERSION = '2.0.1'
4
+ VERSION = '2.1.0'
5
5
  end
@@ -16,7 +16,7 @@ require 'motion/project/indent_string'
16
16
 
17
17
  lib_dir_path = File.dirname(File.expand_path(__FILE__))
18
18
 
19
- POD_VERSION = '~> 2.0.0'
19
+ POD_VERSION = '~> 2.1.0'
20
20
 
21
21
  unless @running_specs
22
22
  Motion::Project::App.setup do |app|
data/spec/setup_spec.rb CHANGED
@@ -2,66 +2,41 @@
2
2
 
3
3
  require File.expand_path('spec_utils', __dir__)
4
4
 
5
- module Motion
6
- module Project
7
- class Config
8
- attr_writer :project_dir
9
- end
10
- end
11
- end
12
-
13
5
  describe 'Sparkle setup' do
14
6
  before(:all) do
15
- SpecUtils::TemporaryDirectory.teardown
16
- SpecUtils::TemporaryDirectory.setup
17
-
18
- FileUtils.mkdir_p("#{SpecUtils::TemporaryDirectory.directory}resources")
19
- FileUtils.mkdir_p("#{SpecUtils::TemporaryDirectory.directory}vendor")
20
- FileUtils.touch("#{SpecUtils::TemporaryDirectory.directory}.gitignore")
21
- end
22
-
23
- context 'something' do
24
- before do
25
- @config = App.config
26
- @config.project_dir = SpecUtils::TemporaryDirectory.directory.to_s
27
- @config.instance_eval do
28
- pods do
29
- pod 'Sparkle', POD_VERSION
30
- end
31
-
32
- sparkle do
33
- release :base_url, 'http://example.com/'
34
- # release :public_key, 'public_key.pem'
35
- publish :public_key, '<YOUR-EDDSA-PUBLIC-KEY>'
36
- release :version, '1.0'
37
-
38
- # Optional config options
39
- release :feed_base_url, 'http://rss.example.com/'
40
- release :feed_filename, 'example.xml'
41
- release :notes_base_url, 'http://www.example.com/'
42
- release :notes_filename, 'example.html'
43
- release :package_base_url, 'http://download.example.com/'
44
- release :package_filename, 'example.zip'
45
- # publish :use_exported_private_key, true
46
- end
7
+ @config = App.config
8
+ @config.project_dir = SpecUtils::TemporaryDirectory.directory.to_s
9
+ @config.instance_eval do
10
+ sparkle do
11
+ release :base_url, 'http://example.com/'
12
+ # release :public_key, 'public_key.pem'
13
+ publish :public_key, '<YOUR-EDDSA-PUBLIC-KEY>'
14
+ release :version, '1.0'
15
+
16
+ # Optional config options
17
+ release :feed_base_url, 'http://rss.example.com/'
18
+ release :feed_filename, 'example.xml'
19
+ release :notes_base_url, 'http://www.example.com/'
20
+ release :notes_filename, 'example.html'
21
+ release :package_base_url, 'http://download.example.com/'
22
+ release :package_filename, 'example.zip'
23
+ # publish :use_exported_private_key, true
47
24
  end
48
-
49
- Rake::Task['pod:install'].invoke
50
- Rake::Task['sparkle:setup'].invoke
51
- # Rake::Task['sparkle:setup_certificates'].invoke
52
- end
53
-
54
- it 'should create private certificate' do
55
- expect(File.exist?(@config.sparkle.private_key_path.to_s)).to be_truthy
56
25
  end
57
26
 
58
- it 'should create public certificate' do
59
- expect(File.exist?(@config.sparkle.public_key_path.to_s)).to be_truthy
60
- end
27
+ Rake::Task['sparkle:setup'].invoke
28
+ end
61
29
 
62
- it 'should add files to gitignore' do
63
- a = `cat .gitignore`
64
- expect(a.strip).not_to eq ''
65
- end
30
+ # it 'should create private certificate' do
31
+ # expect(File.exist?(@config.sparkle.private_key_path.to_s)).to be_truthy
32
+ # end
33
+ #
34
+ # it 'should create public certificate' do
35
+ # expect(File.exist?(@config.sparkle.public_key_path.to_s)).to be_truthy
36
+ # end
37
+
38
+ it 'should add files to gitignore' do
39
+ a = `cat .gitignore`
40
+ expect(a.strip).not_to eq ''
66
41
  end
67
42
  end
data/spec/sparkle_spec.rb CHANGED
@@ -2,37 +2,20 @@
2
2
 
3
3
  require File.expand_path('spec_utils', __dir__)
4
4
 
5
- module Motion
6
- module Project
7
- class Config
8
- attr_writer :project_dir
9
- end
10
- end
11
- end
12
-
13
5
  # rubocop:disable Metrics/BlockLength
14
6
  describe 'motion-sparkle-sandbox' do
15
7
  before(:all) do
16
- SpecUtils::TemporaryDirectory.teardown
17
- SpecUtils::TemporaryDirectory.setup
18
-
19
- FileUtils.mkdir_p("#{SpecUtils::TemporaryDirectory.directory}resources")
20
- FileUtils.mkdir_p("#{SpecUtils::TemporaryDirectory.directory}vendor")
21
- FileUtils.touch("#{SpecUtils::TemporaryDirectory.directory}.gitignore")
22
- end
23
-
24
- context 'configuration' do
25
- before do
26
- @config = App.config
27
- @config.sparkle = nil
28
- @config.project_dir = SpecUtils::TemporaryDirectory.directory.to_s
29
- @config.instance_eval do
30
- sparkle do
31
- release :base_url, 'http://example.com/'
32
- end
8
+ @config = App.config
9
+ @config.sparkle = nil
10
+ @config.project_dir = SpecUtils::TemporaryDirectory.directory.to_s
11
+ @config.instance_eval do
12
+ sparkle do
13
+ release :base_url, 'http://example.com/'
33
14
  end
34
15
  end
16
+ end
35
17
 
18
+ context 'configuration' do
36
19
  describe 'base url' do
37
20
  it 'base url should be set correctly' do
38
21
  expect(@config.sparkle.appcast.base_url).to eq 'http://example.com/'
@@ -115,22 +98,10 @@ describe 'motion-sparkle-sandbox' do
115
98
  end
116
99
 
117
100
  context 'cocoapod' do
118
- before do
119
- @config = App.config
120
- @config.project_dir = SpecUtils::TemporaryDirectory.directory.to_s
121
- @config.instance_eval do
122
- pods do
123
- pod 'Sparkle', POD_VERSION
124
- end
125
- end
126
-
127
- Rake::Task['pod:install'].invoke
128
- end
129
-
130
101
  it 'Sparkle framework pod should be embedded' do
131
102
  sparkle_framework_path = 'vendor/Pods/Sparkle/Sparkle.framework'
132
- @config.pods.pods_libraries
133
103
 
104
+ @config.pods.pods_libraries
134
105
  expect(@config.embedded_frameworks.first.end_with?(sparkle_framework_path)).to be_truthy
135
106
  end
136
107
  end
data/spec/spec_helper.rb CHANGED
@@ -97,4 +97,12 @@ RSpec.configure do |config|
97
97
  # # test failures related to randomization by passing the same `--seed` value
98
98
  # # as the one that triggered the failure.
99
99
  # Kernel.srand config.seed
100
+
101
+ config.before(:suite) do
102
+ SpecUtils::SparkleSetup.initial_install
103
+ end
104
+
105
+ config.after(:suite) do
106
+ SpecUtils::SparkleSetup.final_deinstall
107
+ end
100
108
  end
data/spec/spec_utils.rb CHANGED
@@ -13,7 +13,43 @@ $:.unshift("#{ROOT}lib".to_s)
13
13
  require 'motion/project/template/osx'
14
14
  require 'motion-sparkle-sandbox'
15
15
 
16
+ # necessary for us to be able to overwrite the `project_dir`
17
+ module Motion
18
+ module Project
19
+ class Config
20
+ attr_writer :project_dir
21
+ end
22
+ end
23
+ end
24
+
16
25
  module SpecUtils
26
+ module SparkleSetup
27
+ # run from a before(:suite)
28
+ def self.initial_install
29
+ SpecUtils::TemporaryDirectory.setup
30
+
31
+ FileUtils.mkdir_p("#{SpecUtils::TemporaryDirectory.directory}/resources")
32
+ FileUtils.mkdir_p("#{SpecUtils::TemporaryDirectory.directory}/vendor")
33
+ FileUtils.touch("#{SpecUtils::TemporaryDirectory.directory}/.gitignore")
34
+
35
+ @config = App.config
36
+ @config.sparkle = nil
37
+ @config.project_dir = SpecUtils::TemporaryDirectory.directory.to_s
38
+ @config.instance_eval do
39
+ pods do
40
+ pod 'Sparkle', POD_VERSION
41
+ end
42
+ end
43
+
44
+ Rake::Task['pod:install'].invoke
45
+ end
46
+
47
+ # run from an after(:suite)
48
+ def self.final_deinstall
49
+ SpecUtils::TemporaryDirectory.teardown
50
+ end
51
+ end
52
+
17
53
  module TemporaryDirectory
18
54
  TEMPORARY_DIRECTORY = ROOT + 'tmp' # rubocop:disable Style/StringConcatenation
19
55
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: motion-sparkle-sandbox
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.1
4
+ version: 2.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brett Walker
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2022-05-27 00:00:00.000000000 Z
12
+ date: 2022-05-28 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: motion-cocoapods