Compare commits
7 Commits
4586c00f4e
...
bced319f32
Author | SHA1 | Date | |
---|---|---|---|
bced319f32 | |||
|
a798e65465 | ||
d36de346ad | |||
b7f88d78b5 | |||
71f6ac0f46 | |||
561afaf18c | |||
f0dc2d521d |
2
.github/dependabot.yml
vendored
2
.github/dependabot.yml
vendored
@ -4,5 +4,5 @@ updates:
|
|||||||
directory: "/"
|
directory: "/"
|
||||||
schedule:
|
schedule:
|
||||||
interval: "weekly"
|
interval: "weekly"
|
||||||
- commit-message:
|
commit-message:
|
||||||
prefix: "ci"
|
prefix: "ci"
|
||||||
|
1
.github/workflows/build.yml
vendored
1
.github/workflows/build.yml
vendored
@ -10,6 +10,7 @@ jobs:
|
|||||||
check:
|
check:
|
||||||
- nixpkgs-fmt
|
- nixpkgs-fmt
|
||||||
- deadnix
|
- deadnix
|
||||||
|
- nur
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
|
@ -1,10 +1,15 @@
|
|||||||
{ pkgs, lib ? pkgs.lib, unitDir ? "unit", packageFun ? "package.nix", root ? "${./pkgs}/${unitDir}" }:
|
{ pkgs
|
||||||
|
, lib ? pkgs.lib
|
||||||
|
, unitDir ? "unit"
|
||||||
|
, packageFun ? "package.nix"
|
||||||
|
, root ? "${./pkgs}/${unitDir}"
|
||||||
|
}:
|
||||||
let
|
let
|
||||||
shards = lib.attrNames (builtins.readDir root);
|
shards = lib.attrNames (builtins.readDir root);
|
||||||
namesForShard = shard: lib.mapAttrs'
|
namesForShard = shard: lib.mapAttrs'
|
||||||
(name: _: { inherit name; value = "${root}/${shard}/${name}"; })
|
(name: _: { inherit name; value = root + "/${shard}/${name}"; })
|
||||||
(builtins.readDir "${root}/${shard}");
|
(builtins.readDir (root + "/${shard}"));
|
||||||
namesToPath = lib.foldl' lib.recursiveUpdate { } (map namesForShard shards);
|
namesToPath = lib.foldl' lib.recursiveUpdate { } (map namesForShard shards);
|
||||||
units = lib.mapAttrs (_: path: pkgs.callPackage "${path}/${packageFun}" { }) namesToPath;
|
units = lib.mapAttrs (_: path: pkgs.callPackage (path + "/${packageFun}") { }) namesToPath;
|
||||||
in
|
in
|
||||||
units
|
units
|
||||||
|
10
default.nix
10
default.nix
@ -7,11 +7,13 @@
|
|||||||
# nix-build -A mypackage
|
# nix-build -A mypackage
|
||||||
|
|
||||||
{ pkgs ? import <nixpkgs> { } }:
|
{ pkgs ? import <nixpkgs> { } }:
|
||||||
|
let
|
||||||
import ./pkgs/top-level/all-packages.nix { inherit pkgs; }
|
legacy = import ./pkgs/top-level/all-packages.nix { inherit pkgs; };
|
||||||
// {
|
units = import ./callUnitRoot.nix { inherit pkgs; root = ./pkgs/unit; };
|
||||||
|
in
|
||||||
|
legacy // units // {
|
||||||
# The `lib`, `modules`, and `overlay` names are special
|
# The `lib`, `modules`, and `overlay` names are special
|
||||||
lib = import ./lib { inherit pkgs; }; # functions
|
lib = import ./lib { inherit pkgs; }; # functions
|
||||||
modules = import ./modules; # NixOS modules
|
modules = import ./modules; # NixOS modules
|
||||||
overlays = import ./overlays; # nixpkgs overlays
|
overlays = import ./overlays; # nixpkgs overlays
|
||||||
} // import ./callUnitRoot.nix { inherit pkgs; }
|
}
|
||||||
|
6
flake.lock
generated
6
flake.lock
generated
@ -17,11 +17,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1677383253,
|
"lastModified": 1677995890,
|
||||||
"narHash": "sha256-UfpzWfSxkfXHnb4boXZNaKsAcUrZT9Hw+tao1oZxd08=",
|
"narHash": "sha256-eOnCn0o3I6LP48fAi8xWFcn49V2rL7oX5jCtJTeN1LI=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "9952d6bc395f5841262b006fbace8dd7e143b634",
|
"rev": "a1240f6b4a0bcc84fc48008b396a140d9f3638f6",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
16
flake.nix
16
flake.nix
@ -20,11 +20,11 @@
|
|||||||
# Unstable names are variables.
|
# Unstable names are variables.
|
||||||
packages =
|
packages =
|
||||||
let
|
let
|
||||||
|
|
||||||
legacyPackages = import ./pkgs/top-level/all-packages.nix { inherit pkgs; };
|
legacyPackages = import ./pkgs/top-level/all-packages.nix { inherit pkgs; };
|
||||||
|
unitPackages = import ./callUnitRoot.nix { inherit pkgs; };
|
||||||
onlyAvailable = lib.filterAttrs (_: drv: builtins.elem system (drv.meta.platforms or [ ]));
|
onlyAvailable = lib.filterAttrs (_: drv: builtins.elem system (drv.meta.platforms or [ ]));
|
||||||
in
|
in
|
||||||
onlyAvailable (legacyPackages // import ./callUnitRoot.nix { inherit pkgs; });
|
onlyAvailable (legacyPackages // unitPackages);
|
||||||
|
|
||||||
checks = {
|
checks = {
|
||||||
nixpkgs-fmt = pkgs.writeShellScriptBin "nixpkgs-fmt-check" ''
|
nixpkgs-fmt = pkgs.writeShellScriptBin "nixpkgs-fmt-check" ''
|
||||||
@ -33,6 +33,18 @@
|
|||||||
deadnix = pkgs.writeShellScriptBin "deadnix-check" ''
|
deadnix = pkgs.writeShellScriptBin "deadnix-check" ''
|
||||||
${pkgs.deadnix}/bin/deadnix --fail .
|
${pkgs.deadnix}/bin/deadnix --fail .
|
||||||
'';
|
'';
|
||||||
|
# Ensures that the NUR bot can evaluate and find all our packages.
|
||||||
|
# Normally we'd also run with `--option restrict-eval true`, but
|
||||||
|
# this is incompatible with flakes because reasons.
|
||||||
|
nur = pkgs.writeShellScriptBin "nur-check" ''
|
||||||
|
nix-env -f . -qa \* --meta \
|
||||||
|
--allowed-uris https://static.rust-lang.org \
|
||||||
|
--option allow-import-from-derivation true \
|
||||||
|
--drv-path --show-trace \
|
||||||
|
-I nixpkgs=$(nix-instantiate --find-file nixpkgs) \
|
||||||
|
-I ./ \
|
||||||
|
--json | ${pkgs.jq}/bin/jq -r 'values | .[].name'
|
||||||
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
devShells.ci = pkgs.mkShellNoCC {
|
devShells.ci = pkgs.mkShellNoCC {
|
||||||
|
@ -32,4 +32,4 @@ lib.makeScope newScope (self: lib.makeOverridable
|
|||||||
jetbrainsWithPlugins = jetbrainsWithPlugins self variant;
|
jetbrainsWithPlugins = jetbrainsWithPlugins self variant;
|
||||||
})
|
})
|
||||||
)
|
)
|
||||||
{ })
|
{ })
|
||||||
|
@ -29,15 +29,17 @@ stdenv.mkDerivation rec {
|
|||||||
--add-flags "--working-dir \''${XDG_DATA_HOME:-\$HOME/.local/share}/ATLauncher"
|
--add-flags "--working-dir \''${XDG_DATA_HOME:-\$HOME/.local/share}/ATLauncher"
|
||||||
'';
|
'';
|
||||||
|
|
||||||
meta = with lib; {
|
meta = {
|
||||||
description = "Minecraft launcher";
|
description = "Minecraft launcher";
|
||||||
longDescription = ''
|
longDescription = ''
|
||||||
ATLauncher is a Launcher for Minecraft which integrates multiple different
|
ATLauncher is a Launcher for Minecraft which integrates multiple different
|
||||||
ModPacks to allow you to download and install ModPacks easily and quickly.
|
ModPacks to allow you to download and install ModPacks easily and quickly.
|
||||||
'';
|
'';
|
||||||
sourceProvenance = with sourceTypes; [ binaryBytecode ];
|
sourceProvenance = [
|
||||||
license = licenses.gpl3Only;
|
(lib.sourceTypes.binaryBytecode or { shortName = "binaryBytecode"; isSource = false; })
|
||||||
platforms = platforms.all;
|
];
|
||||||
|
license = lib.licenses.gpl3Only;
|
||||||
|
platforms = lib.platforms.all;
|
||||||
homepage = "https://atlauncher.com/";
|
homepage = "https://atlauncher.com/";
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user