feat(wordpress): Add lavoixduntexte
Add the website lavoixduntexte, as well as wrappers to create addons easily
This commit is contained in:
parent
14b436f331
commit
acc2ee6fef
4 changed files with 53 additions and 3 deletions
27
machines/web01/wordpress/addons/default.nix
Normal file
27
machines/web01/wordpress/addons/default.nix
Normal file
|
@ -0,0 +1,27 @@
|
|||
{ pkgs, lib, ... }:
|
||||
|
||||
let
|
||||
mkWordpressAddon = { name, version, type, hash ? lib.fakeHash }:
|
||||
pkgs.stdenv.mkDerivation {
|
||||
inherit name version;
|
||||
|
||||
src = pkgs.fetchzip {
|
||||
url = "https://downloads.wordpress.org/${type}/${name}.${version}.zip";
|
||||
inherit hash;
|
||||
};
|
||||
|
||||
installPhase = "mkdir -p $out; cp -R * $out/";
|
||||
};
|
||||
in {
|
||||
themes = builtins.mapAttrs (name: attrs:
|
||||
mkWordpressAddon ({
|
||||
inherit name;
|
||||
type = "theme";
|
||||
} // attrs)) (import ./themes.nix);
|
||||
|
||||
plugins = builtins.mapAttrs (name: attrs:
|
||||
mkWordpressAddon ({
|
||||
inherit name;
|
||||
type = "plugin";
|
||||
} // attrs)) (import ./plugins.nix);
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue