Skip to content

Commit

Permalink
update packages, fix cargo-workspaces
Browse files Browse the repository at this point in the history
  • Loading branch information
macalinao committed Jan 6, 2024
1 parent 54ed488 commit c0aaa65
Show file tree
Hide file tree
Showing 5 changed files with 70 additions and 13 deletions.
6 changes: 3 additions & 3 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

18 changes: 9 additions & 9 deletions nix/flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions nix/nixpkgs/overlays/10-basic.nix
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ self: super: rec {
sha256 = "1zxgy3znw0i6h1lxhmnx001c1pdcyszwqj8f0d0092nmnngdzsrl";
};

cargo-workspaces = self.callPackage ./packages/cargo-workspaces.nix { };

# kitty = super.kitty.overrideAttrs (existing: {
# patches = [
# # From https://github.com/NixOS/nixpkgs/blob/master/pkgs/applications/terminal-emulators/kitty/default.nix
Expand Down
55 changes: 55 additions & 0 deletions nix/nixpkgs/overlays/packages/cargo-workspaces.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
{ lib
, rustPlatform
, fetchCrate
, pkg-config
, libgit2_1_6
, libssh2
, openssl
, zlib
, stdenv
, darwin
}:

rustPlatform.buildRustPackage rec {
pname = "cargo-workspaces";
version = "0.3.0";

src = fetchCrate {
inherit pname version;
hash = "sha256-1wNoMVfouuPRGFGB6XIhgeeWgknxMctrBl5Vfco6qug=";
};

cargoHash = "sha256-OJGqIo6mYqXjmQb/2CVVTskecYZretw+K46Fvbu/PcQ=";

nativeBuildInputs = [
pkg-config
];

buildInputs = [
libgit2_1_6
libssh2
openssl
zlib
] ++ lib.optionals stdenv.isDarwin [
darwin.apple_sdk.frameworks.Security
darwin.apple_sdk_11_0.frameworks.SystemConfiguration
];

env = {
LIBSSH2_SYS_USE_PKG_CONFIG = true;
};

meta = with lib; {
description = "A tool for managing cargo workspaces and their crates, inspired by lerna";
longDescription = ''
A tool that optimizes the workflow around cargo workspaces with
git and cargo by providing utilities to version, publish, execute
commands and more.
'';
homepage = "https://github.com/pksunkara/cargo-workspaces";
changelog = "https://github.com/pksunkara/cargo-workspaces/blob/v${version}/CHANGELOG.md";
license = licenses.mit;
maintainers = with maintainers; [ figsoda macalinao matthiasbeyer ];
mainProgram = "cargo-workspaces";
};
}
2 changes: 1 addition & 1 deletion scripts/igm-switch
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ SYSTEM_CONFIG_ATTRIBUTE=$(system_config_attribute)
echo "Using flake at path $FLAKE_PATH."

SHOW_TRACE=''
if [ $1 = '--debug' ]; then
if [ ${1:none} = '--debug' ]; then
SHOW_TRACE='--show-trace'
fi

Expand Down

0 comments on commit c0aaa65

Please sign in to comment.