fastlane-plugin-xamarin 0.5.1 → 0.6.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: 5e6373ebed792383b070c77af61af724b85d65b9cdecc66e635ac63486639890
4
- data.tar.gz: ed3fbbc51626ab00579069fe14d9780fd834ca1ee0dc14b5ff1b504010594e0c
3
+ metadata.gz: f3c759ecdef6aefbe106ffa5f5eaa3db6fe94b11cadbf2c4c9ff8140416b2b0d
4
+ data.tar.gz: fa32c89768861dca52fe34f296943431817188c1216ebc2bb272915a374d55ac
5
5
  SHA512:
6
- metadata.gz: ee8375701bebba74a160d5075fb681143df76ed90b13faeb194da7b3499d87fb42b67dea7ba81b59801df10ecf9bbc564c6235b37145a47498bc7f535fd8c75e
7
- data.tar.gz: 726b3a209cc8da748f6f3e23168e08f975d1861ab335ddf33e392529a924ced5a3af53212fa85470452e0767503daa21f02a9d4a5334420cfbd321a6211ccaf3
6
+ metadata.gz: 328fc5fd5ed0930da55c37353078b12b4037d7988f749806a9e048a2f14304fd4b83ff842687cdbeb34ca55cd3b2b8105d7a50ba7df6867b0e186d78645c4f2d
7
+ data.tar.gz: 5c96a7ed64b21578f9d6bff2c5c765854affe4f4341eb197ceb4fd2f45d0ef83a1e2a63587489d9620e9cf546e039a8e67e96bc4c65fb9da6760474bb043b667
@@ -7,11 +7,17 @@ module Fastlane
7
7
  def self.run(params)
8
8
 
9
9
  Dir.glob('**/bin').each do |f|
10
- FileUtils.rm_rf(f) if File.directory?(f)
10
+ if File.directory?(f)
11
+ UI.message("Deleting #{f}") if FastlaneCore::Globals.verbose?
12
+ FileUtils.rm_rf(f)
13
+ end
11
14
  end
12
15
 
13
16
  Dir.glob('**/obj').each do |f|
14
- FileUtils.rm_rf(f) if File.directory?(f)
17
+ if File.directory?(f)
18
+ UI.message("Deleting #{f}") if FastlaneCore::Globals.verbose?
19
+ FileUtils.rm_rf(f)
20
+ end
15
21
  end
16
22
 
17
23
  end
@@ -36,11 +42,10 @@ module Fastlane
36
42
  def self.available_options
37
43
  [
38
44
  ]
39
-
40
45
  end
41
46
 
42
47
  def self.is_supported?(platform)
43
- [:android, :ios].include?(platform)
48
+ [:android, :ios, :mac].include?(platform)
44
49
  end
45
50
  end
46
51
  end
