Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exit immediately if trying to select currently selected xcode #181

Merged
merged 3 commits into from Sep 29, 2022

Conversation

tahirmt
Copy link
Contributor

@tahirmt tahirmt commented Jan 31, 2022

If the currently requested xcode is already selected, there is no need to prompt the user to give sudo permissions and re-select the path. We can just avoid the step and exit early.

Closes #102

@tahirmt tahirmt requested a review from a team as a code owner January 31, 2022 04:31
@tahirmt tahirmt force-pushed the select-current-exit-immediately branch 2 times, most recently from 91e3655 to eb8e698 Compare February 4, 2022 05:25
@tahirmt tahirmt force-pushed the select-current-exit-immediately branch 2 times, most recently from c3712ce to fbe2b25 Compare March 17, 2022 18:27
Copy link
Contributor

@rogerluan rogerluan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, just 2 nitpicks :)

Sources/XcodesKit/XcodeSelect.swift Outdated Show resolved Hide resolved
Sources/XcodesKit/XcodeSelect.swift Outdated Show resolved Hide resolved
tahirmt and others added 3 commits September 19, 2022 22:02
If the currently requested xcode is already selected, there is no need to prompt the user to give sudo permissions and re-select the path. We can just avoid the step and exit early.
Co-authored-by: Roger Oba <rogerluan.oba@gmail.com>
@tahirmt tahirmt force-pushed the select-current-exit-immediately branch from 0b43aee to 030ac5f Compare September 20, 2022 02:02
@rogerluan
Copy link
Contributor

@MattKiazyk just a heads up that this PR could/should be merged before #182 🤗 #182 branched off of this one :)

Copy link
Contributor

@MattKiazyk MattKiazyk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @tahirmt sorry for the delayed approval

@MattKiazyk MattKiazyk merged commit 93dcc92 into XcodesOrg:main Sep 29, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Selecting the currently-selected Xcode version should finish immediately
3 participants