fastlane-plugin-appbox 3.4.0 → 4.0.0

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
  SHA256:
3
- metadata.gz: 5ac49ed2e0a409764830fb7855c1791757fe94118bcb569a9da553aef9c5e3b8
4
- data.tar.gz: fd5191b76fffc00f4d6142ffdc5df137c72839806a08674e63f7598d996fd663
3
+ metadata.gz: 3db84f527f2c015f99d005447b3f209bfca6a1c020ca56fed4a099eb13ceff6e
4
+ data.tar.gz: fd340764d6fa68040b93ec7f7b88874850eadc71ae2eb2a67cd0666f620f78f5
5
5
  SHA512:
6
- metadata.gz: dcc94414c7c62001123af387ea4aa5c5d427c0c566fa2914a35fe1e6a4094cb2204adf5259ffe076ff6692559082f1f161e0282f1f43ecf02d7042608f2486a4
7
- data.tar.gz: 6462fcc5ce569eee114cb886a805931670cfbe3fd63128e64c65b6b70579354da1fb6a69f37954a7295151360efed4cf1a1055c4a2265794101db8931287785d
6
+ metadata.gz: f1ee9fbc055c6c129638af19988c734229a1bde2b0466e83d230b115d2bf80318e792153eb49cfa8714280765cdaf45a5a1a095d9a66ee8d70909b59cd81f6ba
7
+ data.tar.gz: 5729b9846272dc136a5d413195c1d44110f56a779e65355e7f44e5edbb39043107fdb662156317bf5dda83f1b800a327a6c8daadc3bd2b8e67c2a3024dff45d7
data/README.md CHANGED
@@ -10,17 +10,28 @@
10
10
  fastlane add_plugin appbox