@@ -0,0 +1,124 @@
1
+ module Fastlane
2
+ module Actions
3
+
4
+ class MsbuildAction < Action
5
+ def self.run(params)
6
+
7
+ msbuild = params[:msbuild] || FastlaneCore::CommandExecutor.which('msbuild')
8
+
9
+ if msbuild.nil?
10
+ UI.error("Could not find msbuild")
11
+ return
12
+ end
13
+
14
+ if FastlaneCore::Globals.verbose?
15
+ FastlaneCore::PrintTable.print_values(
16
+ config: params,
17
+ title: "Summary of parameters passed"
18
+ )
19
+ end
20
+ command = Array.new
21
+
22
+ command.push(msbuild)
23
+ command.push(params[:project])
24
+ command.push("/t:#{params[:target]}")
25
+ command.push("/p:Configuration=#{params[:configuration]}") unless params[:configuration].nil?
26
+ command.push("/p:DefineConstants=#{params[:define_constants]}") unless params[:define_constants].nil?
27
+ command.push("/p:DebugType=#{params[:debug_type]}") unless params[:debug_type].nil?
28
+
29
+ if FastlaneCore::Globals.verbose?
30
+ command.push("/v:d")
31
+ else
32
+ command.push("/v:m")
33
+ end
34
+
35
+
36
+ exit_status = 0
37
+ result = FastlaneCore::CommandExecutor.execute(command: command,
38
+ print_command: true,
39
+ print_all: FastlaneCore::Globals.verbose?,
40
+ error: proc do |error_output|
41
+ exit_status = $?.exitstatus
42
+ UI.error("Wups, invalid")
43
+ end)
44
+
45
+ if exit_status == 0
46
+ UI.success("Successfully executed msbuild")
47
+ else
48
+ UI.error!("Unable to build - see log for more info")
49
+ end
50
+
51
+
52
+ end
53
+
54
+ def self.description
55
+ "Build Solutions with msbuild"
56
+ end
57
+
58
+ def self.authors
59
+ ["Thomas Charriere"]
60
+ end
61
+
62
+ def self.return_value
63
+ # If your method provides a return value, you can describe here what it does
64
+ end
65
+
66
+ def self.details
67
+ # Optional:
68
+ "Build Solutions with msbuild"
69
+ end
70
+
71
+ def self.output
72
+ [
73
+ ]
74
+ end
75
+
76
+ def self.available_options
77
+ [
78
+ FastlaneCore::ConfigItem.new(key: :project,
79
+ env_name: "MSBUILD_SOLUTION",
80
+ description: "Path to Solution (.sln) to compile",
81
+ optional: false,
82
+ type: String),
83
+
84
+ FastlaneCore::ConfigItem.new(key: :target,
85
+ env_name: "MSBUILD_TARGET",
86
+ description: "Specifies the Build Targets: Build",
87
+ default_value: 'Build',
88
+ optional: true,
89
+ type: String),
90
+
91
+ FastlaneCore::ConfigItem.new(key: :configuration,
92
+ env_name: "MSBUILD_CONFIGURATION",
93
+ description: "Specifies the build configuration to use, such as 'Debug' or 'Release'. The Configuration property is used to determine default values for other properties which determine target behavior. Additional configurations may be created within your IDE",
94
+ default_value: 'Release',
95
+ optional: true,
96
+ type: String),
97
+
98
+ FastlaneCore::ConfigItem.new(key: :msbuild,
99
+ env_name: "MSBUILD_MSBUILD",
100
+ description: "Path to `msbuild`. Default value is found by using `which msbuild`",
101
+ optional: true,
102
+ type: String),
103
+
104
+ FastlaneCore::ConfigItem.new(key: :debug_type,
105
+ env_name: "MSBUILD_DEBUGTYPE",
106
+ description: "Specifies the type of debug symbols to generate as part of the build, which also impacts whether the Application is debuggable. Possible values include: Full, PdbOnly",
107
+ optional: true,
108
+ type: String),
109
+
110
+ FastlaneCore::ConfigItem.new(key: :define_constants,
111
+ env_name: "MSBUILD_DEFINECONSTANTS",
112
+ description: "Defines conditional compiler constants",
113
+ optional: true,
114
+ type: String)
115
+ ]
116
+
117
+ end
118
+
119
+ def self.is_supported?(platform)
120
+ [:android, :ios, :mac].include?(platform)
121
+ end
122
+ end
123
+ end
124
+ end
@@ -0,0 +1,102 @@
1
+ module Fastlane
2
+ module Actions
3
+ class NugetInstallAction < Action
4
+ def self.run(params)
5
+
6
+ nuget = params[:nuget] || FastlaneCore::CommandExecutor.which('nuget')
7
+
8
+ if nuget.nil?
9
+ UI.error("Could not find nuget")
10
+ return
11
+ end
12
+
13
+ if FastlaneCore::Globals.verbose?
14
+ FastlaneCore::PrintTable.print_values(
15
+ config: params,
16
+ title: "Summary of parameters passed"
17
+ )
18
+ end
19
+ command = Array.new
20
+
21
+ command.push(nuget)
22
+ command.push("install")
23
+ command.push(params[:config_file_path] || params[:package_id])
24
+ command.push("-OutputDirectory") unless params[:output_directory].nil?
25
+ command.push(params[:output_directory]) unless params[:output_directory].nil?
26
+
27
+ command.push("-Verbosity")
28
+ if FastlaneCore::Globals.verbose?
29
+ command.push("detailed")
30
+ else
31
+ command.push("normal")
32
+ end
33
+
34
+ exit_status = 0
35
+ result = FastlaneCore::CommandExecutor.execute(command: command,
36
+ print_command: true,
37
+ print_all: FastlaneCore::Globals.verbose?,
38
+ error: proc do |error_output|
39
+ exit_status = $?.exitstatus
40
+ end)
41
+
42
+ if exit_status == 0
43
+ UI.success("Successfully executed nuget")
44
+ else
45
+ UI.error!("Uhh ohh - failed executing nuget")
46
+ end
47
+
48
+
49
+ end
50
+
51
+ def self.description
52
+ "Nuget"
53
+ end
54
+
55
+ def self.authors
56
+ ["Thomas Charriere"]
57
+ end
58
+
59
+ def self.return_value
60
+ # If your method provides a return value, you can describe here what it does
61
+ end
62
+
63
+ def self.details
64
+ "Nuget restore"
65
+ end
66
+
67
+
68
+ def self.available_options
69
+ [
70
+ FastlaneCore::ConfigItem.new(key: :config_file_path,
71
+ env_name: "NUGET_CONFIGFILEPATH",
72
+ description: "Identifies the packages.config file that lists the packages to install.",
73
+ optional: false,
74
+ type: String),
75
+
76
+ FastlaneCore::ConfigItem.new(key: :package_id,
77
+ env_name: "NUGET_PACKAGEID",
78
+ description: "The package to install (using the latest version)",
79
+ optional: false,
80
+ type: String),
81
+
82
+ FastlaneCore::ConfigItem.new(key: :nuget,
83
+ env_name: "NUGET_PATH",
84
+ description: "Path to `nuget`. Default value is found by using `which nuget`",
85
+ optional: true,
86
+ type: String),
87
+
88
+ FastlaneCore::ConfigItem.new(key: :output_directory,
89
+ env_name: "NUGET_OUTPUT_DIRECTORY",
90
+ description: "Specifies the folder in which packages are installed. If no folder is specified, the current folder is used.",
91
+ optional: true,
92
+ type: String),
93
+ ]
94
+
95
+ end
96
+
97
+ def self.is_supported?(platform)
98
+ [:android, :ios].include?(platform)
99
+ end
100
+ end
101
+ end
102
+ end
@@ -35,7 +35,7 @@ module Fastlane
35
35
  if exit_status == 0
