Skip to content

Instantly share code, notes, and snippets.

@superherointj
superherointj / towboot.log
Created May 26, 2021 18:59
Tow-Boot Raspberry Pi 4 logs
Tow-Boot 2021.04 (Apr 05 2021 - 15:03:29 +0000)001
DRAM: 7.9 GiB
RPI 4 Model B (0xd03114)
MMC: mmcnr@7e300000: 1, emmc2@7e340000: 0
Loading Environment from FAT... *** Warning - bad CRC, using default environment
Error: malloc in gunzip failed!
There is no valid bmp file at the given address
In: serial
services = {
xserver = {
enable = true;
videoDrivers = [ "intel" "nvidia" ];
config = ''
Section "Device"
Identifier "Intel Graphics"
Driver "intel"
@superherointj
superherointj / flake.nix
Created June 7, 2021 17:15
Flakes p/ Multiplos hosts
{
description = "superherointj NixOS configuration";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
home-manager = {
url = "github:nix-community/home-manager";
inputs = { nixpkgs = { follows = "nixpkgs"; }; };
};
};
@superherointj
superherointj / default.nix
Created June 15, 2021 21:43
Packaging Linkerd - Nixpkgs
{ lib, fetchFromGitHub, buildGoModule }:
buildGoModule rec {
pname = "linkerd";
version = "edge-21.6.2";
src = fetchFromGitHub {
owner = "linkerd";
repo = "linkerd2";
rev = version;
{ lib, fetchFromGitHub, buildGoModule }:
let
vfsgen = (fetchFromGitHub {
owner = "shurcooL";
repo = "vfsgen";
rev = "0d455de96546f756e8830efeec8dab0f489af135";
sha256 = "sha256-8wobXCZHGHf7rIcyeiJ+aA/XkzbbaXt7laGXhNXboVU=";
});
logrus = (fetchFromGitHub {
# vscode.nix
{ config, pkgs, ... }: {
programs.vscode = {
enable = true;
package = pkgs.vscodium;
userSettings = {
"editor.minimap.enabled" = false;
"editor.fontSize" = 18;
"editor.wordWrap" = "on";
programs.direnv = {
enable = true;
nix-direnv = {
enable = true;
enableFlakes = true;
};
};
home.file.".config/direnv/lib/use_flake.sh".text = ''
use_flake() {
watch_file flake.nix
@superherointj
superherointj / configuration.nix
Created June 25, 2021 18:36
NixOS module example
# Example of what I call 'module' which has >10 levels to it.
{ config, pkgs, libs, lib, ... }:
let hostId = "2"; in
{
imports = [
(import ../../profiles/rockpro64 { inherit config pkgs libs lib hostId; })
];
}
@superherointj
superherointj / home.nix
Last active July 23, 2021 21:36
Y3liZXI gist
/* cole ai */
home-manager = {
useUserPackages = true;
useGlobalPkgs = true;
users = {
intj = {
###
home.packages = let
telegram-cli = with pkgs;
@superherointj
superherointj / nixos.logs
Created August 24, 2021 11:53
NixOS Error on nixos-rebuild switch
# nixos-rebuild switch
Traceback (most recent call last):
File "/nix/store/4rj0wczwfbfkb63zxyypsbzsazpdcqyk-systemd-boot", line 240, in main
write_entry(*gen, machine_id)
File "/nix/store/4rj0wczwfbfkb63zxyypsbzsazpdcqyk-systemd-boot", line 103, in write_entry
subprocess.check_call([append_initrd_secrets, "/boot%s" % (initrd)])
File "/nix/store/4s0h5aawbap3xhldxhcijvl26751qrjr-python3-3.8.9/lib/python3.8/subprocess.py", line 359, in check_call
retcode = call(*popenargs, **kwargs)
File "/nix/store/4s0h5aawbap3xhldxhcijvl26751qrjr-python3-3.8.9/lib/python3.8/subprocess.py", line 340, in call