fastlane 2.67.0 → 2.68.0.beta.20171129010003

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 023dc8370b008bcf99703bb1543fd2ca6a2a32bd
4
- data.tar.gz: eabea283aefde2fe8620c719d292fe6fd4da83bc
3
+ metadata.gz: 214350d2a2fb36bcb9e5986405534e1fd77524dc
4
+ data.tar.gz: 3eba464e91ee8d1a657d5ebdb730ad5f78162ecc
5
5
  SHA512:
6
- metadata.gz: 0f5c751c1a9873841c6ea8acfe70eb32e744007567089f1e983ee6b841c3d702981991e501c795dd92498084282f32c54cf593e567b6a68894e1f63564aa4953
7
- data.tar.gz: df0ab4ebf116d631014475ad025c6173b7e71ccd1af77d41650363eda71e5cc1b59fbfd1da66accb072556a6df99da97f0c1196c775c8b47a752797f4c9bf6c5
6
+ metadata.gz: 5cbf535dc7856f6659775977f809a9cfaded54c56373c95c61a1721cb500cc1464941aef602ac52e6aeb241661b4ee834040a8c98a8e003a21c3827e70f8aa3e
7
+ data.tar.gz: a86fc1671fe25112c93cb59d4eb0467f1b5e4fb5b2f912e719a5ba5cefbbe5bca9c460604ae3692533a2fc309fce2060502868ba2dbb87e3134c1086efa304b5
@@ -21,4 +21,3 @@ _fastlane_complete() {
21
21
  COMPREPLY=( $(compgen -W "$completions" -- "$word") )
22
22
  }
23
23
 
24
- complete -F _fastlane_complete fastlane
@@ -21,4 +21,3 @@ update_fastlane"
21
21
  reply=( "${(ps:\n:)completions}" )
22
22
  }
23
23
 
24
- compctl -K _fastlane_complete fastlane
@@ -2,6 +2,7 @@ require 'fastlane_core'
2
2
 
3
3
  require 'fastlane/version'
4
4
  require 'fastlane/features'
5
+ require 'fastlane/shells'
5
6
  require 'fastlane/tools'
6
7
  require 'fastlane/documentation/actions_list'
7
8
  require 'fastlane/actions/actions_helper' # has to be before fast_file
@@ -3,13 +3,19 @@ require 'fileutils'
3
3
  module Fastlane
4
4
  # Enable tab auto completion
5
5
  class AutoComplete
6
- def self.execute
6
+ # This method copies the tab auto completion scripts to the user's home folder,
7
+ # while optionally adding custom commands for which to enable auto complete
8
+ # @param [Array] options An array of all options (e.g. --custom fl)
9
+ def self.execute(args, options)
7
10
  shell = ENV['SHELL']
8
11
 
9
12
  if shell.end_with? "fish"
10
13
  fish_completions_dir = "~/.config/fish/completions"
11
- confirm = UI.confirm "This will copy a fish script into #{fish_completions_dir} that provides the command tab completion. If the directory does not exist it will be created. Sound good?"
12
- return unless confirm
14
+
15
+ if UI.interactive?
16
+ confirm = UI.confirm "This will copy a fish script into #{fish_completions_dir} that provides the command tab completion. If the directory does not exist it will be created. Sound good?"
17
+ return unless confirm
18
+ end
13
19
 
14
20
  fish_completions_dir = File.expand_path fish_completions_dir
15
21
  FileUtils.mkdir_p fish_completions_dir
@@ -22,8 +28,11 @@ module Fastlane
22
28
  UI.success "Copied! You can now use tab completion for lanes"
23
29
  else
24
30
  fastlane_conf_dir = "~/.fastlane"
25
- confirm = UI.confirm "This will copy a shell script into #{fastlane_conf_dir} that provides the command tab completion. Sound good?"
26
- return unless confirm
31
+
32
+ if UI.interactive?
33
+ confirm = UI.confirm "This will copy a shell script into #{fastlane_conf_dir} that provides the command tab completion. Sound good?"
34
+ return unless confirm
35
+ end
27
36
 
28
37
  # create the ~/.fastlane directory
