mirror of
https://github.com/srid/nixos-config.git
synced 2025-12-26 23:14:57 +08:00
Merge pull request #73 from srid/infinitude-mac
Add `inifinitude` (Mac)
This commit is contained in:
commit
fadfa6efcd
6 changed files with 34 additions and 57 deletions
|
|
@ -1,46 +0,0 @@
|
|||
# Configuration for my M1 Macbook Max (using nix-darwin)
|
||||
{ flake, ... }:
|
||||
|
||||
let
|
||||
inherit (flake) inputs;
|
||||
inherit (inputs) self;
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
self.darwinModules.default
|
||||
];
|
||||
|
||||
nixpkgs.hostPlatform = "aarch64-darwin";
|
||||
networking.hostName = "appreciate";
|
||||
|
||||
security.pam.enableSudoTouchIdAuth = true;
|
||||
|
||||
system.keyboard = {
|
||||
enableKeyMapping = true;
|
||||
remapCapsLockToControl = true;
|
||||
};
|
||||
# See https://github.com/ryan4yin/nix-darwin-kickstarter/blob/main/rich-demo/modules/system.nix
|
||||
system.defaults = {
|
||||
dock = {
|
||||
autohide = true;
|
||||
# customize Hot Corners(触发角, 鼠标移动到屏幕角落时触发的动作)
|
||||
wvous-tl-corner = 2; # top-left - Mission Control
|
||||
# wvous-tr-corner = 13; # top-right - Lock Screen
|
||||
wvous-bl-corner = 3; # bottom-left - Application Windows
|
||||
# wvous-br-corner = 4; # bottom-right - Desktop
|
||||
};
|
||||
|
||||
finder = {
|
||||
_FXShowPosixPathInTitle = true; # show full path in finder title
|
||||
AppleShowAllExtensions = true; # show all file extensions
|
||||
FXEnableExtensionChangeWarning = false; # disable warning when changing file extension
|
||||
QuitMenuItem = true; # enable quit menu item
|
||||
ShowPathbar = true; # show path bar
|
||||
ShowStatusBar = true; # show status bar
|
||||
};
|
||||
};
|
||||
|
||||
# Used for backwards compatibility, please read the changelog before changing.
|
||||
# $ darwin-rebuild changelog
|
||||
system.stateVersion = 4;
|
||||
}
|
||||
26
configurations/darwin/infinitude.nix
Normal file
26
configurations/darwin/infinitude.nix
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
# Configuration for my M1 Macbook Max as headless server
|
||||
{ flake, ... }:
|
||||
|
||||
let
|
||||
inherit (flake) inputs;
|
||||
inherit (inputs) self;
|
||||
in
|
||||
{
|
||||
nixos-unified.sshTarget = "srid@192.168.2.46";
|
||||
|
||||
imports = [
|
||||
self.darwinModules.default
|
||||
];
|
||||
|
||||
nixpkgs.hostPlatform = "aarch64-darwin";
|
||||
networking.hostName = "infinitude";
|
||||
|
||||
system.keyboard = {
|
||||
enableKeyMapping = true;
|
||||
remapCapsLockToControl = true;
|
||||
};
|
||||
|
||||
# Used for backwards compatibility, please read the changelog before changing.
|
||||
# $ darwin-rebuild changelog
|
||||
system.stateVersion = 4;
|
||||
}
|
||||
6
justfile
6
justfile
|
|
@ -16,10 +16,10 @@ nom:
|
|||
pureintent:
|
||||
nix run . pureintent
|
||||
|
||||
# Deploy to nginx gate
|
||||
# Deploy to infinitude (mac)
|
||||
[group('deploy')]
|
||||
gate:
|
||||
nix run . gate
|
||||
infinitude:
|
||||
nix run . infinitude
|
||||
|
||||
# Format the nix source tree
|
||||
fmt:
|
||||
|
|
|
|||
|
|
@ -1,11 +1,11 @@
|
|||
{ pkgs, flake, ... }:
|
||||
let
|
||||
package =
|
||||
if pkgs.stdenv.isDarwin then
|
||||
#if pkgs.stdenv.isDarwin then
|
||||
# Upstream has broken mac package
|
||||
pkgs.gitAndTools.gitFull.override { svnSupport = false; }
|
||||
else
|
||||
pkgs.gitAndTools.git;
|
||||
# pkgs.gitAndTools.gitFull.override { svnSupport = false; }
|
||||
#else
|
||||
pkgs.gitAndTools.git;
|
||||
in
|
||||
{
|
||||
home.packages = with pkgs; [
|
||||
|
|
|
|||
|
|
@ -1,7 +1,4 @@
|
|||
{
|
||||
# Garbage collect automatically every week
|
||||
nix.gc.automatic = true;
|
||||
|
||||
# Nix configuration is managed globally by nix-darwin.
|
||||
# Prevent $HOME nix.conf from disrespecting it.
|
||||
home.file."~/.config/nix/nix.conf".text = "";
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
imports = [
|
||||
./all/zsh.nix
|
||||
./all/wezterm
|
||||
# ./all/wezterm
|
||||
# ./all/emacs.nix
|
||||
];
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue