Skip to content

Commit

Permalink
Improvement: Improv error handling for missing export options on buil…
Browse files Browse the repository at this point in the history
…d-ipa (#51)

* Improve error handling for build-ipa action for missing export options

* Update changelog

* Restore project and workspace validation
  • Loading branch information
priitlatt authored Sep 11, 2020
1 parent 09074c7 commit 3bb2b0c
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 1 deletion.
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
Version 0.2.12
-------------

**Improvements**

- Improvement: Fail gracefully with appropriate error message when non-existent export options plist path is passed to `xcode-project build-ipa`.

Version 0.2.11
-------------

Expand Down
2 changes: 1 addition & 1 deletion src/codemagic/__version__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
__title__ = "codemagic-cli-tools"
__description__ = "CLI tools used in Codemagic builds"
__version__ = "0.2.11"
__version__ = "0.2.12"
__url__ = 'https://github.com/codemagic-ci-cd/cli-tools'
__licence__ = 'GNU General Public License v3.0'
3 changes: 3 additions & 0 deletions src/codemagic/tools/xcode_project.py
Original file line number Diff line number Diff line change
Expand Up @@ -302,6 +302,9 @@ def build_ipa(self,
if xcode_project_path is None and xcode_workspace_path is None:
error = 'Workspace or project argument needs to be specified'
XcodeProjectArgument.XCODE_WORKSPACE_PATH.raise_argument_error(error)
if not export_options_plist.is_file():
error = f'Path "{export_options_plist}" does not exist'
XcodeProjectArgument.EXPORT_OPTIONS_PATH.raise_argument_error(error)

xcarchive: Optional[pathlib.Path] = None
xcodebuild: Optional[Xcodebuild] = None
Expand Down

0 comments on commit 3bb2b0c

Please sign in to comment.