Change-Id: Iebddca35f0a870799c8a19ae019cecd9803a3e9c Reviewed-on: https://cl.tvl.fyi/c/depot/+/8907 Tested-by: BuildkiteCI Reviewed-by: sterni <sternenseemann@systemli.org> Autosubmit: tazjin <tazjin@tvl.su>
		
			
				
	
	
		
			37 lines
		
	
	
	
		
			851 B
		
	
	
	
		
			Nix
		
	
	
	
	
	
			
		
		
	
	
			37 lines
		
	
	
	
		
			851 B
		
	
	
	
		
			Nix
		
	
	
	
	
	
| # https://github.com/josh-project/josh
 | |
| { depot, pkgs, ... }:
 | |
| 
 | |
| let
 | |
|   # TODO(sterni): switch to pkgs.josh as soon as that commit is released
 | |
|   rev = "c0a170a756dd5e63268673086218c0ce7bf18bdc";
 | |
|   src = pkgs.fetchFromGitHub {
 | |
|     owner = "josh-project";
 | |
|     repo = "josh";
 | |
|     inherit rev;
 | |
|     hash = "sha256:0rsf65fq9xm3qj77ig3s4wmmgm50jhvwrknr839hipjj5lj4x1hp";
 | |
|   };
 | |
| in
 | |
| depot.third_party.naersk.buildPackage {
 | |
|   inherit src;
 | |
|   JOSH_VERSION = "git-${builtins.substring 0 8 rev}";
 | |
| 
 | |
|   buildInputs = with pkgs; [
 | |
|     libgit2
 | |
|     openssl
 | |
|     pkg-config
 | |
|   ];
 | |
| 
 | |
|   cargoBuildOptions = x: x ++ [
 | |
|     "-p"
 | |
|     "josh-filter"
 | |
|     "-p"
 | |
|     "josh-proxy"
 | |
|   ];
 | |
| 
 | |
|   overrideMain = x: {
 | |
|     nativeBuildInputs = (x.nativeBuildInputs or [ ]) ++ [ pkgs.makeWrapper ];
 | |
|     postInstall = ''
 | |
|       wrapProgram $out/bin/josh-proxy --prefix PATH : "${pkgs.git}/bin"
 | |
|     '';
 | |
|   };
 | |
| }
 |