bootic_cli 0.6.4 → 0.6.5

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: a1f49bbc8333263cc87d2e254d0e2d3dca1d801ac685c343a64512b22ccddd91
4
- data.tar.gz: 31d0c8fa3d9c3b7d070c172441b4df0187728606153d15235ba65cb5fc513c7a
3
+ metadata.gz: 5b387d8fd3e457f8d96ee99d8ef47cc9202ab52f2a161815a79138e0047b4613
4
+ data.tar.gz: e933918d22e7ce87854b905816cb1a20190f393f0c390209ba479e351599d8e9
5
5
  SHA512:
6
- metadata.gz: 8ecbeaf2859c4fb9ba81611ccf810d4c10e1a9e61888c7d206c1ef7facc2bd7a1e78589cbd9512903a0799faf0cad3b2aeb6a0fbd4c16c40f22399f286d94891
7
- data.tar.gz: d13807aacb8f8428d7306eab4f30c5b4862a3a4ef7c067e0591c1ab04043904940bcf0d4098be445932c2730f5a02e6d0bef655a405af4af543acbec892989f6
6
+ metadata.gz: 5d87ca108ef8c9db618dd49e64731b7d910332b76900b7c3ca0db5fdc50a0781fb9078af96751dd3eedeba14ce680f96296e49554e2ce039f49989c70f88437e
7
+ data.tar.gz: ec3e339333a702508a32bce522a66a4580915e4140ef05faf6e5c9b459439cf7f56f0d9f0f671eae2885f5f4ee2b7f317bcb65a8585ccb188a15a2ed8d208d56
data/bootic_cli.gemspec CHANGED
@@ -25,6 +25,11 @@ Gem::Specification.new do |spec|
25
25
  spec.add_dependency 'listen', "~> 3.1"
26
26
  spec.add_dependency 'launchy', "~> 2.4"
27
27
 
28
+ if Gem.win_platform?
29
+ spec.add_dependency 'diff-lcs'
30
+ spec.add_dependency 'wdm', '>= 0.1.0'
31
+ end
32
+
28
33
  spec.add_development_dependency "bundler", "~> 1.9"
29
34
  spec.add_development_dependency "rake", "~> 10.0"
30
35
  spec.add_development_dependency "rspec", "~> 3.2"
@@ -89,7 +89,7 @@ module BooticCli
89
89
 
90
90
  # if we just compared against the dev theme, redo the mumbo-jumbo but with the public one
91
91
  unless remote_theme.public?
92
- prompt.say "Comparing againt public theme now.", :cyan
92
+ prompt.pause "Comparing againt public theme now. Press any key to continue.", :cyan
93
93
  local_theme, public_theme = theme_selector.select_theme_pair(default_subdomain, current_dir, true)
94
94
  workflows.compare(local_theme, public_theme)
95
95
  end
@@ -262,6 +262,15 @@ module BooticCli
262
262
  !default_answer
263
263
  end
264
264
 
265
+ def pause(string, color = nil)
266
+ begin
267
+ input = shell.ask(string, color)
268
+ rescue Interrupt
269
+ say "\nCtrl-C received. Bailing out!", :magenta
270
+ abort
271
+ end
272
+ end
273
+
265
274
  def notice(str)
266
275
  parts = [" --->", str]
267
276
  puts highlight parts.join(' ')
@@ -1,5 +1,14 @@
1
1
  require 'diffy'
2
2
 
3
+ module Diffy
4
+ class Diff
5
+ # monkey patch diffy to fix buggy bug: https://github.com/samg/diffy/pull/103
6
+ def diff_options
7
+ Array(options[:context] ? "-U#{options[:context]}" : options[:diff])
8
+ end
9
+ end
10
+ end
11
+
3
12
  module BooticCli
4
13
  module Themes
5
14
  # given :source and :target themes,
@@ -21,9 +30,7 @@ module BooticCli
21
30
 
22
31
  def templates
23
32
  @templates ||= map_pair(source.templates, target.templates) do |a, b|
24
- # don't use context until diffy bug is fixed: https://github.com/samg/diffy/pull/103
25
- # diff = Diffy::Diff.new(normalize_endings(b.body), normalize_endings(a.body), context: 1)
26
- diff = Diffy::Diff.new(normalize_endings(b.body), normalize_endings(a.body))
33
+ diff = Diffy::Diff.new(normalize_endings(b.body), normalize_endings(a.body), context: 1)
27
34
 
28
35
  if !diff.to_s.empty? && should_update?(a, b)
29
36
  c = TemplateWithDiff.new(a.file_name, a.body, a.updated_on, diff)
@@ -1,3 +1,3 @@
1
1
  module BooticCli
2
- VERSION = '0.6.4'
2
+ VERSION = '0.6.5'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bootic_cli
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.4
4
+ version: 0.6.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ismael Celis
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2019-08-13 00:00:00.000000000 Z
12
+ date: 2019-08-23 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: thor