Trying to use brew-nix - still to much broken

This commit is contained in:
Olaf
2026-07-30 16:04:47 +02:00
parent 45bf546b85
commit 9d42bfdf15
4 changed files with 132 additions and 159 deletions
+77 -68
View File
@@ -1,80 +1,89 @@
_:
{ pkgs }:
let
casks = pkgs.brewCasks;
# the override to replace the packages source fetch itself rather than just changing a downstream hash field
overrideCaskWithHash = name: hash:
casks.${name}.overrideAttrs (oldAttrs: {
src = pkgs.fetchurl {
url = builtins.head oldAttrs.src.urls;
hash = hash;
};
});
overriddenCasks = {
"box-tools" = overrideCaskWithHash "box-tools" "sha256-e7QZ/mWye86d7GDSgD+CtHDLCp/odiFwDcdg7/qxqKc=";
daisydisk = overrideCaskWithHash "daisydisk" "sha256-Re9GOfK03Gogb4Ep1itUJm60L94qvGfXgjqpLg8GQlc=";
keybase = overrideCaskWithHash "keybase" "sha256-CnFlLeU/BIhiUYebtRpUjJWE0QrsdZsiiZGzRUi31zg=";
};
in
[
# Development Tools
"arduino-ide"
"homebrew/cask/docker-desktop"
"iterm2"
"oracle-jdk"
"visual-studio-code"
# Development tools
casks.arduino-ide
casks."docker-desktop"
casks.iterm2
casks.oracle-jdk
casks."visual-studio-code"
# Creative tools
"blender"
"gimp"
"inkscape"
"vcv-rack"
#"affinity-designer"
#"affinity-photo"
#"affinity-publisher"
casks.blender
casks.gimp
casks.inkscape
casks."vcv-rack"
# Communication Tools
"adium"
"discord"
"signal"
"webex"
"whatsapp"
"zoom"
# Communication tools
casks.adium
casks.discord
casks.signal
casks.webex
casks.whatsapp
casks.zoom
# Utility tools
# These casks currently fail during Homebrew download/build in this environment.
# casks."blackhole-16ch"
# casks."blackhole-2ch"
casks."box-drive"
# box-tools currently fails during unpack/install in this environment.
# overriddenCasks."box-tools"
# daisydisk currently fails with an upstream hash mismatch in this environment.
# overriddenCasks.daisydisk
# casks."karabiner-elements"
overriddenCasks.keybase
(overrideCaskWithHash "smartsheet" "sha256-ShCJAKDWMWy++3IC00YdyABvsmLW6DrpvJABAkFQXOA=")
casks.spamsieve
casks."syncthing-app"
casks."synology-drive"
# Utility Tools
# Entertainment tools
casks.qobuz
casks.steam
casks."handbrake-app"
casks."jellyfin-media-player"
casks.mediaelch
casks.obs
casks."vimediamanager"
casks.vlc
"blackhole-16ch"
"blackhole-2ch"
"box-drive"
"box-tools"
"daisydisk"
"karabiner-elements"
"keybase"
"spamsieve"
"syncthing-app"
"synology-drive"
# Entertainment Tools
"qobuz"
"steam"
"handbrake-app"
"jellyfin-media-player"
"mediaelch"
"obs"
"vimediamanager"
"vlc"
# Productivity Tools
"1Password"
"bitwarden"
"calibre"
"dbeaver-community"
"element"
"gpg-suite"
"macdown-3000"
"mailmate"
"orcaslicer"
"remanager"
"qmk-toolbox"
"smartsheet"
"spamsieve"
# "sqlitestudio" # Doesn't work without Rosetta
"tigervnc"
# "virtualbox" # build error?
"copilot-cli"
# Productivity tools
casks."1password"
casks.bitwarden
casks.calibre
casks."dbeaver-community"
casks.element
casks."gpg-suite"
casks."macdown-3000"
casks.mailmate
casks.orcaslicer
casks.remanager
casks."qmk-toolbox"
casks.smartsheet
casks."copilot-cli"
# Browsers
"brave-browser"
"firefox"
"google-chrome"
casks."brave-browser"
casks.firefox
casks."google-chrome"
# x11
"xquartz"
# X11
casks.xquartz
]
+4 -41
View File
@@ -9,6 +9,7 @@
let
user = "olaf";
casks = import ./casks.nix { inherit pkgs; };
# Define the content of your file as a derivation
myEmacsLauncher = pkgs.writeScript "emacs-launcher.command" ''
#!/bin/sh
@@ -32,49 +33,11 @@ in
};
homebrew = {
enable = true;
casks = pkgs.callPackage ./casks.nix { };
onActivation = {
cleanup = "uninstall";
autoUpdate = true;
upgrade = true;
};
# These app IDs are from using the mas CLI app
# mas = mac app store
# https://github.com/mas-cli/mas
#
# $ nix shell nixpkgs#mas
# $ mas search <app name>
#
# If you have previously added these apps to your Mac App Store profile (but not installed them on this system),
# you may receive an error message "Redownload Unavailable with This Apple ID".
# This message is safe to ignore. (https://github.com/dustinlyons/nixos-config/issues/83)
masApps = {
"1Password for Safari" = 1569813296; # (8.10.82)
"Affinity Designer 2" = 1616831348;
"Affinity Photo 2: Image Editor" = 1616822987;
"Affinity Publisher 2" = 1606941598;
# "DaisyDisk" = 411643860; # (4.32) # Don't use this, we need the official version that is not sandboxed
"Fantastical - Calendar" = 975937182;
" Fedistar" = 6445863996; # (1.13.1)
"Home Assistant" = 1099568401; # (2025.7.1)
"Ice Cubes for Mastodon" = 6444915884; # (1.11.3)
"LibreOffice" = 1630474372;
"Monal - XMPP Chatting " = 1637078500;
"MQTT Explorer" = 1455214828; # (0.3.5)
"Night Sky" = 475772902; # 475772902
"Native SQLite Manager" = 1416282836; # (1.31.0)
"Remarkable Desktop" = 1276493162; # (3.19.0)
"Slack for Desktop" = 803453959; # (4.45.60)
"WiFi Explorer: Scanner" = 494803304; # (3.5.6)
"Wireguard" = 1451685025; # (1.0.16)
### "1Password: Password Manager" = 1511601750; # (8.11.0) Does not seem to insta
};
enable = false;
};
environment.systemPackages = casks;
# Enable home-manager
home-manager = {
useGlobalPkgs = true;