This commit is contained in:
Ana Hobden 2022-09-28 13:49:07 -07:00
parent 72a4356a8b
commit 08f1410f6a
3 changed files with 28 additions and 25 deletions

View file

@ -47,7 +47,7 @@
]);
in
{
devShell = forAllSystems ({ system, pkgs, ... }:
devShells = forAllSystems ({ system, pkgs, ... }:
let
toolchain = fenixToolchain system;
ci = import ./nix/ci.nix { inherit pkgs; };
@ -60,29 +60,31 @@
.
'';
in
pkgs.mkShell {
name = "nix-install-shell";
{
default = pkgs.mkShell {
name = "nix-install-shell";
RUST_SRC_PATH = "${toolchain}/lib/rustlib/src/rust/library";
RUST_SRC_PATH = "${toolchain}/lib/rustlib/src/rust/library";
nativeBuildInputs = with pkgs; [
pkg-config
];
buildInputs = with pkgs; [
toolchain
openssl
rust-analyzer
nativeBuildInputs = with pkgs; [
pkg-config
];
buildInputs = with pkgs; [
toolchain
openssl
rust-analyzer
# CI dependencies
jq
codespell
findutils # for xargs
git
nixpkgs-fmt
eclint
]
++ ci
++ lib.optionals (pkgs.stdenv.isDarwin) (with pkgs; [ libiconv darwin.apple_sdk.frameworks.Security ]);
# CI dependencies
jq
codespell
findutils # for xargs
git
nixpkgs-fmt
eclint
]
++ ci
++ lib.optionals (pkgs.stdenv.isDarwin) (with pkgs; [ libiconv darwin.apple_sdk.frameworks.Security ]);
};
});
packages = forAllSystems
@ -118,7 +120,8 @@
};
};
in
{
rec {
default = harmonic;
harmonic = naerskLib.buildPackage
(sharedAttrs // { });
} // lib.optionalAttrs (system == "x86_64-linux") {

View file

@ -84,7 +84,7 @@ impl Actionable for CreateNixTree {
*action_state = ActionState::Progress;
tracing::debug!("Creating nix tree");
// Just do sequential since parallizing this will have little benefit
// Just do sequential since parallelizing this will have little benefit
for create_directory in create_directories {
create_directory.execute().await?
}
@ -131,7 +131,7 @@ impl Actionable for CreateNixTree {
*action_state = ActionState::Progress;
tracing::debug!("Deleting nix tree");
// Just do sequential since parallizing this will have little benefit
// Just do sequential since parallelizing this will have little benefit
for create_directory in create_directories.iter_mut().rev() {
create_directory.revert().await?
}

View file

@ -29,7 +29,7 @@ pub(crate) async fn confirm(question: impl AsRef<str>) -> eyre::Result<bool> {
Some(Ok(event)) => {
if let crossterm::event::Event::Key(key) = event {
match key.code {
KeyCode::Enter => continue, // Many users will hit enter accidently when they are agreeing/declining prompts.
KeyCode::Enter => continue, // Many users will hit enter accidentally when they are agreeing/declining prompts.
// TODO(@hoverbear): Should maybe actually even wait for it?
KeyCode::Char('y') => break Ok(true),
_ => {