29
38
  fastlane_conf_dir = File.expand_path fastlane_conf_dir
@@ -33,10 +42,41 @@ module Fastlane
33
42
  completion_script_path = File.join(Fastlane::ROOT, 'lib', 'assets', 'completions')
34
43
  FileUtils.cp_r completion_script_path, fastlane_conf_dir
35
44
 
45
+ custom_commands = options.custom.to_s.split(',')
46
+
47
+ Fastlane::SHELLS.each do |shell_name|
48
+ open("#{fastlane_conf_dir}/completions/completion.#{shell_name}", 'a') do |file|
49
+ default_line_prefix = Helper.bundler? ? "bundle exec " : ""
50
+
51
+ file.puts self.get_auto_complete_line(shell_name, "#{default_line_prefix}fastlane")
52
+
53
+ custom_commands.each do |command|
54
+ auto_complete_line = self.get_auto_complete_line(shell_name, command)
55
+
56
+ next if auto_complete_line.nil?
57
+
58
+ file.puts auto_complete_line
59
+ end
60
+ end
61
+ end
62
+
36
63
  UI.success "Copied! To use auto complete for fastlane, add the following line to your favorite rc file (e.g. ~/.bashrc)"
37
64
  UI.important " . ~/.fastlane/completions/completion.sh"
38
65
  UI.success "Don't forget to source that file in your current shell! 🐚"
39
66
  end
40
67
  end
68
+
69
+ # Helper to get the auto complete register script line
70
+ def self.get_auto_complete_line(shell, command)
71
+ if shell == :bash
72
+ prefix = "complete -F"
73
+ elsif shell == :zsh
74
+ prefix = "compctl -K"
75
+ else
76
+ return nil
77
+ end
78
+
79
+ return "#{prefix} _fastlane_complete #{command}"
80
+ end
41
81
  end
42
82
  end
@@ -218,10 +218,11 @@ module Fastlane
218
218
  command :enable_auto_complete do |c|
219
219
  c.syntax = 'fastlane enable_auto_complete'
220
220
  c.description = 'Enable tab auto completion'
221
+ c.option '-c STRING[,STRING2]', '--custom STRING[,STRING2]', String, 'Add custom command(s) for which tab auto complete should be enabled too'
221
222
 
222
223
  c.action do |args, options|
223
224
  require 'fastlane/auto_complete'
224
- Fastlane::AutoComplete.execute
225
+ Fastlane::AutoComplete.execute(args, options)
225
226
  end
226
227
  end
227
228
 
@@ -0,0 +1,6 @@
1
+ module Fastlane
2
+ SHELLS = [
3
+ :bash,
4
+ :zsh
5
+ ]
6
+ end
@@ -1,5 +1,5 @@
1
1
  module Fastlane
2
- VERSION = '2.67.0'.freeze
2
+ VERSION = '2.68.0.beta.20171129010003'.freeze
3
3
  DESCRIPTION = "The easiest way to automate beta deployments and releases for your iOS and Android apps".freeze
4
4
  MINIMUM_XCODE_RELEASE = "7.0".freeze
5
5
  RUBOCOP_REQUIREMENT = '0.49.1'.freeze
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fastlane
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.67.0
4
+ version: 2.68.0.beta.20171129010003
5
5
  platform: ruby
6
6
  authors:
7
7
  - Felix Krause
@@ -15,7 +15,7 @@ authors:
15
15
  autorequire:
16
16
  bindir: bin
17
17
  cert_chain: []
18
- date: 2017-11-28 00:00:00.000000000 Z
18
+ date: 2017-11-29 00:00:00.000000000 Z
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency
21
21
  name: slack-notifier
@@ -828,7 +828,6 @@ files:
828
828
  - deliver/lib/deliver/upload_price_tier.rb
829
829
  - deliver/lib/deliver/upload_screenshots.rb
830
830
  - fastlane/README.md
831
- - fastlane/lib/.DS_Store
832
831
  - fastlane/lib/assets/ActionDetails.md.erb
833
832
  - fastlane/lib/assets/Actions.md.erb
834
833
  - fastlane/lib/assets/AppfileTemplate
