skippy 0.4.0.a → 0.4.1.a

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: 8911df6fd31addc62c4bc4756eb46f715eaf70ea2d2bcfb32175f104dad78f82
4
- data.tar.gz: dbb042f7ed689a8d1a01589b4f11479014da36861e1cf578453a75eab14028b0
3
+ metadata.gz: ce2b2452959a54d094d90bac57789f3738137f7d94ce844db4a6a2b08788925d
4
+ data.tar.gz: f3984931967ac74cfb3d5c8c233855385e0bee8c046d4d8156c0fec1d503d320
5
5
  SHA512:
6
- metadata.gz: fda57b8e19f1a22ab2ad207bd938df1a5f9ba158400d5126572dc518130f48614cd30082aa4b4ac800fd33aa7c38fd32c712dfd4c7c5aac36432bc21762c0b6d
7
- data.tar.gz: e43b4802ac2f2b0c2a60e5b8da927e9cb19cdcaee74d38c021422ebb571a7395363184f6828eccd23c66055ba2d078e8f30162849543a02d081cfcd05df853a5
6
+ metadata.gz: b18020a84524b9d4842e22939ada7fdf9f1edec500a4dce6d9ff6642ef47d335c46debb5c7933a4e504c191eb953af5a4654977787b9ce6e1734e408c1019f7f
7
+ data.tar.gz: 1836e67a3a1a547b3f7f9caa96d729157246621df36045171920e234eeccc9224419730a53dddf6d17a603b6d1871135d2ad1dcd99472fd34dbc833c4d3f19a3
@@ -45,6 +45,10 @@ Metrics/ClassLength:
45
45
  Exclude:
46
46
  - test/**/*
47
47
 
48
+ # Too noisy.
49
+ Metrics/CyclomaticComplexity:
50
+ Enabled: false
51
+
48
52
  Metrics/LineLength:
49
53
  Exclude:
50
54
  - features/step_definitions/**/*
@@ -53,6 +57,10 @@ Metrics/MethodLength:
53
57
  Exclude:
54
58
  - test/**/*
55
59
 
60
+ # Too noisy.
61
+ Metrics/PerceivedComplexity:
62
+ Enabled: false
63
+
56
64
  # Prefer { ... } over do ... end except for control flow and
57
65
  # method defintions. Unfortunatly, no cop configuration for this.
58
66
  # https://github.com/chneukirchen/styleguide/blob/e60de37b478d3f892f6985a58d573016f33f0269/RUBY-STYLE#L63-L67
@@ -82,6 +90,18 @@ Style/Documentation:
82
90
  Style/GuardClause:
83
91
  Enabled: false
84
92
 
93
+ # In the context of the Thor DLS the rocket arrow => reads better.
94
+ Style/HashSyntax:
95
+ Exclude:
96
+ - app/commands/**/*
97
+
98
+ # Some times it reads clearer to not trail if/unless at the end.
99
+ Style/IfUnlessModifier:
100
+ Enabled: false
101
+
102
+ Style/ModuleFunction:
103
+ Enabled: false
104
+
85
105
  # %w and %i etc isn't really intuitive unless you are really familiar with the
86
106
  # syntax. %w seems used often enough. But [:symbol, :foo] reads clearer than
87
107
  # %i(symbol foo).
@@ -1,16 +1,18 @@
1
1
  {
2
2
  // See https://go.microsoft.com/fwlink/?LinkId=733558
3
3
  // for the documentation about the tasks.json format
4
- "version": "0.1.0",
5
- "command": "bundle",
6
- "isShellCommand": true,
7
- "showOutput": "always",
8
- "echoCommand": true,
9
- "args": ["exec", "rake"],
10
- "tasks": [{
11
- "taskName": "test",
12
- "args": ["TEST=${relativeFile}"],
13
- "isTestCommand": true,
14
- "isBuildCommand": true
15
- }]
4
+ "version": "2.0.0",
5
+ "tasks": [
6
+ {
7
+ "label": "rake test FILE",
8
+ "type": "shell",
9
+ "command": "bundle",
10
+ "args": [
11
+ "exec",
12
+ "rake",
13
+ "TEST=${relativeFile}"
14
+ ],
15
+ "group": "test"
16
+ }
17
+ ]
16
18
  }
