mirror of
https://github.com/NixOS/nixos-hardware.git
synced 2026-12-04 06:53:30 +01:00
chore: format repo using treefmt-nix and nixfmt-rfc-style
This commit is contained in:
1 parent
fc7c471412
commit
51e51e6014
266 files changed
+3721
-2733
No files matched your search
@@ -1,4 +1,9 @@
|
||||
{ config, pkgs, lib, ... }:
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
let
|
||||
cfg = config.hardware.visionfive2;
|
||||
in
|
||||
@@ -34,15 +39,19 @@ in
|
||||
|
||||
config = {
|
||||
system.build = {
|
||||
opensbi = (pkgs.callPackage ./opensbi.nix {}).overrideAttrs (f: p: {
|
||||
src = if cfg.opensbi.src != null then cfg.opensbi.src else p.src;
|
||||
patches = if cfg.opensbi.patches != null then cfg.opensbi.patches else (p.patches or []);
|
||||
});
|
||||
opensbi = (pkgs.callPackage ./opensbi.nix { }).overrideAttrs (
|
||||
_f: p: {
|
||||
src = if cfg.opensbi.src != null then cfg.opensbi.src else p.src;
|
||||
patches = if cfg.opensbi.patches != null then cfg.opensbi.patches else (p.patches or [ ]);
|
||||
}
|
||||
);
|
||||
|
||||
uboot = (pkgs.callPackage ./uboot.nix { inherit (config.system.build) opensbi; }).overrideAttrs (f: p: {
|
||||
src = if cfg.uboot.src != null then cfg.uboot.src else p.src;
|
||||
patches = if cfg.uboot.patches != null then cfg.uboot.patches else (p.patches or []);
|
||||
});
|
||||
uboot = (pkgs.callPackage ./uboot.nix { inherit (config.system.build) opensbi; }).overrideAttrs (
|
||||
_f: p: {
|
||||
src = if cfg.uboot.src != null then cfg.uboot.src else p.src;
|
||||
patches = if cfg.uboot.patches != null then cfg.uboot.patches else (p.patches or [ ]);
|
||||
}
|
||||
);
|
||||
|
||||
updater-flash = pkgs.writeShellApplication {
|
||||
name = "visionfive2-firmware-update-flash";
|
||||
|
||||
@@ -1,4 +1,9 @@
|
||||
{ config, pkgs, modulesPath, ... }:
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
modulesPath,
|
||||
...
|
||||
}:
|
||||
{
|
||||
imports = [
|
||||
"${modulesPath}/profiles/base.nix"
|
||||
@@ -7,8 +12,7 @@
|
||||
];
|
||||
|
||||
sdImage = {
|
||||
imageName =
|
||||
"${config.sdImage.imageBaseName}-${config.system.nixos.label}-${pkgs.stdenv.hostPlatform.system}-starfive-visionfive2.img";
|
||||
imageName = "${config.sdImage.imageBaseName}-${config.system.nixos.label}-${pkgs.stdenv.hostPlatform.system}-starfive-visionfive2.img";
|
||||
|
||||
# Overridden by postBuildCommands
|
||||
populateFirmwareCommands = "";
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{ stdenv, fetchFromGitHub }:
|
||||
|
||||
stdenv.mkDerivation (finalAttrs: {
|
||||
stdenv.mkDerivation (_finalAttrs: {
|
||||
pname = "spi_tool";
|
||||
version = "0x01010101";
|
||||
src = fetchFromGitHub {
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
{ buildUBoot
|
||||
, opensbi
|
||||
{
|
||||
buildUBoot,
|
||||
opensbi,
|
||||
}:
|
||||
|
||||
buildUBoot {
|
||||
|
||||
Reference in new issue
Block a user