11
11
  ```
12
12
 
13
- **Step 2** - Download the latest version of AppBox from [here](https://github.com/vineetchoudhary/AppBox-iOSAppsWirelessInstallation/releases) or [here](https://getappbox.com/download) and install it into `/Applications` directory of you mac. Now, open AppBox and login with your Dropbox account.
13
+ **Step 2** - Install AppBox using one of the following methods:
14
+
15
+ - **Direct Install:**
16
+ ```bash
17
+ curl -s https://getappbox.com/install.sh | bash
18
+ ```
19
+
20
+ - **Homebrew:**
21
+ ```bash
22
+ brew install --cask appbox
23
+ ```
24
+
25
+ Now, open AppBox and login with your Dropbox account.
14
26
 
15
27
  **Step 3** - Define appbox action in your project Fastfile with emails and message. Here the available params for appbox plugins -
16
28
 
17
- - `emails` (Required | String) - Comma-separated list of email address that should receive application installation link.
18
- - `message` (Optional | String) - Attach personal message in the email. Supported Keywords:
19
- >The {PROJECT_NAME} - For Project Name,
20
- >{BUILD_VERSION} - For Build Version, and
21
- >{BUILD_NUMBER} - For Build Number.
22
- - `appbox_path` (Optional | String) - If you've setup AppBox in the different directory then you need to mention that here. Default is `/Applications/AppBox.app`
29
+ - `emails` (Optional | String) - Comma-separated list of email address that should receive application installation link.
30
+ - `message` (Optional | String) - A personal message shown under "Message from the developer" in the email. Sent verbatim — AppBox 4 no longer substitutes `{PROJECT_NAME}` / `{BUILD_VERSION}` / `{BUILD_NUMBER}` placeholders, so build them yourself from fastlane's own variables (see the examples below).
23
31
  - `keep_same_link` (Optional | Bool) - This feature will keep same short URL for all future build/IPA uploaded with same bundle identifier. If this option is enabled, you can also download the previous build with the same URL. Read more [here](https://docs.getappbox.com/Features/keepsamelink/).
32
+ - `slack_webhook_url` (Optional | String) - Slack Incoming Webhook URL to post a notification to a Slack channel.
33
+ - `ms_teams_webhook_url` (Optional | String) - Microsoft Teams Incoming Webhook URL to post a notification to a Teams channel.
34
+ - `webhook_message` (Optional | String) - **Deprecated and ignored since AppBox 4.** The CLI prints a note and generates the notification text from the build itself. Still accepted so existing Fastfiles keep working.
24
35
  - `dropbox_folder_name` (Optional | String) - You can change the link by providing a Custom Dropbox Folder Name. By default folder name will be the application bundle identifier. So, AppBox will keep the same link for the IPA file available in the same folder. Read more [here](https://docs.getappbox.com/Features/keepsamelink/).
25
36
 
26
37
 
@@ -50,7 +61,7 @@ platform :ios do
50
61
  lane :gymbox do
51
62
  gym
52
63
  appbox(
53
- emails: 'you@example.com,'someoneelse@example.com',
64
+ emails: 'you@example.com,someoneelse@example.com',
54
65
  )
55
66
  end
56
67
  end
@@ -66,7 +77,7 @@ platform :ios do
66
77
  gym
67
78
  appbox(
68
79
  emails: 'you@example.com',
69
- message: '{PROJECT_NAME} - {BUILD_VERSION}({BUILD_NUMBER}) is ready to test.',
80
+ message: "#{lane_context[SharedValues::IPA_OUTPUT_PATH] ? File.basename(lane_context[SharedValues::IPA_OUTPUT_PATH], '.ipa') : 'Build'} is ready to test.",
70
81
  )
71
82
  end
72
83
  end
@@ -82,7 +93,7 @@ platform :ios do
82
93
  gym
83
94
  appbox(
84
95
  emails: 'you@example.com',
85
- message: '{PROJECT_NAME} - {BUILD_VERSION}({BUILD_NUMBER}) is ready to test.',
96
+ message: "#{lane_context[SharedValues::IPA_OUTPUT_PATH] ? File.basename(lane_context[SharedValues::IPA_OUTPUT_PATH], '.ipa') : 'Build'} is ready to test.",
86
97
  keep_same_link: true,
87
98
  )
88
99
  end
@@ -99,7 +110,7 @@ platform :ios do
99
110
  gym
100
111
  appbox(
101
112
  emails: 'you@example.com',
102
- message: '{PROJECT_NAME} - {BUILD_VERSION}({BUILD_NUMBER}) is ready to test.',
113
+ message: "#{lane_context[SharedValues::IPA_OUTPUT_PATH] ? File.basename(lane_context[SharedValues::IPA_OUTPUT_PATH], '.ipa') : 'Build'} is ready to test.",
103
114
  keep_same_link: true,
104
115
  dropbox_folder_name: 'Fastlane-Demo-Keep-Same-Link',
105
116
  )
@@ -107,33 +118,17 @@ platform :ios do
107
118
  end
108
119
  ```
109
120
 
110
- #### 6. Upload IPA file where AppBox available at some custom path instead of macOS Application Directory.
111
-
112
- ```rb
113
- default_platform(:ios)
114
-
115
- platform :ios do
116
- lane :gymbox do
117
- gym
118
- appbox(
119
- emails: 'you@example.com,'someoneelse@example.com',
120
- appbox_path:'/Users/vineetchoudhary/Desktop/AppBox2.8.0/AppBox.app',
121
- )
122
- end
123
- end
124
- ```
121
+ #### Note
122
+ When you run this for the first time, a pop-up will appear stating that "Terminal.app" wants to access data from other apps. You must allow this to copy the IPA file to the Appbox temporary directory, enabling Appbox to access and upload it.
123
+ ![](/AppBox-Fastlane-Demo-Project/images/terminal-permission.webp)
125
124
 
126
125
  ## 3. Supported AppBox link access via Fastlane SharedValues
127
126
  - `APPBOX_SHARE_URL` - AppBox short shareable URL to install uploaded application.
128
127
  - `APPBOX_IPA_URL`- Upload IPA file URL to download IPA file.