@@ -22,7 +22,7 @@ class Install < Skippy::Command::Group
22
22
  next if library[:version].nil? || library[:source].nil?
23
23
 
24
24
  options = {
25
- requirement: library[:version]
25
+ requirement: library[:version],
26
26
  }
27
27
  options[:branch] = library[:branch] unless library[:branch].nil?
28
28
  lib = project.libraries.install(library[:source], options)
@@ -39,7 +39,8 @@ class Lib < Skippy::Command
39
39
  def install(source)
40
40
  project = Skippy::Project.current_or_fail
41
41
  libraries = project.libraries
42
- library = libraries.install(source, install_options(options)) { |type, message|
42
+ installation_options = install_options(options)
43
+ library = libraries.install(source, installation_options) { |type, message|
43
44
  color = type == :warning ? :red : :yellow
44
45
  say message, color
45
46
  }
@@ -62,7 +62,7 @@ class Skippy::GitLibraryInstaller < Skippy::LibraryInstaller
62
62
  # @param [Git::Base]
63
63
  # @param [String] branch
64
64
  def checkout_branch(git, branch)
65
- branches = git.braches.map(&:name)
65
+ branches = git.branches.map(&:name)
66
66
  info "Branches: #{branches.inspect}"
67
67
  unless branches.include?(branch)
68
68
  raise Skippy::BranchNotFound, "Found no branch named: '#{branch}'"
@@ -117,7 +117,10 @@ class Skippy::LibrarySource
117
117
  # @param [String] source
118
118
  # @return [String]
119
119
  def resolve_from_git_uri(source)
120
- uri = URI.parse(source)
120
+ # This can be a local Windows path, normalize path separators to allow the
121
+ # path to be parsed.
122
+ normalized = source.tr('\\', '/')
123
+ uri = URI.parse(normalized)
121
124
  # When logged in, BitBucket will display a URI with the user's username.
122
125
  uri.user = ''
123
126
  uri.to_s
@@ -150,7 +150,7 @@ class Skippy::ModuleManager
150
150
  transform_module(content)
151
151
  File.write(target, content)
152
152
  else
153
- File.copy(source, target)
153
+ FileUtils.copy(source, target)
154
154
  end
155
155
  end
156
156
 
@@ -15,7 +15,7 @@ class Skippy::OSCommon
15
15
  end
16
16
 
17
17
  # @param [String] path
18
- def launch_app(path, *args)
18
+ def launch_app(path, *args) # rubocop:disable Lint/UnusedMethodArgument
19
19
  raise NotImplementedError
20
20
  end
21
21
 
@@ -23,7 +23,7 @@ class Skippy::OSMac < Skippy::OSCommon
23
23
  executable: app,
24
24
  version: version,
25
25
  can_debug: File.exist?(debug_lib),
26
- is64bit: version > 2015,
26
+ is64bit: version > 2015
27
27
  )
28
28
  }
29
29
  apps.sort_by(&:version)
@@ -33,7 +33,7 @@ class Skippy::OSWin < Skippy::OSCommon
33
33
  executable: exe,
34
34
  version: version,
35
35
  can_debug: File.exist?(debug_dll),
36
- is64bit: SYSTEM_64BIT && path.start_with?("#{PROGRAM_FILES_64BIT}/"),
36
+ is64bit: SYSTEM_64BIT && path.start_with?("#{PROGRAM_FILES_64BIT}/")
37
37
  )
38
38
  }
39
39
  }
@@ -1,5 +1,5 @@
1
1
  module Skippy
2
2
 
3
- VERSION = '0.4.0.a'.freeze
3
+ VERSION = '0.4.1.a'.freeze
4
4
 
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: skippy
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.0.a
4
+ version: 0.4.1.a
5
5
  platform: ruby
6
6
  authors:
7
7
  - Thomas Thomassen
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-12-20 00:00:00.000000000 Z
11
+ date: 2018-06-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: git