36
36
  UI.success("Successfully executed nuget")
37
37
  else
38
- UI.error("Uhh ohh - failed executing nuget")
38
+ UI.error!("Uhh ohh - failed executing nuget")
39
39
  end
40
40
 
41
41
 
@@ -41,6 +41,12 @@ module Fastlane
41
41
  command.push("/p:AndroidSigningKeyStore=#{params[:android_signing_keystore]}") unless params[:android_signing_keystore].nil?
42
42
  command.push("/p:AndroidSigningStorePass=#{params[:android_signing_storepass]}") unless params[:android_signing_storepass].nil?
43
43
 
44
+ if FastlaneCore::Globals.verbose?
45
+ command.push("/v:d")
46
+ else
47
+ command.push("/v:m")
48
+ end
49
+
44
50
  exit_status = 0
45
51
  result = FastlaneCore::CommandExecutor.execute(command: command,
46
52
  print_command: true,
@@ -70,7 +76,7 @@ module Fastlane
70
76
  )
71
77
 
72
78
  else
73
- UI.error("Unable to build - see log for more info")
79
+ UI.error!("Unable to build - see log for more info")
74
80
  end
75
81
 
76
82
 
@@ -36,6 +36,12 @@ module Fastlane
36
36
  command.push("/p:CodesignKey=#{params[:codesign_key]}") unless params[:codesign_key].nil?
37
37
  command.push("/p:CodesignProvision=#{params[:codesign_provision]}") unless params[:codesign_provision].nil?
38
38
 
39
+ if FastlaneCore::Globals.verbose?
40
+ command.push("/v:d")
41
+ else
42
+ command.push("/v:m")
43
+ end
44
+
39
45
  exit_status = 0
40
46
  result = FastlaneCore::CommandExecutor.execute(command: command,
41
47
  print_command: true,
@@ -76,7 +82,7 @@ module Fastlane
76
82
  )
77
83
 
78
84
  else
79
- UI.error("Unable to build - see log for more info")
85
+ UI.error!("Unable to build - see log for more info")
80
86
  end
81
87
 
82
88
 
@@ -1,5 +1,5 @@
1
1
  module Fastlane
2
2
  module Xamarin
3
- VERSION = "0.5.1"
3
+ VERSION = "0.6.0"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fastlane-plugin-xamarin
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.1
4
+ version: 0.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Thomas Charriere
@@ -104,6 +104,8 @@ files:
104
104
  - README.md
105
105
  - lib/fastlane/plugin/xamarin.rb
106
106
  - lib/fastlane/plugin/xamarin/actions/clean_action.rb
107
+ - lib/fastlane/plugin/xamarin/actions/msbuild_action.rb
108
+ - lib/fastlane/plugin/xamarin/actions/nuget_install_action.rb
107
109
  - lib/fastlane/plugin/xamarin/actions/nuget_restore_action.rb
108
110
  - lib/fastlane/plugin/xamarin/actions/xamarin_android_action.rb
109
111
  - lib/fastlane/plugin/xamarin/actions/xamarin_ios_action.rb