Rename project from flakelite to flakelight

This commit is contained in:
Archit Gupta 2023-08-26 22:48:57 -07:00
parent f6c4424f6e
commit b8d9538c58
19 changed files with 52 additions and 52 deletions

View File

@ -1,4 +1,4 @@
# flakelite # flakelight
An opinionated Nix flake framework for making flakes simple. An opinionated Nix flake framework for making flakes simple.

View File

@ -1,12 +1,12 @@
# flakelite -- Framework for making flakes simple # flakelight -- Framework for simplifying flake setup
# Copyright (C) 2023 Archit Gupta <archit@accelbread.com> # Copyright (C) 2023 Archit Gupta <archit@accelbread.com>
# SPDX-License-Identifier: MIT # SPDX-License-Identifier: MIT
{ config, lib, flakelite, ... }: { config, lib, flakelight, ... }:
let let
inherit (lib) isFunction mapAttrs mkIf mkMerge mkOption; inherit (lib) isFunction mapAttrs mkIf mkMerge mkOption;
inherit (lib.types) lazyAttrsOf nullOr raw; inherit (lib.types) lazyAttrsOf nullOr raw;
inherit (flakelite.types) optFunctionTo; inherit (flakelight.types) optFunctionTo;
isApp = x: (x ? type) && (x.type == "app") && (x ? program); isApp = x: (x ? type) && (x.type == "app") && (x ? program);

View File

