a geicko-2 based round robin ranking system designed to test c++ battleship submissions
battleship.dunkirk.sh
1{
2 description = "Battleship Arena - SSH battleship tournament service";
3
4 inputs = {
5 nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
6 };
7
8 outputs =
9 { self, nixpkgs }:
10 let
11 allSystems = [
12 "x86_64-linux"
13 "aarch64-linux"
14 "x86_64-darwin"
15 "aarch64-darwin"
16 ];
17 forAllSystems =
18 f:
19 nixpkgs.lib.genAttrs allSystems (
20 system:
21 f {
22 pkgs = import nixpkgs { inherit system; };
23 }
24 );
25 in
26 {
27 packages = forAllSystems (
28 { pkgs }:
29 {
30 default = pkgs.buildGoModule {
31 pname = "battleship-arena";
32 version = "0.1.0";
33 subPackages = [ "cmd/battleship-arena" ];
34 src = self;
35
36 vendorHash = null;
37
38 nativeBuildInputs = [ pkgs.makeWrapper ];
39 buildInputs = [ pkgs.gcc ];
40
41 env.CGO_ENABLED = "1";
42
43 ldflags = [
44 "-s"
45 "-w"
46 ];
47
48 meta = with pkgs.lib; {
49 description = "SSH-based battleship tournament service";
50 homepage = "https://github.com/taciturnaxolotl/battleship-arena";
51 license = licenses.mit;
52 mainProgram = "battleship-arena";
53 };
54 };
55 }
56 );
57 };
58}