2021-02-14 03:38:20 +01:00
|
|
|
# Suites
|
|
|
|
Suites provide a mechanism for users to easily combine and name collecitons of
|
2021-06-03 21:25:06 +02:00
|
|
|
profiles. For good examples, check out the suites defined in the community branch.
|
2021-02-14 03:38:20 +01:00
|
|
|
|
2021-06-03 21:25:06 +02:00
|
|
|
`suites` are a special case of an `importable` which get passed as a special
|
|
|
|
argument (one that can be use in an `imports` line) to your hosts.
|
2021-02-14 03:38:20 +01:00
|
|
|
|
2021-06-03 21:25:06 +02:00
|
|
|
They are defined with the `suites` argument in either the `home` or `nixos` namespace.
|
2021-04-27 03:29:05 +02:00
|
|
|
Suites should be passed as a function that take profiles as an argument.
|
|
|
|
|
2021-02-14 03:38:20 +01:00
|
|
|
## Definition
|
|
|
|
```nix
|
|
|
|
rec {
|
|
|
|
workstation = [ profiles.develop profiles.graphical users.nixos ];
|
|
|
|
mobileWS = workstation ++ [ profiles.laptop ];
|
|
|
|
}
|
|
|
|
```
|
|
|
|
|
|
|
|
## Usage
|
|
|
|
`hosts/my-laptop.nix`:
|
|
|
|
```nix
|
|
|
|
{ suites, ... }:
|
|
|
|
{
|
|
|
|
imports = suites.mobileWS;
|
|
|
|
}
|
|
|
|
```
|