129
128
  - `APPBOX_MANIFEST_URL` - Manifest file URL for upload application.
130
- - `APPBOX_LONG_SHARE_UR` - AppBox long shareable URL to install uploaded application.
131
-
132
- ![](/AppBox-Fastlane-Demo-Project/AppBoxFastlane.gif)
133
-
134
129
 
135
130
  ## 4. About AppBox
136
- [AppBox](https://getappbox.com) is a tool for iOS developers to build and deploy Development, Ad-Hoc and In-house (Enterprise) applications directly to the devices from your Dropbox account. Also, available on [Github](https://github.com/vineetchoudhary/AppBox-iOSAppsWirelessInstallation).
131
+ [AppBox](https://getappbox.com) is a tool for iOS developers to build and deploy Development, Ad-Hoc and In-house (Enterprise) applications directly to the devices from your Dropbox account. Also, available on [Github](https://github.com/getappbox/AppBox-iOSAppsWirelessInstallation).
137
132
 
138
133
  ## 5. Example
139
134
 
@@ -142,6 +137,6 @@ Check out the [example `Fastfile`](fastlane/Fastfile) to see how to use this plu
142
137
  ## 6. Issues and Feedback
143
138
  For any other issues and feedback about this plugin, please submit it to this [repository](https://github.com/getappbox/fastlane-plugin-appbox/issues/new).
144
139
 
145
- ## 6. Troubleshooting
140
+ ## 7. Troubleshooting
146
141
  If you have trouble using plugins, check out the [Plugins Troubleshooting](https://docs.fastlane.tools/plugins/plugins-troubleshooting/) guide.
147
142
 
@@ -1,4 +1,5 @@
1
1
  require "json"
2
+ require "shellwords"
2
3
  require 'fastlane/action'
3
4
  require_relative '../helper/appbox_helper'
4
5
 
@@ -8,111 +9,97 @@ module Fastlane
8
9
  APPBOX_IPA_URL = :APPBOX_IPA_URL
9
10
  APPBOX_SHARE_URL = :APPBOX_SHARE_URL
10
11
  APPBOX_MANIFEST_URL = :APPBOX_MANIFEST_URL
11
- APPBOX_LONG_SHARE_URL = :APPBOX_LONG_SHARE_URL
12
12
  end
13
13
 
14
14
  class AppboxAction < Action
15
15
  def self.run(params)
16
- #emails param
16
+
17
+ #custom dropbox folder name
18
+ if params[:dropbox_folder_name]
19
+ dropbox_folder_name = params[:dropbox_folder_name]
20
+ UI.message("Dropbox folder name - #{dropbox_folder_name}")
21
+ end
22
+
23
+ # AppBox CLI
24
+ appboxcli = "appboxcli"
25
+ appboxcli_path = `which #{appboxcli}`.strip
26
+ if appboxcli_path.empty?
27
+ UI.user_error!("AppBox CLI not found. Install it from AppBox Preferences > General, or read more here - https://docs.getappbox.com/CommandLineInterface/")
28
+ end
29
+
30
+ ipa_path = Actions.lane_context[Actions::SharedValues::IPA_OUTPUT_PATH]
31
+ if ipa_path.nil? || ipa_path.to_s.empty?
32
+ UI.user_error!("No IPA found. Run `gym`/`build_app` before `appbox`, or set lane_context[SharedValues::IPA_OUTPUT_PATH] yourself.")
33
+ end
34
+ UI.user_error!("IPA not found at #{ipa_path}") unless File.exist?(ipa_path)
35
+ UI.message("IPA PATH - #{ipa_path}")
36
+
37
+ # Start AppBox
38
+ UI.message("")
39
+ UI.message("Starting AppBox...")
40
+ UI.message("Upload process will start soon. Upload process might take a few minutes. Please don't interrupt the script.")
41
+
42
+ # Built as an argv array and run without a shell, so a value containing a
43
+ # quote or a space cannot break the command.
44
+ args = [appboxcli, "--ipa", ipa_path.to_s]
45
+
17
46
  if params[:emails]
18
- emails = params[:emails]
19
- UI.message("Emails - #{emails}")
47
+ args += ["--emails", params[:emails].to_s]
48
+ UI.message("Emails - #{params[:emails]}")
20
49
  end
21
50
 
22
- #developer personal message param
23
51
  if params[:message]
24
- message = params[:message]
25
- UI.message("Message - #{message}")
52
+ args += ["--message", params[:message].to_s]
53
+ UI.message("Message - #{params[:message]}")
26
54
  end
27
55
 
28
- #keep same linkparam
29
- if params[:keep_same_link]
30
- keep_same_link = params[:keep_same_link]
31
- UI.message("Keep Same Link - #{keep_same_link}")
56
+ if params[:keep_same_link] == true
57
+ args << "--keepsamelink"
58
+ UI.message("Keep Same Link - #{params[:keep_same_link]}")
32
59
  end
33
60
 
34
- #custom dropbox folder name
35
- if params[:dropbox_folder_name]
36
- dropbox_folder_name = params[:dropbox_folder_name]
37
- UI.message("Dropbox folder name - #{dropbox_folder_name}")
61
+ if dropbox_folder_name
62
+ args += ["--dbfolder", dropbox_folder_name.to_s]
63
+ UI.message("Dropbox Folder Name - #{dropbox_folder_name}")
38
64
  end
39
65
 
40
- #AppBox Path
41
- if params[:appbox_path]
42
- appbox_path = "#{params[:appbox_path]}/Contents/MacOS/AppBox"
43
- else
44
- appbox_path = "/Applications/AppBox.app/Contents/MacOS/AppBox"
66
+ if params[:slack_webhook_url]
67
+ args += ["--slackwebhook", params[:slack_webhook_url].to_s]
68
+ UI.message("Slack Webhook URL - #{params[:slack_webhook_url]}")
45
69
  end
46
70
 
47
- #Check if AppBox exist at given path
48
- if File.file?(appbox_path)
49
- UI.message("")
50
- UI.message("AppBox Path - #{appbox_path}")
51
-
52
- ipa_path = Actions.lane_context[ Actions::SharedValues::IPA_OUTPUT_PATH ]
53
- ipa_file_name = File.basename(ipa_path)
54
- UI.message("IPA PATH - #{ipa_path}")
55
-
56
- # Copy ipa file into AppBox temporary directory
57
- appbox_data_dir = File.expand_path("~/Library/Containers/com.developerinsider.AppBox/Data")
58
- appbox_temp_path = File.join(appbox_data_dir, "tmp")
59
- UI.message("Copying IPA file to AppBox temporary directory - #{appbox_temp_path}")
60
- FileUtils.cp ipa_path, appbox_temp_path
61
- temp_ipa_path = File.join(appbox_temp_path, ipa_file_name)
62
-
63
- # Start AppBox
64
- UI.message("")
65
- UI.message("Starting AppBox...")
66
- UI.message("Upload process will start soon. Upload process might take a few minutes. Please don't interrupt the script.")
67
- if dropbox_folder_name
68
- exit_status = system("exec #{appbox_path} ipa='#{temp_ipa_path}' email='#{emails}' message='#{message}' keepsamelink=#{keep_same_link} dbfolder='#{dropbox_folder_name}'")
69
- else
70
- exit_status = system("exec #{appbox_path} ipa='#{temp_ipa_path}' email='#{emails}' message='#{message}' keepsamelink='#{keep_same_link}'")
71
- end
71
+ if params[:ms_teams_webhook_url]
72
+ args += ["--msteamswebhook", params[:ms_teams_webhook_url].to_s]
73
+ UI.message("MS Teams Webhook URL - #{params[:ms_teams_webhook_url]}")
74
+ end
72
75
 
73
- # Print upload status
74
- if exit_status
75
- UI.success("Successfully uploaded the IPA file to DropBox. Check below summary for more details.")
76
- # Check if share url file exist and print value
77
- share_url_file_path = File.join(appbox_data_dir, "Documents", ".appbox_share_value.json")
78
- if File.file?(share_url_file_path)
79
- file = File.read(share_url_file_path)
80
- share_urls_values = JSON.parse(file)
81
-
82
- Actions.lane_context[SharedValues::APPBOX_IPA_URL] = share_urls_values['APPBOX_IPA_URL']
83
- Actions.lane_context[SharedValues::APPBOX_SHARE_URL] = share_urls_values['APPBOX_SHARE_URL']
84
- Actions.lane_context[SharedValues::APPBOX_MANIFEST_URL] = share_urls_values['APPBOX_MANIFEST_URL']
85
-
86
- FastlaneCore::PrintTable.print_values(config: share_urls_values, hide_keys: [], title: "Summary for AppBox")
87
- end
88
- clean_temporary_files(appbox_temp_path)
89
- UI.success('AppBox finished successfully')
90
- else
91
- clean_temporary_files(appbox_temp_path)
92
- UI.error('AppBox finished with errors')
93
- UI.message('Please feel free to open an issue on the project GitHub page. Please include a description of what is not working right with your issue. https://github.com/getappbox/fastlane-plugin-appbox/issues/new')
94
- exit
95
- end
96
- else
97
- UI.error("AppBox not found at path #{appbox_path}. Please download (https://getappbox.com/download) and install appbox first. ")
98
- exit
76
+ if params[:webhook_message]
77
+ args += ["--webhookmessage", params[:webhook_message].to_s]
78
+ UI.message("Webhook Message - #{params[:webhook_message]}")
99
79
  end
100
-
101
- end
102
80
 
103
- # Delete all files/folders in AppBox temporary directory
104
- def self.clean_temporary_files(appbox_temp_path)
105
- UI.message("Cleaning AppBox temporary directory - #{appbox_temp_path}")
106
- if File.directory?(appbox_temp_path)
107
- Dir.foreach(appbox_temp_path) do |file|
108
- next if file == '.' or file == '..'
109
- file_path = File.join(appbox_temp_path, file)
110
- if File.file?(file_path)
111
- File.delete(file_path)
112
- else
113
- FileUtils.rm_rf(file_path)
114
- end
81
+ UI.message("AppBox Command - #{Shellwords.join(args)}")
82
+
83
+ # Execute without a shell.
84
+ exit_status = system(*args)
85
+
86
+ # Print upload status
87
+ if exit_status
88
+ UI.success("Successfully uploaded the IPA file to DropBox. Check below summary for more details.")
89
+ # Check if share url file exist and print value
90
+ share_url_file_path = File.join(File.expand_path('~'), ".appbox_share_value.json")
91
+ if File.file?(share_url_file_path)
92
+ file = File.read(share_url_file_path)
93
+ share_urls_values = JSON.parse(file)
94
+ Actions.lane_context[SharedValues::APPBOX_IPA_URL] = share_urls_values['APPBOX_IPA_URL']
95
+ Actions.lane_context[SharedValues::APPBOX_SHARE_URL] = share_urls_values['APPBOX_SHARE_URL']
96
+ Actions.lane_context[SharedValues::APPBOX_MANIFEST_URL] = share_urls_values['APPBOX_MANIFEST_URL']
97
+ FastlaneCore::PrintTable.print_values(config: share_urls_values, hide_keys: [], title: "Summary for AppBox")
115
98
  end
99
+ UI.success('AppBox finished successfully')
100
+ else
101
+ UI.error('AppBox finished with errors')
102
+ UI.user_error!('AppBox upload failed. Please feel free to open an issue on the project GitHub page, including a description of what is not working. https://github.com/getappbox/fastlane-plugin-appbox/issues/new')
116
103
  end
117
104
  end
118
105
 
@@ -121,7 +108,6 @@ module Fastlane
121
108
  ['APPBOX_IPA_URL', 'Upload IPA file URL to download IPA file.'],
122
109
  ['APPBOX_MANIFEST_URL', 'Manifest file URL for upload application.'],
123
110
  ['APPBOX_SHARE_URL', 'AppBox short shareable URL to install uploaded application.'],
124
- ['APPBOX_LONG_SHARE_URL', 'AppBox long shareable URL to install uploaded application.']
125
111
  ]
126
112
  end
127
113
 
@@ -142,16 +128,11 @@ module Fastlane
142
128
  FastlaneCore::ConfigItem.new(key: :emails,
143
129
  env_name: "FL_APPBOX_EMAILS",
144
130
  description: "Comma-separated list of email address that should receive application installation link",
145
- optional: false),
146
-
147
- FastlaneCore::ConfigItem.new(key: :appbox_path,
148
- env_name: "FL_APPBOX_PATH",
149
- description: "If you've setup AppBox in the different directory then you need to mention that here. Default is '/Applications/AppBox.app'",
150
131
  optional: true),
151
132
 
152
133
  FastlaneCore::ConfigItem.new(key: :message,
153
134
  env_name: "FL_APPBOX_MESSAGE",
154
- description: "Attach personal message in the email. Supported Keywords: The {PROJECT_NAME} - For Project Name, {BUILD_VERSION} - For Build Version, and {BUILD_NUMBER} - For Build Number",
135
+ description: "A personal message shown under \"Message from the developer\" in the email. Sent verbatim; AppBox 4 does not substitute {BUILD_NAME}/{BUILD_VERSION}/{BUILD_NUMBER} placeholders",
155
136
  optional: true),
156
137
 
157
138
  FastlaneCore::ConfigItem.new(key: :keep_same_link,
@@ -165,6 +146,21 @@ module Fastlane
165
146
  env_name: "FL_APPBOX_DB_FOLDER_NAME",
166
147
  description: "You can change the link by providing a Custom Dropbox Folder Name. By default folder name will be the application bundle identifier. So, AppBox will keep the same link for the IPA file available in the same folder. Read more here - https://docs.getappbox.com/Features/keepsamelink/",
167
148
  optional: true),
149
+
150
+ FastlaneCore::ConfigItem.new(key: :slack_webhook_url,
151
+ env_name: "FL_APPBOX_SLACK_WEBHOOK_URL",
152
+ description: "Slack Incoming Webhook URL to send notification to a Slack channel",
153
+ optional: true),
154
+
155
+ FastlaneCore::ConfigItem.new(key: :ms_teams_webhook_url,
156
+ env_name: "FL_APPBOX_MS_TEAMS_WEBHOOK_URL",
157
+ description: "Microsoft Teams Incoming Webhook URL to send notification to a Teams channel",
158
+ optional: true),
159
+
160
+ FastlaneCore::ConfigItem.new(key: :webhook_message,
161
+ env_name: "FL_APPBOX_WEBHOOK_MESSAGE",
162
+ description: "Deprecated and ignored since AppBox 4 — the notification text is generated from the build. Accepted so existing Fastfiles keep working",
163
+ optional: true),
168
164
  ]
169
165
  end
170
166
 
@@ -1,5 +1,5 @@
1
1
  module Fastlane
2
2
  module Appbox
3
- VERSION = "3.4.0"
3
+ VERSION = "4.0.0"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fastlane-plugin-appbox
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.4.0
4
+ version: 4.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Vineet Choudhary
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-05-24 00:00:00.000000000 Z
11
+ date: 2026-09-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: pry
@@ -167,7 +167,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
167
167
  - !ruby/object:Gem::Version
168
168
  version: '0'
169
169
  requirements: []
170
- rubygems_version: 3.5.23
170
+ rubygems_version: 3.5.22
171
171
  signing_key:
172
172
  specification_version: 4
173
173
  summary: Deploy Development, Ad-Hoc and In-house (Enterprise) iOS applications directly