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

Fix mktemp usage on Mac OS, and handling of environments where GPG is not available #2027

Merged
merged 1 commit into from
Nov 24, 2016

Conversation

Daniel15
Copy link
Member

Summary
Fixes two issues with the install script:

  • Old versions of Mac OS (10.10 and below) require the -t option for mktemp
  • The check for GPG wasn't returning correctly, and tried to run GPG even when not available

Test plan
mv /usr/bin/gpg /usr/bin/gpg-old and run install script. Ensure output looks like:

> WARNING: GPG is not installed, integrity can not be verified!
> Extracting to ~/.yarn...
> Adding to $PATH...

Move /usr/bin/gpg-old back to /usr/bin/gpg, ensure GPG is ran:

> Verifying integrity...
gpg: Signature made Mon 21 Nov 2016 10:18:40 PM STD using RSA key ID FD2497F5
gpg: Good signature from "Yarn Packaging <yarn@dan.cx>"
gpg: WARNING: This key is not certified with a trusted signature!
gpg:          There is no indication that the signature belongs to the owner.
Primary key fingerprint: 72EC F46A 56B4 AD39 C907  BBB7 1646 B01B 86E5 0310
     Subkey fingerprint: 6A01 0C51 6600 6599 AA17  F081 46C2 130D FD24 97F5
> GPG signature looks good
> Extracting to ~/.yarn...

Unfortunately I don't have any Mac OS 10.10 machines available to test it out, but I think this will work as expected.

cc @BanzaiMan

Closes #2012
Closes #1984

 - Old versions of Mac OS (10.10 and below) require the `-t` option for `mktemp`
 - The check for GPG wasn't returning correctly, and tried to run GPG even when not available

Closes yarnpkg#2012
Closes yarnpkg#1984
@Daniel15 Daniel15 changed the title Fix mktemp usage on Mac OS, and handling of GPG Fix mktemp usage on Mac OS, and handling of environments where GPG is not available Nov 24, 2016
@Daniel15 Daniel15 merged commit 42b4759 into yarnpkg:master Nov 24, 2016
@Daniel15 Daniel15 deleted the fixinstaller branch November 24, 2016 23:45
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.

1 participant