Compare commits

...

51 Commits

Author SHA1 Message Date
dde705cf76 update flake 2025-08-31 15:45:46 +02:00
1cb2aa0a04 Merge pull request #5 from ordionary/main
back
2025-08-18 12:04:27 +02:00
nicco
6946fcb6fe update and remove tidal 2025-08-18 09:59:20 +02:00
nicco
6425ba60eb Merge branch 'main' of github.com:ordionary/nix 2025-08-18 09:53:11 +02:00
nicco
246ec2c64c remove bruno and replace cd 2025-08-18 09:53:05 +02:00
6cf8fc5ef5 add nvs overlay 2025-08-08 19:59:01 +02:00
0e9cccf82e Merge pull request #4 from ordionary/main
Back back
2025-08-08 19:15:08 +02:00
nicco
8a51c74620 add nvs package 2025-08-08 19:12:36 +02:00
nicco
2f0d9a097e add project deps 2025-08-08 19:11:26 +02:00
nicco
f797752d8c add posting 2025-08-01 18:48:44 +02:00
aaec06be58 Merge branch 'main' of github.com:cupcakearmy/nix 2025-07-31 11:11:55 +02:00
a345a227aa update nix 2025-07-31 11:11:43 +02:00
b712b580a9 Merge pull request #3 from ordionary/main
sync back
2025-07-31 11:10:38 +02:00
nicco
8d79067cb2 remove zen 2025-07-31 11:10:10 +02:00
Nicco
86e48260f6 Merge branch 'cupcakearmy:main' into main 2025-07-31 10:48:05 +02:00
b986b3a6c5 add font and update packages 2025-07-31 10:47:46 +02:00
nicco
3f30b041c7 add ios stuff 2025-07-31 10:45:42 +02:00
nicco
412d5200f2 switch back to vscode 2025-07-31 10:45:32 +02:00
nicco
c4e7214a17 cli tools 2025-07-21 18:01:06 +02:00
nicco
03098ec5d9 add delta for git 2025-07-21 18:01:00 +02:00
a62a663a1e Merge pull request #2 from ordionary/main
enable cachex and fnm shortcut
2025-07-09 21:35:16 +02:00
nicco
2edba6eac8 enable cachex and fnm shortcut 2025-07-07 17:26:37 +02:00
ed7696d7a3 update commit 2025-07-02 18:43:32 +02:00
89d8728118 add sign key 2025-07-02 18:37:41 +02:00
c001acbb04 Merge pull request #1 from ordionary/main
Ordio stuff
2025-07-02 18:34:34 +02:00
nicco
35e8d233b0 signing 2025-07-02 18:26:27 +02:00
nicco
a92e8912e7 remove omp 2025-07-02 18:26:18 +02:00
nicco
225846e2e2 add notion 2025-07-02 18:23:36 +02:00
3b500da3a4 new plists 2025-07-02 01:06:06 +02:00
4031657854 rename 2025-07-02 01:05:17 +02:00
bb9aa33132 don't sleep 2025-07-02 00:58:34 +02:00
309c4c8d02 add ordio config 2025-07-02 00:54:23 +02:00
e746a81578 signing commits 2025-07-02 00:32:08 +02:00
3a7470cce7 ordio stuff and cleanup 2025-07-02 00:11:56 +02:00
a4d815202e Refactor SSH config to use host-specific keys and disable nix
- Convert SSH config to template with @SSH_KEY@ placeholder
- Add sshKey field to host configurations (mac14, ordio)
- Update home.nix to dynamically substitute SSH keys per host
- Change docker cask to docker-desktop in cask.nix
- Add development packages to ordio host (mkcert, dnsmasq, etc.)
- Disable nix in darwin.nix configuration
2025-07-02 00:11:31 +02:00
1dc5eb19f5 remove unused host 2025-07-02 00:10:51 +02:00
5708bd1509 add ordio ssh key 2025-07-01 14:19:58 +02:00
faf04c3311 add ordio config 2025-07-01 13:44:37 +02:00
a31c089055 add ordio laptop 2025-07-01 13:35:48 +02:00
f50908d358 add bambu 2025-07-01 13:35:06 +02:00
58f2f67260 raycast config 2025-07-01 13:34:59 +02:00
899ab0658f cleanup 2025-06-22 12:18:20 +02:00
205b4b8c9c update flake 2025-06-16 10:05:00 +02:00
e01a71ece0 darwin revuild now needs sudo 2025-05-30 13:24:24 +02:00
1c20a73d19 Update dependencies and fix zen-browser package name
- Change "zen-browser" to "zen" in cask configuration
- Add system.primaryUser setting in darwin.nix
- Remove commented networking.hosts configuration
- Update flake.lock with latest home-manager, nix-darwin, and nixpkgs
2025-05-29 19:16:22 +02:00
a1ad0fa815 add fd and replace ls 2025-05-23 15:40:24 +02:00
9c14f17cd8 switch to starhip 2025-05-23 15:29:03 +02:00
00c61fe4a1 add rust utils 2025-05-23 15:21:11 +02:00
4ec39b7ab3 add browsers 2025-05-14 22:25:57 +02:00
5231444833 Merge branch 'main' of github.com:cupcakearmy/nix 2025-05-05 18:39:51 +02:00
d831b73833 stuff 2025-05-05 18:39:47 +02:00
32 changed files with 162 additions and 373 deletions