@ -1,4 +1,4 @@
# flakelite -- Framework for making flakes simple # flakelight -- Framework for simplifying flake setup
# Copyright (C) 2023 Archit Gupta <archit@accelbread.com> # Copyright (C) 2023 Archit Gupta <archit@accelbread.com>
# SPDX-License-Identifier: MIT # SPDX-License-Identifier: MIT
@ -7,7 +7,7 @@ let
inherit (lib) mkEnableOption; inherit (lib) mkEnableOption;
in in
{ {
options.flakelite.builtinFormatters = options.flakelight.builtinFormatters =
mkEnableOption "default formatters" // { default = true; }; mkEnableOption "default formatters" // { default = true; };
config = { config = {

View File

@ -1,8 +1,8 @@
# flakelite -- Framework for making flakes simple # flakelight -- Framework for simplifying flake setup
# Copyright (C) 2023 Archit Gupta <archit@accelbread.com> # Copyright (C) 2023 Archit Gupta <archit@accelbread.com>
# SPDX-License-Identifier: MIT # SPDX-License-Identifier: MIT
{ config, src, lib, inputs, outputs, flakelite, ... }: { config, src, lib, inputs, outputs, flakelight, ... }:
let let
inherit (lib) isList mkOption mkOrder mapAttrs optionalAttrs; inherit (lib) isList mkOption mkOrder mapAttrs optionalAttrs;
inherit (lib.types) listOf nullOr oneOf str; inherit (lib.types) listOf nullOr oneOf str;
@ -25,7 +25,7 @@ in
system = prev.stdenv.hostPlatform.system; system = prev.stdenv.hostPlatform.system;
in in
{ {
inherit src inputs outputs flakelite system; inherit src inputs outputs flakelight system;
inputs' = mapAttrs (_: mapAttrs (_: v: v.${system} or { })) inputs; inputs' = mapAttrs (_: mapAttrs (_: v: v.${system} or { })) inputs;
outputs' = mapAttrs (_: v: v.${system} or { }) outputs; outputs' = mapAttrs (_: v: v.${system} or { }) outputs;

View File

@ -1,12 +1,12 @@
# flakelite -- Framework for making flakes simple # flakelight -- Framework for simplifying flake setup
# Copyright (C) 2023 Archit Gupta <archit@accelbread.com> # Copyright (C) 2023 Archit Gupta <archit@accelbread.com>
# SPDX-License-Identifier: MIT # SPDX-License-Identifier: MIT
{ config, src, lib, flakelite, ... }: { config, src, lib, flakelight, ... }:
let let
inherit (lib) isDerivation isFunction mkOption mkIf mapAttrs; inherit (lib) isDerivation isFunction mkOption mkIf mapAttrs;
inherit (lib.types) lazyAttrsOf nullOr raw; inherit (lib.types) lazyAttrsOf nullOr raw;
inherit (flakelite.types) optFunctionTo; inherit (flakelight.types) optFunctionTo;
mkCheck = pkgs: src: name: cmd: mkCheck = pkgs: src: name: cmd:
let let

View File

@ -1,14 +1,14 @@
# flakelite -- Framework for making flakes simple # flakelight -- Framework for simplifying flake setup
# Copyright (C) 2023 Archit Gupta <archit@accelbread.com> # Copyright (C) 2023 Archit Gupta <archit@accelbread.com>
# SPDX-License-Identifier: MIT # SPDX-License-Identifier: MIT
{ config, inputs, lib, flakelite, ... }: { config, inputs, lib, flakelight, ... }:
let let
inherit (builtins) all head isAttrs length; inherit (builtins) all head isAttrs length;
inherit (lib) foldAttrs getFiles getValues mapAttrs mergeAttrs mkOption inherit (lib) foldAttrs getFiles getValues mapAttrs mergeAttrs mkOption
mkOptionType showFiles showOption; mkOptionType showFiles showOption;
inherit (lib.types) functionTo lazyAttrsOf listOf nonEmptyStr raw uniq; inherit (lib.types) functionTo lazyAttrsOf listOf nonEmptyStr raw uniq;
inherit (flakelite.types) optListOf overlay; inherit (flakelight.types) optListOf overlay;
outputs = mkOptionType { outputs = mkOptionType {
name = "outputs"; name = "outputs";

View File

@ -1,14 +1,14 @@
# flakelite -- Framework for making flakes simple # flakelight -- Framework for simplifying flake setup
# Copyright (C) 2023 Archit Gupta <archit@accelbread.com> # Copyright (C) 2023 Archit Gupta <archit@accelbread.com>
# SPDX-License-Identifier: MIT # SPDX-License-Identifier: MIT
{ config, lib, flakelite, ... }: { config, lib, flakelight, ... }:
let let
inherit (lib) any attrValues filterAttrs mapAttrs mkIf mkMerge mkOption inherit (lib) any attrValues filterAttrs mapAttrs mkIf mkMerge mkOption
optionalAttrs; optionalAttrs;
inherit (lib.types) lazyAttrsOf functionTo lines listOf nullOr package str; inherit (lib.types) lazyAttrsOf functionTo lines listOf nullOr package str;
inherit (flakelite) supportedSystem; inherit (flakelight) supportedSystem;
inherit (flakelite.types) optFunctionTo packageDef; inherit (flakelight.types) optFunctionTo packageDef;
in in
{ {
options = { options = {

View File

@ -1,4 +1,4 @@
# flakelite -- Framework for making flakes simple # flakelight -- Framework for simplifying flake setup
# Copyright (C) 2023 Archit Gupta <archit@accelbread.com> # Copyright (C) 2023 Archit Gupta <archit@accelbread.com>
# SPDX-License-Identifier: MIT # SPDX-License-Identifier: MIT
@ -7,11 +7,11 @@ let
inherit (lib) mkEnableOption mkIf optionalString pathExists; inherit (lib) mkEnableOption mkIf optionalString pathExists;
in in
{ {
options.flakelite.editorconfig = options.flakelight.editorconfig =
mkEnableOption "editorconfig check" // { default = true; }; mkEnableOption "editorconfig check" // { default = true; };
config.checks = mkIf config.checks = mkIf
(config.flakelite.editorconfig && (pathExists (src + /.editorconfig))) (config.flakelight.editorconfig && (pathExists (src + /.editorconfig)))
{ {
# By default, high false-positive flags are disabled. # By default, high false-positive flags are disabled.
editorconfig = { editorconfig-checker, ... }: editorconfig = { editorconfig-checker, ... }:

View File

@ -1,12 +1,12 @@
# flakelite -- Framework for making flakes simple # flakelight -- Framework for simplifying flake setup
# Copyright (C) 2023 Archit Gupta <archit@accelbread.com> # Copyright (C) 2023 Archit Gupta <archit@accelbread.com>
# SPDX-License-Identifier: MIT # SPDX-License-Identifier: MIT
{ config, src, lib, flakelite, ... }: { config, src, lib, flakelight, ... }:
let let
inherit (lib) mkOption mkIf mapAttrsToList; inherit (lib) mkOption mkIf mapAttrsToList;
inherit (lib.types) lazyAttrsOf nullOr str; inherit (lib.types) lazyAttrsOf nullOr str;
inherit (flakelite.types) optFunctionTo; inherit (flakelight.types) optFunctionTo;
in in
{ {
options.formatters = mkOption { options.formatters = mkOption {

View File

@ -1,4 +1,4 @@
# flakelite -- Framework for making flakes simple # flakelight -- Framework for simplifying flake setup
# Copyright (C) 2023 Archit Gupta <archit@accelbread.com> # Copyright (C) 2023 Archit Gupta <archit@accelbread.com>
# SPDX-License-Identifier: MIT # SPDX-License-Identifier: MIT

View File

@ -1,12 +1,12 @@
# flakelite -- Framework for making flakes simple # flakelight -- Framework for simplifying flake setup
# Copyright (C) 2023 Archit Gupta <archit@accelbread.com> # Copyright (C) 2023 Archit Gupta <archit@accelbread.com>
# SPDX-License-Identifier: MIT # SPDX-License-Identifier: MIT
{ config, lib, flakelite, ... }: { config, lib, flakelight, ... }:
let let
inherit (lib) mkOption mkIf mkMerge; inherit (lib) mkOption mkIf mkMerge;
inherit (lib.types) lazyAttrsOf nullOr; inherit (lib.types) lazyAttrsOf nullOr;
inherit (flakelite.types) module; inherit (flakelight.types) module;
in in
{ {
options = { options = {

View File

@ -1,12 +1,12 @@
# flakelite -- Framework for making flakes simple # flakelight -- Framework for simplifying flake setup
# Copyright (C) 2023 Archit Gupta <archit@accelbread.com> # Copyright (C) 2023 Archit Gupta <archit@accelbread.com>
# SPDX-License-Identifier: MIT # SPDX-License-Identifier: MIT
{ config, src, lib, flakelite, ... }@args: { config, src, lib, flakelight, ... }@args:
let let
inherit (lib) isFunction mkOption mkIf mkMerge optionalAttrs; inherit (lib) isFunction mkOption mkIf mkMerge optionalAttrs;
inherit (flakelite) autoImport; inherit (flakelight) autoImport;
inherit (flakelite.types) path; inherit (flakelight.types) path;
in in
{ {
options.nixDir = mkOption { options.nixDir = mkOption {

View File

@ -1,4 +1,4 @@
# flakelite -- Framework for making flakes simple # flakelight -- Framework for simplifying flake setup
# Copyright (C) 2023 Archit Gupta <archit@accelbread.com> # Copyright (C) 2023 Archit Gupta <archit@accelbread.com>
# SPDX-License-Identifier: MIT # SPDX-License-Identifier: MIT

View File

@ -1,12 +1,12 @@
# flakelite -- Framework for making flakes simple # flakelight -- Framework for simplifying flake setup
# Copyright (C) 2023 Archit Gupta <archit@accelbread.com> # Copyright (C) 2023 Archit Gupta <archit@accelbread.com>
# SPDX-License-Identifier: MIT # SPDX-License-Identifier: MIT
{ config, lib, flakelite, ... }: { config, lib, flakelight, ... }:
let let
inherit (lib) mkOption mkIf mkMerge; inherit (lib) mkOption mkIf mkMerge;
inherit (lib.types) lazyAttrsOf nullOr; inherit (lib.types) lazyAttrsOf nullOr;
inherit (flakelite.types) module; inherit (flakelight.types) module;
in in
{ {
options = { options = {

View File

@ -1,12 +1,12 @@
# flakelite -- Framework for making flakes simple # flakelight -- Framework for simplifying flake setup
# Copyright (C) 2023 Archit Gupta <archit@accelbread.com> # Copyright (C) 2023 Archit Gupta <archit@accelbread.com>
# SPDX-License-Identifier: MIT # SPDX-License-Identifier: MIT
{ config, lib, flakelite, ... }: { config, lib, flakelight, ... }:
let let
inherit (lib) mkOption mkIf; inherit (lib) mkOption mkIf;
inherit (lib.types) lazyAttrsOf; inherit (lib.types) lazyAttrsOf;
inherit (flakelite.types) overlay; inherit (flakelight.types) overlay;
in in
{ {
options.overlays = mkOption { options.overlays = mkOption {

View File

@ -1,15 +1,15 @@
# flakelite -- Framework for making flakes simple # flakelight -- Framework for simplifying flake setup
# Copyright (C) 2023 Archit Gupta <archit@accelbread.com> # Copyright (C) 2023 Archit Gupta <archit@accelbread.com>
# SPDX-License-Identifier: MIT # SPDX-License-Identifier: MIT
{ config, lib, flakelite, ... }: { config, lib, flakelight, ... }:
let let
inherit (builtins) attrNames functionArgs intersectAttrs parseDrvName; inherit (builtins) attrNames functionArgs intersectAttrs parseDrvName;
inherit (lib) composeManyExtensions filterAttrs fix genAttrs mapAttrs mapAttrs' inherit (lib) composeManyExtensions filterAttrs fix genAttrs mapAttrs mapAttrs'
mkIf mkMerge mkOption mkOrder nameValuePair optional optionalAttrs remove; mkIf mkMerge mkOption mkOrder nameValuePair optional optionalAttrs remove;
inherit (lib.types) lazyAttrsOf nullOr; inherit (lib.types) lazyAttrsOf nullOr;
inherit (flakelite) supportedSystem; inherit (flakelight) supportedSystem;
inherit (flakelite.types) packageDef; inherit (flakelight.types) packageDef;
getName = pkg: pkg.pname or (parseDrvName pkg.name).name; getName = pkg: pkg.pname or (parseDrvName pkg.name).name;

View File

@ -1,4 +1,4 @@
# flakelite -- Framework for making flakes simple # flakelight -- Framework for simplifying flake setup
# Copyright (C) 2023 Archit Gupta <archit@accelbread.com> # Copyright (C) 2023 Archit Gupta <archit@accelbread.com>
# SPDX-License-Identifier: MIT # SPDX-License-Identifier: MIT

View File

@ -1,4 +1,4 @@
# flakelite -- Framework for making flakes simple # flakelight -- Framework for simplifying flake setup
# Copyright (C) 2023 Archit Gupta <archit@accelbread.com> # Copyright (C) 2023 Archit Gupta <archit@accelbread.com>
# SPDX-License-Identifier: MIT # SPDX-License-Identifier: MIT
@ -18,12 +18,12 @@ let
specialArgs.modulesPath = ./builtinModules; specialArgs.modulesPath = ./builtinModules;
modules = builtinModules ++ [ modules = builtinModules ++ [
{ inputs.nixpkgs = mkDefault localInputs.nixpkgs; } { inputs.nixpkgs = mkDefault localInputs.nixpkgs; }
{ _module.args = { inherit src flakelite; }; } { _module.args = { inherit src flakelight; }; }
root root
]; ];
}).config.outputs; }).config.outputs;
flakelite = { flakelight = {
inherit mkFlake supportedSystem importDir autoImport; inherit mkFlake supportedSystem importDir autoImport;
types = { types = {
@ -92,6 +92,6 @@ let
in in
{ {
lib = flakelite; lib = flakelight;
__functor = _: mkFlake; __functor = _: mkFlake;
} }

View File

@ -1,4 +1,4 @@
# flakelite -- Framework for making flakes simple # flakelight -- Framework for simplifying flake setup
# Copyright (C) 2023 Archit Gupta <archit@accelbread.com> # Copyright (C) 2023 Archit Gupta <archit@accelbread.com>
# SPDX-License-Identifier: MIT # SPDX-License-Identifier: MIT
@ -6,7 +6,7 @@
inputs.nixpkgs.url = "nixpkgs/nixos-unstable"; inputs.nixpkgs.url = "nixpkgs/nixos-unstable";
outputs = inputs: outputs = inputs:
let let
flakelite = import ./. inputs; flakelight = import ./. inputs;
in in
flakelite ./. { outputs = flakelite; }; flakelight ./. { outputs = flakelight; };
} }