Skip to content

Commit 1cbd198

Browse files
committed
working example
1 parent 890fee6 commit 1cbd198

File tree

3 files changed

+98
-0
lines changed

3 files changed

+98
-0
lines changed

flake.lock

Lines changed: 60 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

flake.nix

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
{
2+
inputs = {
3+
nixpkgs.url = "github:NixOS/nixpkgs";
4+
utils.url = "github:numtide/flake-utils";
5+
};
6+
7+
outputs = { self, nixpkgs, utils }:
8+
utils.lib.eachDefaultSystem (system:
9+
let
10+
pkgs = import nixpkgs {
11+
inherit system;
12+
};
13+
name = "embgitdev";
14+
in
15+
rec
16+
{
17+
packages.${name} = pkgs.callPackage ./default.nix {
18+
inherit (inputs);
19+
};
20+
21+
# `nix build`
22+
defaultPackage = packages.${name};
23+
24+
# `nix run`
25+
apps.${name} = utils.lib.mkApp {
26+
inherit name;
27+
drv = packages.${name};
28+
};
29+
defaultApp = packages.${name};
30+
31+
devShell = pkgs.mkShell {
32+
buildInputs = with pkgs; [
33+
gnumake
34+
];
35+
};
36+
});
37+
}

src/main.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@ func main() {
5959
cmdAddAll(),
6060
cmdClone(),
6161
cmdCommit(),
62+
cmdLog(),
6263
cmdPull(),
6364
cmdPush(),
6465
cmdResetHard(),

0 commit comments

Comments
 (0)