View File

@@ -4,6 +4,7 @@
```bash
# Install nix [without the --determinate flag]
# ⚠️ When asked if install the determinate version say no
curl --proto '=https' --tlsv1.2 -sSf -L https://install.determinate.systems/nix | sh -s -- install
# Install brew [for casks]
@@ -19,7 +20,7 @@ git-crypt unlock .key
# Installation
# Available hosts can be found in the ./hosts directory
nix run nix-darwin -- switch --flake ~/.config/nix-macos#<host>
sudo nix run nix-darwin -- switch --flake ~/.config/nix-macos#<host>
# After installation simply use the provided alias to rebuild
vai
@@ -55,5 +56,3 @@ Stuff that I would like to automate, but have not found a way/time
- surfshark
- ublock origin
- vimium

View File

@@ -1,8 +1,10 @@
[
# Objective See
"knockknock"
"lulu"
"oversight"
# Utility
"aldente"
"alt-tab"
"keka"
@@ -13,31 +15,25 @@
"lihaoyun6/tap/quickrecorder"
# Dev
"docker"
"docker-desktop"
"sloth"
"vscodium"
"hoppscotch"
"postman"
"visual-studio-code"
"utm"
"balenaetcher"
"outerbase-studio"
"hoppscotch"
# Apps
# Base
"obsidian"
"figma"
"arc"
"firefox"
"zen-browser"
"zen"
"ungoogled-chromium"
"bitwarden"
"spotify"
"vlc"
"slack"
"yubico-authenticator"
"suspicious-package"
"mediahuman-audio-converter"
"imageoptim"
"appcleaner"
"daisydisk"
"discord"
"signal"
"vlc"
]

View File

@@ -6,7 +6,11 @@
...
}:
{
nix.settings.experimental-features = "nix-command flakes";
nix.settings = {
experimental-features = "nix-command flakes";
substituters = [ "https://devenv.cachix.org" ];
trusted-public-keys = [ "devenv.cachix.org-1:w1cLUi8dv3hnoSPGAuibQv+f9TZLr6cv/Hm9XgU50cw=" ];
};
# Set Git commit hash for darwin-version.
system.configurationRevision = flake.rev or flake.dirtyRev or null;
@@ -20,12 +24,7 @@
# Nix Darwin
# https://daiderd.com/nix-darwin/manual/index.html
# networking.hosts = {
# "127.0.0.1" = [
# "localhost"
# "dev.buena.com"
# ];
# };
system.primaryUser = host.username;
system.defaults = {
# Security
@@ -39,9 +38,9 @@
orientation = "left";
show-recents = false;
persistent-apps = [
"/Applications/Arc.app"
"/Applications/Zen.app"
"/Applications/Ghostty.app"
"/Applications/VSCodium.app"
"/Applications/Visual Studio Code.app"
"/Applications/Spotify.app"
"/System/Applications/System Settings.app"
];
@@ -74,6 +73,13 @@
remapCapsLockToEscape = true;
};
# Power
power = {
sleep = {
computer = "never";
};
};
# Other
system.startup.chime = false;

View File

@@ -1,4 +0,0 @@
[user]
name = cupcakearmy
email = hi@nicco.io
signingkey = 3235314B4D31232F

View File

@@ -1,4 +0,0 @@
[user]
name = Niccolo Borgioli
email = hi@nicco.io
signingkey = 4897ACD13A65977C

View File

@@ -4,15 +4,15 @@
process = git-lfs filter-process
required = true
[core]
pager = delta
excludesfile = ~/.gitignore_global
autocrlf = input
ignorecase=false
[commit]
gpgsign = false
[interactive]
diffFilter = delta --color-only
[pull]
rebase = false
[push]
autoSetupRemote = true
[branch]
@@ -20,5 +20,16 @@
[alias]
fpush = push --force-with-lease
# Signing
[tag]
gpgsign = true
[commit]
gpgsign = true
[gpg]
format = ssh
[include]
path = ~/.gitconfig.local
[delta]
navigate = true

View File

@@ -1 +0,0 @@
node_modules

Binary file not shown.

View File

@@ -1,106 +0,0 @@
[
{
"properties": {
"steps": 8,
"hue": {
"start": 209,
"end": 259,
"curve": "easeOutQuad"
},
"saturation": {
"start": 0.03,
"end": 1,
"rate": 1,
"curve": "easeOutQuad"
},
"brightness": {
"start": 1,
"end": 0.03,
"curve": "easeInQuart"
}
},
"options": {
"minorSteps": [0, 1],
"name": "Main",
"rotation": "clockwise"
}
},
{
"properties": {
"steps": 8,
"hue": {
"start": 0,
"end": 15,
"curve": "easeOutQuad"
},
"saturation": {
"start": 0.75,
"end": 1,
"rate": 1,
"curve": "easeOutQuad"
},
"brightness": {
"start": 1,
"end": 0.2,
"curve": "linear"
}
},
"options": {
"minorSteps": [0, 1],
"name": "Error",
"rotation": "clockwise"
}
},
{
"properties": {
"steps": 8,
"hue": {
"start": 60,
"end": 70,
"curve": "easeOutQuad"
},
"saturation": {
"start": 0.75,
"end": 1,
"rate": 1,
"curve": "easeOutQuad"
},
"brightness": {
"start": 1,
"end": 0.2,
"curve": "linear"
}
},
"options": {
"minorSteps": [0, 1],
"name": "Warning",
"rotation": "clockwise"
}
},
{
"properties": {
"steps": 8,
"hue": {
"start": 122,
"end": 146,
"curve": "easeOutQuad"
},
"saturation": {
"start": 0.75,
"end": 1,
"rate": 1,
"curve": "easeOutQuad"
},
"brightness": {
"start": 1,
"end": 0.2,
"curve": "linear"
}
},
"options": {
"minorSteps": [0, 1],
"name": "Success",
"rotation": "clockwise"
}
}
]

View File

@@ -1,21 +0,0 @@
import color from '@k-vyn/coloralgorithm'
import colors from './colors.json' assert { type: 'json' }
import fs from 'fs'
import yaml from 'yaml'
const offset = 10
const palette = {}
for (const { properties, options } of colors) {
const result = color.generate(properties, options)
const name = result[0].name
for (const color of result[0].colors) {
palette[`${name.toLowerCase()}-${color.step * offset}`] = color.hex
}
}
const configFile = '../main.omp.yaml'
const config = fs.readFileSync(configFile, 'utf8')
// config.palette = palette
const output = yaml.stringify({ palette })
fs.writeFileSync(configFile, config.replace(/palette:(.|\s)*$/, output))

View File

@@ -1,8 +0,0 @@
{
"type": "module",
"main": "index.js",
"dependencies": {
"@k-vyn/coloralgorithm": "^1.0.0",
"yaml": "^2.2.1"
}
}

View File

@@ -1,159 +0,0 @@
# yaml-language-server: $schema=https://raw.githubusercontent.com/JanDeDobbeleer/oh-my-posh/main/themes/schema.json
palette:
error-0: '#ff4040'
error-10: '#e23629'
error-15: '#d33220'
error-20: '#c52e18'
error-30: '#a8280d'
error-40: '#8a2106'
error-5: '#f03a34'
error-50: '#6d1b02'
error-60: '#501401'
error-70: '#330d00'
main-0: '#f7fbff'
main-10: '#b4cafd'
main-15: '#95a9fc'
main-20: '#7783fa'
main-30: '#5348f4'
main-40: '#4826e8'
main-5: '#d6e6fe'
main-50: '#3e10ca'
main-60: '#22036e'
main-70: '#020008'
success-0: '#40ff46'
success-10: '#29e243'
success-15: '#20d342'
success-20: '#18c541'
success-30: '#0da83d'
success-40: '#068a36'
success-5: '#34f044'
success-50: '#026d2d'
success-60: '#015022'
success-70: '#003316'
warning-0: '#ffff40'
warning-10: '#dae229'
warning-15: '#c8d320'
warning-20: '#b6c518'
warning-30: '#96a80d'
warning-40: '#788a06'
warning-5: '#ecf034'
warning-50: '#5d6d02'
warning-60: '#435001'
warning-70: '#2a3300'
blocks:
- type: prompt
alignment: left
segments:
- leading_diamond:
foreground: p:main-70
background: p:main-5
type: os
style: diamond
- properties:
style: full
template: " \uf0e7 "
foreground: p:main-70
powerline_symbol:
background: p:error-15
type: root
style: powerline
- properties:
style: full
template: ' {{ .Path }} '
foreground: p:main-0
powerline_symbol:
background: p:main-40
type: path
style: powerline
- template: ' {{ .HEAD }} '
foreground: p:main-70
powerline_symbol:
background: p:warning-10
type: git
style: powerline
- type: prompt
alignment: right
segments:
- leading_diamond:
trailing_diamond:
foreground: p:main-70
background: p:main-10
type: python
style: dynamic
- leading_diamond:
trailing_diamond:
foreground: p:main-70
background: p:main-10
type: go
style: dynamic
- leading_diamond:
trailing_diamond:
foreground: p:main-70
background: p:main-10
type: node
style: dynamic
- leading_diamond:
trailing_diamond:
template: '{{ .Context }}{{ if .Namespace }}::{{ .Namespace }}{{ end }}'
foreground: p:main-70
background: p:main-10
type: kubectl
style: dynamic
- leading_diamond:
trailing_diamond:
template: '{{ .Icon }} {{ .Server }}'
foreground: p:main-70
background: p:main-10
type: docker
style: dynamic
- leading_diamond:
trailing_diamond:
foreground: p:main-70
background: p:main-10
type: rust
style: dynamic
- leading_diamond:
trailing_diamond:
foreground: p:main-70
background: p:main-10
type: battery
style: dynamic
- properties:
always_enabled: true
leading_diamond:
template: "{{ if gt .Code 0 }}\uf00d {{ .Code }} {{ .Meaning }}{{ else }}\uf42e{{ end }}"
foreground: p:main-70
type: status
style: diamond
background_templates:
- '{{ if gt .Code 0 }}p:error-0{{ else }}p:main-10{{ end }}'
- properties:
always_enabled: true
style: round
foreground: p:main-70
powerline_symbol:
background: p:main-5
type: executiontime
style: powerline
- properties:
time_format: '15:04:05'
template: ' {{ .CurrentDate | date .Format }} '
foreground: p:main-70
powerline_symbol:
background: p:main-0
type: time
style: powerline
- type: prompt
alignment: left
segments:
- properties:
always_enabled: true
template: ' '
foreground: p:main-15
type: status
style: plain
foreground_templates:
- '{{ if gt .Code 0 }}p:error-15{{ end }}'
newline: true
version: 3

18
flake.lock generated
View File

@@ -7,11 +7,11 @@
]
},
"locked": {
"lastModified": 1745764360,
"narHash": "sha256-GJEUJpZLkczMN6HXD0wdFX6KyDbvZe3v5orUhqEfK6w=",
"lastModified": 1756579987,
"narHash": "sha256-duCce8zGsaMsrqqOmLOsuaV1PVIw/vXWnKuLKZClsGg=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "50bb714a8259b0c29b6c3429099a3b837771dab4",
"rev": "99a69bdf8a3c6bf038c4121e9c4b6e99706a187a",
"type": "github"
},
"original": {
@@ -27,11 +27,11 @@
]
},
"locked": {
"lastModified": 1744478979,
"narHash": "sha256-dyN+teG9G82G+m+PX/aSAagkC+vUv0SgUw3XkPhQodQ=",
"lastModified": 1755825449,
"narHash": "sha256-XkiN4NM9Xdy59h69Pc+Vg4PxkSm9EWl6u7k6D5FZ5cM=",
"owner": "LnL7",
"repo": "nix-darwin",
"rev": "43975d782b418ebf4969e9ccba82466728c2851b",
"rev": "8df64f819698c1fee0c2969696f54a843b2231e8",
"type": "github"
},
"original": {
@@ -42,11 +42,11 @@
},
"nixpkgs": {
"locked": {
"lastModified": 1745377448,
"narHash": "sha256-jhZDfXVKdD7TSEGgzFJQvEEZ2K65UMiqW5YJ2aIqxMA=",
"lastModified": 1756536218,
"narHash": "sha256-ynQxPVN2FIPheUgTFhv01gYLbaiSOS7NgWJPm9LF9D0=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "507b63021ada5fee621b6ca371c4fca9ca46f52c",
"rev": "a918bb3594dd243c2f8534b3be01b3cb4ed35fd1",
"type": "github"
},
"original": {

View File

@@ -32,6 +32,9 @@
flake = self;
};
modules = [
{
nixpkgs.overlays = [ (import ./overlay.nix) ];
}
(import ./darwin.nix)
home-manager.darwinModules.home-manager
{

View File

@@ -25,29 +25,39 @@
};
file = {
".config/omp/config.yaml".source = ../files/omp/config.yaml;
".config/ghostty/config".source = ../files/ghostty/config;
".gitconfig".source = ../files/git/gitconfig;
".gitignore_global".source = ../files/git/gitignore_global;
".gitconfig.local".source = ../files/git/config.work;
".gitconfig.local".source = ../secrets/git/config.${host.hostName};
".config/nvim".source = ../files/nvim;
# Secrets
".ssh/config".source = ../secrets/ssh/config;
".ssh/config".text = builtins.replaceStrings [ "@SSH_KEY@" ] [ host.sshKey ] (
builtins.readFile ../secrets/ssh/config.template
);
};
shellAliases = {
l = "ls -hal";
# Rust re-maps
l = "eza -a1lh";
ls = "eza";
cat = "bat";
cd = "z";
# QOL
dc = "docker compose";
rsync = "rsync -az --info=progress2";
t = "tmux new-session -A -s main";
e = "nvim";
g = "lazygit";
d = "lazydocker";
vai = "darwin-rebuild switch --flake ~/.config/nix-macos#${host.hostName}";
p = "pnpm";
px = "pnpm -s dlx";
n = "fnm use --install-if-missing";
c = "pwd | pbcopy";
k = "kubectl";
vai = "sudo darwin-rebuild switch --flake ~/.config/nix-macos#${host.hostName}";
};
};
@@ -58,12 +68,15 @@
fish = {
enable = true;
interactiveShellInit = ''
if type -q oh-my-posh
oh-my-posh init fish --config ~/.config/omp/config.yaml | source
if type -q starship
starship init fish | source
end
if type -q fnm
fnm env --use-on-cd | source
end
if type -q nvs
nvs env --source | source
end
'';
};
bash = {

View File

@@ -3,7 +3,6 @@ with pkgs;
[
# Base
tmux
oh-my-posh
git
git-lfs
git-crypt
@@ -19,9 +18,21 @@ with pkgs;
tree
wget
woff2
bat
rsync
yq
delta
# Rust utils
bat
eza
fd
ripgrep
ripgrep-all
zoxide
uutils-coreutils-noprefix
dust
yazi
starship
# Dev
devenv
@@ -30,15 +41,19 @@ with pkgs;
colima
lazydocker
exercism
posting
terraform
k9s
kubectl
# Editor
nvs
neovim
fzf
lazygit
lua
luajitPackages.luarocks
ast-grep
ripgrep
# Language specific
nixfmt-rfc-style
@@ -56,4 +71,5 @@ with pkgs;
# Fonts
nerd-fonts.jetbrains-mono
karla
]

View File

@@ -1,4 +1,4 @@
[
(import ./mac14.nix)
(import ./mac16.nix)
(import ./ordio.nix)
]

View File

@@ -2,15 +2,24 @@
username = "cupcakearmy";
hostName = "mac14";
platform = "aarch64-darwin";
sshKey = "legba";
extras = {
casks = [
"surfshark"
"visual-studio-code"
"signal"
"discord"
"daisydisk"
"blender"
"bambu-studio"
];
pkgs =
pkgs: with pkgs; [
biome
infisical
ffmpeg
pulumi
];
};
}

View File

@@ -1,21 +0,0 @@
{
username = "niccoloborgioli";
hostName = "mac16";
platform = "aarch64-darwin";
extras = {
casks = [
"phpstorm"
"datagrip"
"tailscale"
"android-studio"
];
pkgs =
pkgs: with pkgs; [
phrase-cli
boundary
awscli2
_1password-cli
];
};
}

33
hosts/ordio.nix Normal file
View File

@@ -0,0 +1,33 @@
{
username = "nicco";
hostName = "ordio";
platform = "aarch64-darwin";
sshKey = "ordio";
extras = {
casks = [
"tableplus"
"http-toolkit"
"phpstorm"
"notion"
];
pkgs =
pkgs: with pkgs; [
mkcert
dnsmasq
awscli2
mysql84
cocoapods
xcodes
# For projects
pixman
pkg-config
pango
libpng
giflib
librsvg
python313Packages.setuptools
];
};
}

27
overlay.nix Normal file
View File

@@ -0,0 +1,27 @@
final: prev: {
nvs = prev.buildGoModule rec {
pname = "nvs";
version = "1.10.5";
src = prev.fetchFromGitHub {
owner = "cupcakearmy";
repo = pname;
# tag = "v${version}";
rev = "1700f2751e969b77b7f7ab3cc16a4e0f3955ce14";
sha256 = "sha256-RScXYxkrfLJp1nAgN2YgSRC4mLGK4yXsYjGBrDR00b8=";
};
vendorHash = "sha256-l2FdnXA+vKVRekcIKt1R+MxppraTsmo0b/B7RNqnxjA=";
# Completions
nativeBuildInputs = [ prev.installShellFiles ];
postInstall = ''
export HOME=$TMPDIR
installShellCompletion --cmd nvs \
--bash <($out/bin/nvs completion bash) \
--fish <($out/bin/nvs completion fish) \
--zsh <($out/bin/nvs completion zsh)
'';
};
}

Binary file not shown.

BIN
secrets/git/config.mac14 Normal file

Binary file not shown.

BIN
secrets/git/config.ordio Normal file

Binary file not shown.

Binary file not shown.

BIN
secrets/ssh/config.template Normal file

Binary file not shown.