Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
in
rec {
packages = rec {
zeth = (pkgs.callPackage ./nix/zeth.nix { });
solc = (pkgs.callPackage ./nix/solc.nix { });
rollup-bridge-contracts = (pkgs.callPackage ./nix/rollup-bridge-contracts.nix { });
nil = (pkgs.callPackage ./nix/nil.nix {
Expand Down Expand Up @@ -155,6 +156,9 @@
chmod -R u+rwx,g+rx,o+rx ./usr/share/${packages.nilexplorer.name}
chmod -R u+rwx,g+rx,o+rx ./usr/share/${packages.docsaibackend.name}

# copy file after set permitions for /usr/bin
cp ${packages.zeth.outPath}/bin/zeth-ethereum ./usr/bin/zeth-ethereum

mv ./usr/bin/cometa ./usr/bin/nil-cometa
mv ./usr/bin/indexer ./usr/bin/nil-indexer

Expand Down
36 changes: 36 additions & 0 deletions nix/zeth.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
{ lib
, gccStdenv
, fetchurl
, pkgs
}:

let
pname = "zeth";
version = "0.1.0";
meta = with lib; {
description = "Reference tool for rexecute blocks";
homepage = "https://github.com/akokoshn/zeth";
# license = licenses.apache;
};

zeth =
gccStdenv.mkDerivation
rec {
inherit pname version meta;

executable = fetchurl {
url = "https://github.com/akokoshn/zeth/releases/download/dev/zeth-ethereum";
sha256 = "sha256-HXbw7RfiTR4+CMdryWvR/0YpaLK8fsccSxameBkJqIk=";
};

phases = [ "installPhase" ];

installPhase = ''
echo "Install Zeth"
mkdir -p $out/bin
cp ${executable} $out/bin/zeth-ethereum
chmod 777 $out/bin/zeth-ethereum
'';
};
in
zeth