@@ -846,10 +845,8 @@ files:
846
845
  - fastlane/lib/assets/s3_plist_template.erb
847
846
  - fastlane/lib/assets/s3_version_template.erb
848
847
  - fastlane/lib/fastlane.rb
849
- - fastlane/lib/fastlane/.DS_Store
850
848
  - fastlane/lib/fastlane/action.rb
851
849
  - fastlane/lib/fastlane/action_collector.rb
852
- - fastlane/lib/fastlane/actions/.DS_Store
853
850
  - fastlane/lib/fastlane/actions/README.md
854
851
  - fastlane/lib/fastlane/actions/actions_helper.rb
855
852
  - fastlane/lib/fastlane/actions/adb.rb
@@ -894,8 +891,6 @@ files:
894
891
  - fastlane/lib/fastlane/actions/deliver.rb
895
892
  - fastlane/lib/fastlane/actions/deploygate.rb
896
893
  - fastlane/lib/fastlane/actions/device_grid/README.md
897
- - fastlane/lib/fastlane/actions/docs/.DS_Store
898
- - fastlane/lib/fastlane/actions/docs/assets/.DS_Store
899
894
  - fastlane/lib/fastlane/actions/docs/assets/FrameitGit.gif
900
895
  - fastlane/lib/fastlane/actions/docs/assets/MacExample.png
901
896
  - fastlane/lib/fastlane/actions/docs/assets/PEMRecording.gif
@@ -1170,6 +1165,7 @@ files:
1170
1165
  - fastlane/lib/fastlane/setup/setup.rb
1171
1166
  - fastlane/lib/fastlane/setup/setup_android.rb
1172
1167
  - fastlane/lib/fastlane/setup/setup_ios.rb
1168
+ - fastlane/lib/fastlane/shells.rb
1173
1169
  - fastlane/lib/fastlane/supported_platforms.rb
1174
1170
  - fastlane/lib/fastlane/tools.rb
1175
1171
  - fastlane/lib/fastlane/version.rb
@@ -1509,24 +1505,24 @@ metadata:
1509
1505
  post_install_message:
1510
1506
  rdoc_options: []
1511
1507
  require_paths:
1512
- - cert/lib
1513
- - credentials_manager/lib
1514
- - deliver/lib
1515
- - fastlane/lib
1516
- - fastlane_core/lib
1517
- - frameit/lib
1518
- - gym/lib
1508
+ - supply/lib
1509
+ - screengrab/lib
1519
1510
  - match/lib
1520
- - pem/lib
1521
- - pilot/lib
1522
1511
  - precheck/lib
1512
+ - sigh/lib
1523
1513
  - produce/lib
1524
1514
  - scan/lib
1525
- - screengrab/lib
1526
- - sigh/lib
1515
+ - gym/lib
1527
1516
  - snapshot/lib
1517
+ - frameit/lib
1518
+ - fastlane/lib
1519
+ - cert/lib
1520
+ - pilot/lib
1528
1521
  - spaceship/lib
1529
- - supply/lib
1522
+ - credentials_manager/lib
1523
+ - deliver/lib
1524
+ - fastlane_core/lib
1525
+ - pem/lib
1530
1526
  required_ruby_version: !ruby/object:Gem::Requirement
1531
1527
  requirements:
1532
1528
  - - ">="
@@ -1534,15 +1530,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
1534
1530
  version: 2.0.0
1535
1531
  required_rubygems_version: !ruby/object:Gem::Requirement
1536
1532
  requirements:
1537
- - - ">="
1533
+ - - ">"
1538
1534
  - !ruby/object:Gem::Version
1539
- version: '0'
1535
+ version: 1.3.1
1540
1536
  requirements: []
1541
1537
  rubyforge_project:
1542
- rubygems_version: 2.6.8
1538
+ rubygems_version: 2.4.5.1
1543
1539
  signing_key:
1544
1540
  specification_version: 4
1545
1541
  summary: The easiest way to automate beta deployments and releases for your iOS and
1546
1542
  Android apps
1547
1543
  test_files: []
1548
- has_rdoc:
Binary file
Binary file