docs: add generated scopedPackages readme
All checks were successful
Discord / discord commits (push) Has been skipped
All checks were successful
Discord / discord commits (push) Has been skipped
This commit is contained in:
parent
2598505dfd
commit
fdbd5cb2df
4 changed files with 53 additions and 21 deletions
|
@ -20,7 +20,6 @@ substituteAttrs() {
|
||||||
) -t markdown --template "$FLAKE/apps/gen-docs/templates/$1.md" -o "$FLAKE/$1/README.md"
|
) -t markdown --template "$FLAKE/apps/gen-docs/templates/$1.md" -o "$FLAKE/$1/README.md"
|
||||||
}
|
}
|
||||||
|
|
||||||
# TODO: add overlays, scopedPackages
|
|
||||||
substitute "appsPackages" "apps" "getPackageMeta"
|
substitute "appsPackages" "apps" "getPackageMeta"
|
||||||
substitute "nixosConfigurations" "configurations" "getConfigMeta"
|
substitute "nixosConfigurations" "configurations" "getConfigMeta"
|
||||||
substitute "devShells" "devShells" "getPackageMeta"
|
substitute "devShells" "devShells" "getPackageMeta"
|
||||||
|
@ -28,3 +27,6 @@ substitute "packages" "packages" "getPackageMeta"
|
||||||
substituteAttrs "modules"
|
substituteAttrs "modules"
|
||||||
substituteAttrs "homeManagerModules"
|
substituteAttrs "homeManagerModules"
|
||||||
substituteAttrs "overlays"
|
substituteAttrs "overlays"
|
||||||
|
|
||||||
|
# TODO: add metadata of all packages
|
||||||
|
substituteAttrs "scopedPackages"
|
||||||
|
|
11
apps/gen-docs/templates/scopedPackages.md
Normal file
11
apps/gen-docs/templates/scopedPackages.md
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
# ScopedPackages
|
||||||
|
|
||||||
|
This directory contains every package scopes exposed by this flake.
|
||||||
|
|
||||||
|
## List of my package scopes found in `self.scopedPackages`
|
||||||
|
|
||||||
|
| Name | Description |
|
||||||
|
| ---- | ----------- |
|
||||||
|
$for(attrs/pairs)$
|
||||||
|
| `$it.key$` | $it.value.desc/nowrap$ |
|
||||||
|
$endfor$
|
|
@ -1,11 +1,13 @@
|
||||||
# ScopedPackages
|
# ScopedPackages
|
||||||
|
|
||||||
This directory encompasses every derivation scopes for packages exposed by my flake.
|
This directory contains every package scopes exposed by this flake.
|
||||||
|
|
||||||
## List of package scopes found in `self.scopedPackages`
|
## List of my package scopes found in `self.scopedPackages`
|
||||||
|
|
||||||
| Name | Description |
|
| Name | Description |
|
||||||
| --------------- | ----------- |
|
| ---- | ----------- |
|
||||||
| `dracula` | Themes for many apps from the [Dracula GitHub Org](https://github.com/dracula) |
|
| `dracula` | Custom derivations that each represent an app's Dracula Theme. |
|
||||||
| `firefoxAddons` | Firefox extensions updated with [mozilla-addons-to-nix](https://git.sr.ht/~rycee/mozilla-addons-to-nix) |
|
| `firefoxAddons` | Every extensions I use in my firefox module. |
|
||||||
| `mpvScripts` | MPV scripts I use that are not in nixpkgs |
|
| `hass-components` | Components I use for Home-Assistant that aren't in nixpkgs. |
|
||||||
|
| `lovelace-components` | Lovelace components I use for Home-Assistant that aren't in nixpkgs. |
|
||||||
|
| `mpvScripts` | MPV scripts I use that aren't in nixpkgs. |
|
||||||
|
|
|
@ -1,18 +1,35 @@
|
||||||
{
|
{
|
||||||
inputs,
|
inputs ? {},
|
||||||
mkVersion,
|
mkVersion ? {},
|
||||||
pkgs,
|
pkgs ? {},
|
||||||
...
|
description ? false,
|
||||||
}: let
|
}: let
|
||||||
inherit (pkgs) lib;
|
inherit (pkgs.lib) recurseIntoAttrs;
|
||||||
|
|
||||||
mkScope = file:
|
mkScope = file: desc:
|
||||||
lib.recurseIntoAttrs
|
if description
|
||||||
(pkgs.callPackage file ({inherit mkVersion;} // inputs));
|
then desc
|
||||||
|
else
|
||||||
|
recurseIntoAttrs
|
||||||
|
(pkgs.callPackage file ({inherit mkVersion;} // inputs));
|
||||||
in {
|
in {
|
||||||
dracula = mkScope ./dracula;
|
dracula = mkScope ./dracula ''
|
||||||
firefoxAddons = mkScope ./firefox-addons;
|
Custom derivations that each represent an app's Dracula Theme.
|
||||||
hass-components = mkScope ./hass-components;
|
'';
|
||||||
lovelace-components = mkScope ./lovelace-components;
|
|
||||||
mpvScripts = mkScope ./mpv-scripts;
|
firefoxAddons = mkScope ./firefox-addons ''
|
||||||
|
Every extensions I use in my firefox module.
|
||||||
|
'';
|
||||||
|
|
||||||
|
hass-components = mkScope ./hass-components ''
|
||||||
|
Components I use for Home-Assistant that aren't in nixpkgs.
|
||||||
|
'';
|
||||||
|
|
||||||
|
lovelace-components = mkScope ./lovelace-components ''
|
||||||
|
Lovelace components I use for Home-Assistant that aren't in nixpkgs.
|
||||||
|
'';
|
||||||
|
|
||||||
|
mpvScripts = mkScope ./mpv-scripts ''
|
||||||
|
MPV scripts I use that aren't in nixpkgs.
|
||||||
|
'';
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue