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

feat: Add configuration option for default architecture #3778

Merged
merged 3 commits into from
Dec 16, 2019

Conversation

Ash258
Copy link
Contributor

@Ash258 Ash258 commented Dec 4, 2019

Configuration name is subject of change. I am following dash notation for naming, until config is reworked and united (Related #3401)

Is boolean enough or it is prefered to go with scoop config 'default-architecture' '32bit|64bit' which could be more suitable for additional arch support (arm for example)

image

- Closes ScoopInstaller#3770

Configuration name is subject of change. I am following dash notation for naming, until config is reworked and united (Relateed ScoopInstaller#3401)

Is boolean enough or it is prefered to go with `scoop config 'default-architecture' '32bit|64bit'` which could be more suitable for additional arch support (arm for example)

![A](https://i.imgur.com/RBzEysd.png)
@niheaven
Copy link
Member

niheaven commented Dec 4, 2019

default-architecture is preferred for me.

@r15ch13
Copy link
Member

r15ch13 commented Dec 4, 2019

default-architecture with 32bit|64bit|arm sounds good to me. 👍

@niheaven
Copy link
Member

niheaven commented Dec 5, 2019

scoop should throw when user use some words other than 32bit or 64bit.

@Ash258
Copy link
Contributor Author

Ash258 commented Dec 5, 2019

I could potentially add else branch with ensure_architecture function check

Resulting to:

   if ($null -eq $arch) {
		if .... is64..
   } else {
       $arch = ensure_architecture $arch
   }

or to be more user friendly with something like this

try {
   $arch = ensure_architecture $arch
} catch {
	error 'Invalid default architecture configured'
}

@niheaven
Copy link
Member

niheaven commented Dec 6, 2019

Prefer try...cache 😄

Copy link
Member

@niheaven niheaven left a comment

Choose a reason for hiding this comment

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

LGTM

@r15ch13 r15ch13 merged commit 48bb96a into ScoopInstaller:develop Dec 16, 2019
@Ash258 Ash258 deleted the def32 branch December 23, 2019 11:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants