HomePhabricator
Diffusion Comm 6265dd4dd405

[Nix] Fail immediately when upstream nix install fails

Description

[Nix] Fail immediately when upstream nix install fails

Summary:
Propagate failures when running the upstream nix install script.
This is to avoid the case where the failure gets buried by the output
of the rest of the command.

Part of https://linear.app/comm/issue/ENG-2877

Test Plan:

# If nix is not already installed, install it
./scripts/install_nix.sh

# Unset nix from PATH, then re-run script
PATH=/usr/bin:/bin ./scripts/install_nix.sh
# Anwser yes to the prompts, then assert that it fails without
# trying to continue with the script (e.g. nix.conf changes)

Reviewers: varun, atul, ashoat, bartek

Reviewed By: ashoat

Subscribers: ashoat, tomek, atul

Differential Revision: https://phab.comm.dev/D6475

Details

Provenance
jonAuthored on Jan 30 2023, 7:42 AM
Reviewer
ashoat
Differential Revision
D6475: [Nix] Fail immediately when upstream nix install fails
Parents
rCOMM942f509f745c: [Native] Remove CMake installation logic from native/cpp
Branches
Unknown
Tags
Unknown