| 22 Oct 2025 |
cortsf | https://github.com/cortsf/hympd | 01:09:47 |
cortsf | This seems to work locally.
{ pkgs ? import <nixpkgs> {} }:
let
hympdFlake = builtins.getFlake "github:cortsf/hympd?rev=ea295556192e4c436917313da11211d8b1d47299";
hympdPackage = hympdFlake.packages.${pkgs.system}.default;
in
pkgs.stdenv.mkDerivation {
pname = "hympd";
version = "1.0";
src = ./.;
buildInputs = [ hympdPackage ];
# buildPhase = ''
# echo "Using my-package from the other flake: ${myPackage}/bin/some-command"
# '';
installPhase = ''
mkdir -p $out/bin
cp ${hympdPackage}/bin/hympd $out/bin
'';
}
| 01:10:02 |
cortsf | * This seems to work locally.
{ pkgs ? import <nixpkgs> {} }:
let
hympdFlake = builtins.getFlake "github:cortsf/hympd?rev=ea295556192e4c436917313da11211d8b1d47299";
hympdPackage = hympdFlake.packages.${pkgs.system}.default;
in
pkgs.stdenv.mkDerivation {
pname = "hympd";
version = "1.0";
src = ./.;
buildInputs = [ hympdPackage ];
installPhase = ''
mkdir -p $out/bin
cp ${hympdPackage}/bin/hympd $out/bin
'';
}
| 01:13:55 |
ipsavitsky234 | cortsfnot sure what you mean by "publish a nix flake to nixpkgs", can you elaborate pls? | 09:56:16 |
cortsf | ipsavitsky234: I just made a simple program and I'd like it to be available on nixpkgs, if possible. | 11:06:28 |
dramforever | no, builtins.getFlake is not okay, nor is any other way to download external code during evaluation in nixpkgs | 11:07:27 |
@gabyx:matrix.org | In reply to @cortsf:matrix.org ipsavitsky234: I just made a simple program and I'd like it to be available on nixpkgs, if possible. people can use your program also when its an output in a flake.nix | 11:08:02 |
dramforever | generally you want to check how some similar thing is packaged in nixpkgs, and just copy what they do | 11:08:17 |
@gabyx:matrix.org | In reply to @cortsf:matrix.org ipsavitsky234: I just made a simple program and I'd like it to be available on nixpkgs, if possible. * people can use your program also when its an output in a flake.nix, doesnt need to be in the nixpkgs repo… | 11:08:20 |