mirror of
https://github.com/TECHNOFAB11/disko.git
synced 2025-12-13 00:20:05 +01:00
style: Apply nixpkgs-fmt and fix
Apply standard formatting and some statix conventions using; ```sh nixpkgs-fmt **.nix && statix fix . ``` With the intent of making contribution a bit easier and reducing mental load in hand formatting (in the same vein as [black]). [black]: https://github.com/psf/black#the-uncompromising-code-formatter
This commit is contained in:
parent
b1a4ecb8ca
commit
08435eec4b
23 changed files with 171 additions and 158 deletions
|
|
@ -50,11 +50,11 @@
|
|||
default = { dev, parent }:
|
||||
let
|
||||
mountpoint =
|
||||
if (!isNull config.mountpoint) then config.mountpoint
|
||||
else if (isNull parent) then config.name
|
||||
if (config.mountpoint != null) then config.mountpoint
|
||||
else if (parent == null) then config.name
|
||||
else null;
|
||||
in
|
||||
lib.optionalAttrs (!isNull mountpoint) {
|
||||
lib.optionalAttrs (mountpoint != null) {
|
||||
fs.${mountpoint} = ''
|
||||
if ! findmnt ${dev} "${rootMountPoint}${mountpoint}" > /dev/null 2>&1; then
|
||||
mount ${dev} "${rootMountPoint}${mountpoint}" \
|
||||
|
|
@ -70,11 +70,11 @@
|
|||
default = dev: parent:
|
||||
let
|
||||
mountpoint =
|
||||
if (!isNull config.mountpoint) then config.mountpoint
|
||||
else if (isNull parent) then config.name
|
||||
if (config.mountpoint != null) then config.mountpoint
|
||||
else if (parent == null) then config.name
|
||||
else null;
|
||||
in
|
||||
lib.optional (!isNull mountpoint) {
|
||||
lib.optional (mountpoint != null) {
|
||||
fileSystems.${mountpoint} = {
|
||||
device = dev;
|
||||
fsType = "btrfs";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue