summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--flake.nix20
1 files changed, 16 insertions, 4 deletions
diff --git a/flake.nix b/flake.nix
index 70cc436..752d694 100644
--- a/flake.nix
+++ b/flake.nix
@@ -6,10 +6,13 @@
6 6
7 outputs = { self, nixpkgs, robotnix }: 7 outputs = { self, nixpkgs, robotnix }:
8 let 8 let
9 baseUrl = "https://ota.ahem.wtf";
9 common = { 10 common = {
10 apps = { 11 apps = {
11 bromite.enable = true; 12 bromite.enable = true;
12 fdroid.enable = true; 13 fdroid.enable = true;
14
15 updater.enable = true;
13 }; 16 };
14 17
15 microg.enable = true; 18 microg.enable = true;
@@ -33,14 +36,20 @@
33 # configuration. Change it to something meaningful for you, perhaps just 36 # configuration. Change it to something meaningful for you, perhaps just
34 # the device name if you only have one of this kind of device. 37 # the device name if you only have one of this kind of device.
35 robotnixConfigurations.fp3 = robotnix.lib.robotnixSystem ({ config, pkgs, ... }: { 38 robotnixConfigurations.fp3 = robotnix.lib.robotnixSystem ({ config, pkgs, ... }: {
39 imports = [ common ];
40
36 device = "FP3"; 41 device = "FP3";
37 flavor = "lineageos"; 42 flavor = "lineageos";
38 } // common); 43 apps.updater.url = "${baseUrl}/fp3/";
44 });
39 45
40 robotnixConfigurations.fp2 = robotnix.lib.robotnixSystem ({ config, pkgs, ... }: { 46 robotnixConfigurations.fp2 = robotnix.lib.robotnixSystem ({ config, pkgs, ... }: {
47 imports = [ common ];
48
41 device = "FP2"; 49 device = "FP2";
42 flavor = "lineageos"; 50 flavor = "lineageos";
43 } // common); 51 apps.updater.url = "${baseUrl}/fp2/";
52 });
44 53
45 # This provides a convenient output which allows you to build the image by 54 # This provides a convenient output which allows you to build the image by
46 # simply running "nix build" on this flake. 55 # simply running "nix build" on this flake.
@@ -48,7 +57,8 @@
48 defaultPackage.x86_64-linux = self.robotnixConfigurations.fp3.img; 57 defaultPackage.x86_64-linux = self.robotnixConfigurations.fp3.img;
49 58
50 hydraJobs.robotnixConfigurations = with nixpkgs.legacyPackages.x86_64-linux; { 59 hydraJobs.robotnixConfigurations = with nixpkgs.legacyPackages.x86_64-linux; {
51 fp3 = with self.robotnixConfigurations.fp3; 60 fp3.otaDir = self.robotnixConfigurations.fp2.otaDir;
61 fp3.products = with self.robotnixConfigurations.fp3;
52 runCommandLocal 62 runCommandLocal
53 "hydra-fp3-products-${config.buildNumber}" 63 "hydra-fp3-products-${config.buildNumber}"
54 { } 64 { }
@@ -65,7 +75,9 @@
65 echo "file img $out/FP3-img-${config.buildNumber}.zip" >> $out/nix-support/hydra-build-products 75 echo "file img $out/FP3-img-${config.buildNumber}.zip" >> $out/nix-support/hydra-build-products
66 echo "file ota $out/FP3-ota_update-${config.buildNumber}.zip" >> $out/nix-support/hydra-build-products 76 echo "file ota $out/FP3-ota_update-${config.buildNumber}.zip" >> $out/nix-support/hydra-build-products
67 ''; 77 '';
68 fp2 = with self.robotnixConfigurations.fp2; 78
79 fp2.otaDir = self.robotnixConfigurations.fp2.otaDir;
80 fp2.products = with self.robotnixConfigurations.fp2;
69 runCommandLocal 81 runCommandLocal
70 "hydra-fp2-products-${config.buildNumber}" 82 "hydra-fp2-products-${config.buildNumber}"
71 { } 83 { }