Compare commits
117 commits
mybookmark
...
main
Author | SHA1 | Date | |
---|---|---|---|
48af3d5449 | |||
1b367e2322 | |||
cc9fc76545 | |||
dcc102f9bf | |||
6b1a4b5d04 | |||
62246715bb | |||
eb06ace77d | |||
fac0a155e2 | |||
de6547851a | |||
a6013523fa | |||
ad82eb1cbf | |||
3b577407f7 | |||
8e2d043650 | |||
0b6313671c | |||
81f036c147 | |||
f8c7a5ecfe | |||
a93861071d | |||
b5a3d0ec9e | |||
2cd4b5c52a | |||
cea9b407c8 | |||
fec53f5ca0 | |||
ccf59fbaee | |||
f263c95f03 | |||
c68bdd3818 | |||
3ec86e59ba | |||
03e20d83e1 | |||
3ef41dd400 | |||
b82010faf8 | |||
223bff6315 | |||
7a2d1a7e4e | |||
78d818056b | |||
fac15cd4c5 | |||
6d35750873 | |||
476542b697 | |||
b23bc6b9af | |||
4bb1fa1f40 | |||
7152b0bf09 | |||
9ca1072e00 | |||
09694db337 | |||
90b5b48d2a | |||
4766311654 | |||
6dd68098e0 | |||
5032e07ee9 | |||
7954844ff6 | |||
afa495919c | |||
9b9389592e | |||
79e3ffbac3 | |||
a8adda373c | |||
243a476525 | |||
6223f1e7c9 | |||
5a35ac9aeb | |||
70fec1c1f1 | |||
7e89879ae9 | |||
f0710b34fb | |||
f8ad364bc9 | |||
37372a5c69 | |||
13348be8e9 | |||
091442fcdf | |||
a603dd1cad | |||
311cd9042e | |||
9ee84b89e6 | |||
376fb67f48 | |||
be77222a99 | |||
494bd5cad1 | |||
cdc020ff0d | |||
c749caf2e9 | |||
be8780d846 | |||
2497584fd0 | |||
be47c9500b | |||
46c13deee7 | |||
c4a2a60fa6 | |||
714cbcb8a9 | |||
461f3a9a46 | |||
b455010624 | |||
f26beb87bd | |||
8b46fa253d | |||
49d4bbd7c1 | |||
baaf516939 | |||
fa7fce620a | |||
1379ed01f0 | |||
f53cbba16f | |||
f5af1628e7 | |||
0ff88467e6 | |||
195a66d7bf | |||
4c259757db | |||
378fd7caa0 | |||
264546666c | |||
2d5364c5de | |||
da605daf08 | |||
4465aa5abc | |||
aed9af6f45 | |||
5c319ac288 | |||
c94ce60795 | |||
dc126a49d6 | |||
37ddc91613 | |||
7a4712c057 | |||
0357c7ff05 | |||
761b506dac | |||
4dadbe3542 | |||
b6b4abddf5 | |||
b0668e2ef7 | |||
38a179be12 | |||
3dee43330a | |||
e1c3fd6cb8 | |||
a7aa9c7a72 | |||
71660705f0 | |||
dfa99a5d4c | |||
9a31f83e80 | |||
e7d96ac4c0 | |||
18a27db983 | |||
b09da9efbe | |||
e3858e3adf | |||
4e803491d6 | |||
2994a40003 | |||
010e4bc4d7 | |||
8ad810254b | |||
fe829e19c5 |
44 changed files with 1336 additions and 5125 deletions
32
README.md
32
README.md
|
@ -1,31 +1,3 @@
|
||||||
# NixOS Config
|
# Configuration and various sundries
|
||||||
|
|
||||||
IT in a box!
|
IT in a box.
|
||||||
|
|
||||||
## Bootstrapping from a fresh NixOS installation
|
|
||||||
|
|
||||||
1. Install NixOS
|
|
||||||
2. Clone this repo:
|
|
||||||
|
|
||||||
```
|
|
||||||
nix-shell -p git --command 'git clone https://patagia.dev/dln/nixos-config.git'
|
|
||||||
```
|
|
||||||
|
|
||||||
3. Ensure host configuration exists at `./nixos-config/hosts/${HOSTNAME}` and contains at minimum the hardware configuration. The NixOS installer will write this out to `/etc/nixos/hardware-configuration.nix`.
|
|
||||||
4. Apply configuration:
|
|
||||||
```
|
|
||||||
sudo nixos-rebuild boot --flake ./nixos-config#${HOSTNAME}
|
|
||||||
```
|
|
||||||
|
|
||||||
## Use
|
|
||||||
|
|
||||||
1. Clone this repo somewhere convenient, like `~/src/shelman/nixos-config`
|
|
||||||
2. Apply configuration: `just switch`
|
|
||||||
|
|
||||||
## Update
|
|
||||||
|
|
||||||
Update nixpkgs and switch: `just update`
|
|
||||||
|
|
||||||
# Home Manager
|
|
||||||
|
|
||||||
`just home-switch`
|
|
||||||
|
|
|
@ -51,6 +51,18 @@
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
services.avahi = {
|
||||||
|
nssmdns4 = true;
|
||||||
|
enable = true;
|
||||||
|
ipv4 = true;
|
||||||
|
ipv6 = true;
|
||||||
|
publish = {
|
||||||
|
enable = true;
|
||||||
|
addresses = true;
|
||||||
|
workstation = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
# Open ports in the firewall.
|
# Open ports in the firewall.
|
||||||
# networking.firewall.allowedTCPPorts = [ ... ];
|
# networking.firewall.allowedTCPPorts = [ ... ];
|
||||||
# networking.firewall.allowedUDPPorts = [ ... ];
|
# networking.firewall.allowedUDPPorts = [ ... ];
|
||||||
|
|
|
@ -57,10 +57,9 @@ in
|
||||||
};
|
};
|
||||||
packages = with pkgs; [
|
packages = with pkgs; [
|
||||||
inter
|
inter
|
||||||
jetbrains-mono
|
|
||||||
liberation_ttf
|
liberation_ttf
|
||||||
monaspace
|
monaspace
|
||||||
(pkgs.nerdfonts.override { fonts = [ "JetBrainsMono" ]; })
|
nerd-fonts.symbols-only
|
||||||
noto-fonts
|
noto-fonts
|
||||||
noto-fonts-cjk-sans
|
noto-fonts-cjk-sans
|
||||||
noto-fonts-color-emoji
|
noto-fonts-color-emoji
|
||||||
|
@ -94,7 +93,7 @@ in
|
||||||
xkb.variant = "us";
|
xkb.variant = "us";
|
||||||
};
|
};
|
||||||
|
|
||||||
hardware.pulseaudio.enable = false;
|
services.pulseaudio.enable = false;
|
||||||
security.rtkit.enable = true;
|
security.rtkit.enable = true;
|
||||||
services.pipewire = {
|
services.pipewire = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
|
@ -7,12 +7,11 @@
|
||||||
|
|
||||||
let
|
let
|
||||||
inherit (lib) mkIf mkEnableOption;
|
inherit (lib) mkIf mkEnableOption;
|
||||||
cfg = config.patagia.podman;
|
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
options.patagia.laptop.enable = mkEnableOption "Laptop tools and configuration";
|
options.patagia.laptop.enable = mkEnableOption "Laptop tools and configuration";
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
config = mkIf config.patagia.laptop.enable {
|
||||||
environment.systemPackages = with pkgs; [ gnomeExtensions.battery-health-charging ];
|
environment.systemPackages = with pkgs; [ gnomeExtensions.battery-health-charging ];
|
||||||
|
|
||||||
services.fprintd.enable = true;
|
services.fprintd.enable = true;
|
||||||
|
|
|
@ -20,8 +20,7 @@
|
||||||
# Workaround for https://github.com/NixOS/nix/issues/9574
|
# Workaround for https://github.com/NixOS/nix/issues/9574
|
||||||
nix-path = config.nix.nixPath;
|
nix-path = config.nix.nixPath;
|
||||||
substituters = [
|
substituters = [
|
||||||
# "https://cache-nixos-org.aarn.shelman.io"
|
"https://cache-nixos-org.aarn.patagia.net/"
|
||||||
"https://cache.nixos.org/"
|
|
||||||
];
|
];
|
||||||
trusted-public-keys = [ "cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=" ];
|
trusted-public-keys = [ "cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=" ];
|
||||||
extra-substituters = [
|
extra-substituters = [
|
||||||
|
|
|
@ -12,7 +12,7 @@ set fish_emoji_width 2
|
||||||
# Colors
|
# Colors
|
||||||
set fish_color_command --bold
|
set fish_color_command --bold
|
||||||
set fish_color_comment --italics --dim
|
set fish_color_comment --italics --dim
|
||||||
set fish_color_autosuggestion --italics --bold red
|
set fish_color_autosuggestion --italics --bold --dim
|
||||||
set fish_color_cancel
|
set fish_color_cancel
|
||||||
set fish_color_command --bold
|
set fish_color_command --bold
|
||||||
set fish_color_comment --italics --dim
|
set fish_color_comment --italics --dim
|
||||||
|
|
|
@ -1,37 +0,0 @@
|
||||||
set GO_TASK_PROGNAME task
|
|
||||||
|
|
||||||
function __task_get_tasks --description "Prints all available tasks with their description"
|
|
||||||
# Read the list of tasks (and potential errors)
|
|
||||||
$GO_TASK_PROGNAME --list-all 2>&1 | read -lz rawOutput
|
|
||||||
|
|
||||||
# Return on non-zero exit code (for cases when there is no Taskfile found or etc.)
|
|
||||||
if test $status -ne 0
|
|
||||||
return
|
|
||||||
end
|
|
||||||
|
|
||||||
# Grab names and descriptions (if any) of the tasks
|
|
||||||
set -l output (echo $rawOutput | sed -e '1d; s/\* \(.*\):\s*\(.*\)\s*(aliases.*/\1\t\2/' -e 's/\* \(.*\):\s*\(.*\)/\1\t\2/'| string split0)
|
|
||||||
if test $output
|
|
||||||
echo $output
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
complete -c $GO_TASK_PROGNAME -d 'Runs the specified task(s). Falls back to the "default" task if no task name was specified, or lists all tasks if an unknown task name was
|
|
||||||
specified.' -xa "(__task_get_tasks)"
|
|
||||||
|
|
||||||
complete -c $GO_TASK_PROGNAME -s c -l color -d 'colored output (default true)'
|
|
||||||
complete -c $GO_TASK_PROGNAME -s d -l dir -d 'sets directory of execution'
|
|
||||||
complete -c $GO_TASK_PROGNAME -l dry -d 'compiles and prints tasks in the order that they would be run, without executing them'
|
|
||||||
complete -c $GO_TASK_PROGNAME -s f -l force -d 'forces execution even when the task is up-to-date'
|
|
||||||
complete -c $GO_TASK_PROGNAME -s h -l help -d 'shows Task usage'
|
|
||||||
complete -c $GO_TASK_PROGNAME -s i -l init -d 'creates a new Taskfile.yml in the current folder'
|
|
||||||
complete -c $GO_TASK_PROGNAME -s l -l list -d 'lists tasks with description of current Taskfile'
|
|
||||||
complete -c $GO_TASK_PROGNAME -s o -l output -d 'sets output style: [interleaved|group|prefixed]' -xa "interleaved group prefixed"
|
|
||||||
complete -c $GO_TASK_PROGNAME -s p -l parallel -d 'executes tasks provided on command line in parallel'
|
|
||||||
complete -c $GO_TASK_PROGNAME -s s -l silent -d 'disables echoing'
|
|
||||||
complete -c $GO_TASK_PROGNAME -l status -d 'exits with non-zero exit code if any of the given tasks is not up-to-date'
|
|
||||||
complete -c $GO_TASK_PROGNAME -l summary -d 'show summary about a task'
|
|
||||||
complete -c $GO_TASK_PROGNAME -s t -l taskfile -d 'choose which Taskfile to run. Defaults to "Taskfile.yml"'
|
|
||||||
complete -c $GO_TASK_PROGNAME -s v -l verbose -d 'enables verbose mode'
|
|
||||||
complete -c $GO_TASK_PROGNAME -l version -d 'show Task version'
|
|
||||||
complete -c $GO_TASK_PROGNAME -s w -l watch -d 'enables watch of the given task'
|
|
|
@ -1,338 +0,0 @@
|
||||||
# TODO: passthru other args? E.g.. --at-operation, --repository
|
|
||||||
function __jj
|
|
||||||
command jj --ignore-working-copy --color=never --quiet $argv 2>/dev/null
|
|
||||||
end
|
|
||||||
|
|
||||||
# Aliases
|
|
||||||
# Based on https://github.com/fish-shell/fish-shell/blob/cd71359c42f633d9d71a63591ae16d150407a2b2/share/completions/git.fish#L625.
|
|
||||||
#
|
|
||||||
# Aliases are stored in global variables.
|
|
||||||
# `__jj_aliases` is a list of all aliases and `__jj_alias_$alias` is the command line for the alias.
|
|
||||||
function __jj_add_alias
|
|
||||||
set -l alias $argv[1]
|
|
||||||
set -l alias_escaped (string escape --style=var -- $alias)
|
|
||||||
set -g __jj_alias_$alias_escaped $argv
|
|
||||||
set --append -g __jj_aliases $alias
|
|
||||||
end
|
|
||||||
|
|
||||||
__jj config list aliases -T 'concat(name, "\t", value, "\n")' --include-defaults | while read -l config_alias
|
|
||||||
set -l parsed (string match --regex '^aliases\.(.+)\t(.*)$' --groups-only -- $config_alias)
|
|
||||||
set -l alias $parsed[1]
|
|
||||||
set -l command $parsed[2]
|
|
||||||
set -l args $alias
|
|
||||||
# Replace wrapping `[]` if any
|
|
||||||
set -l command (string replace -r --all '^\[|]$' "" -- $command)
|
|
||||||
while test (string length -- $command) -gt 0
|
|
||||||
set -l parsed (string match -r '^"((?:\\\"|[^"])*?)"(?:,\s)?(.*)$' --groups-only -- $command)
|
|
||||||
set --append args $parsed[1]
|
|
||||||
set command $parsed[2]
|
|
||||||
end
|
|
||||||
__jj_add_alias $args
|
|
||||||
end
|
|
||||||
|
|
||||||
__jj_add_alias ci commit
|
|
||||||
__jj_add_alias desc describe
|
|
||||||
__jj_add_alias op operation
|
|
||||||
__jj_add_alias st status
|
|
||||||
|
|
||||||
# Resolve aliases that call another alias.
|
|
||||||
for alias in $__jj_aliases
|
|
||||||
set -l handled $alias
|
|
||||||
|
|
||||||
while true
|
|
||||||
set -l alias_escaped (string escape --style=var -- $alias)
|
|
||||||
set -l alias_varname __jj_alias_$alias_escaped
|
|
||||||
set -l aliased_command $$alias_varname[1][2]
|
|
||||||
set -l aliased_escaped (string escape --style=var -- $aliased_command)
|
|
||||||
set -l aliased_varname __jj_alias_$aliased_escaped
|
|
||||||
set -q $aliased_varname
|
|
||||||
or break
|
|
||||||
|
|
||||||
# Prevent infinite recursion
|
|
||||||
contains $aliased_escaped $handled
|
|
||||||
and break
|
|
||||||
|
|
||||||
# Expand alias in cmdline
|
|
||||||
set -l aliased_cmdline $$aliased_varname[1][2..-1]
|
|
||||||
set --append aliased_cmdline $$alias_varname[1][3..-1]
|
|
||||||
set -g $alias_varname $$alias_varname[1][1] $aliased_cmdline
|
|
||||||
set --append handled $aliased_escaped
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
function __jj_aliases_with_descriptions
|
|
||||||
for alias in $__jj_aliases
|
|
||||||
set -l alias_escaped (string escape --style=var -- $alias)
|
|
||||||
set -l alias_varname __jj_alias_$alias_escaped
|
|
||||||
set -l aliased_cmdline (string join " " -- $$alias_varname[1][2..-1] | string replace -r --all '\\\"' '"')
|
|
||||||
printf "%s\talias: %s\n" $alias $aliased_cmdline
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
# Based on https://github.com/fish-shell/fish-shell/blob/2d4e42ee93327b9cfd554a0d809f85e3d371e70e/share/functions/__fish_seen_subcommand_from.fish.
|
|
||||||
# Test to see if we've seen a subcommand from a list.
|
|
||||||
# This logic may seem backwards, but the commandline will often be much shorter than the list.
|
|
||||||
function __jj_seen_subcommand_from
|
|
||||||
set -l cmd (commandline -opc)
|
|
||||||
set -e cmd[1]
|
|
||||||
|
|
||||||
# Check command line arguments first.
|
|
||||||
for i in $cmd
|
|
||||||
if contains -- $i $argv
|
|
||||||
return 0
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
# Check aliases.
|
|
||||||
set -l alias $cmd[1]
|
|
||||||
set -l alias_escaped (string escape --style=var -- $alias)
|
|
||||||
set -l varname __jj_alias_$alias_escaped
|
|
||||||
set -q $varname
|
|
||||||
or return 1
|
|
||||||
|
|
||||||
for i in $$varname[1][2..-1]
|
|
||||||
if contains -- $i $argv
|
|
||||||
return 0
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
return 1
|
|
||||||
end
|
|
||||||
|
|
||||||
function __jj_changes
|
|
||||||
__jj log --no-graph --limit 1000 -r $argv[1] \
|
|
||||||
-T 'separate("\t", change_id.shortest(), if(description, description.first_line(), "(no description set)")) ++ "\n"'
|
|
||||||
end
|
|
||||||
|
|
||||||
function __jj_bookmarks
|
|
||||||
set -f filter $argv[1]
|
|
||||||
if string length --quiet -- $argv[2]
|
|
||||||
__jj bookmark list --all-remotes -r "$argv[2]" \
|
|
||||||
-T "if($filter, name ++ if(remote, \"@\" ++ remote) ++ \"\t\" ++ if(normal_target, normal_target.change_id().shortest() ++ \": \" ++ if(normal_target.description(), normal_target.description().first_line(), \"(no description set)\"), \"(conflicted bookmark)\") ++ \"\n\")"
|
|
||||||
else
|
|
||||||
__jj bookmark list --all-remotes \
|
|
||||||
-T "if($filter, name ++ if(remote, \"@\" ++ remote) ++ \"\t\" ++ if(normal_target, normal_target.change_id().shortest() ++ \": \" ++ if(normal_target.description(), normal_target.description().first_line(), \"(no description set)\"), \"(conflicted bookmark)\") ++ \"\n\")"
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
function __jj_all_bookmarks
|
|
||||||
__jj_bookmarks '!remote || !remote.starts_with("git")' $argv[1]
|
|
||||||
end
|
|
||||||
|
|
||||||
function __jj_local_bookmarks
|
|
||||||
__jj_bookmarks '!remote' ''
|
|
||||||
end
|
|
||||||
|
|
||||||
function __jj_remote_bookmarks
|
|
||||||
__jj_bookmarks 'remote && !remote.starts_with("git")' ''
|
|
||||||
end
|
|
||||||
|
|
||||||
function __jj_all_changes
|
|
||||||
if string length --quiet -- $argv[1]
|
|
||||||
set -f REV $argv[1]
|
|
||||||
else
|
|
||||||
set -f REV "all()"
|
|
||||||
end
|
|
||||||
__jj_changes $REV
|
|
||||||
__jj_all_bookmarks $REV
|
|
||||||
end
|
|
||||||
|
|
||||||
function __jj_mutable_changes
|
|
||||||
set -f REV "mutable()"
|
|
||||||
__jj_changes $REV
|
|
||||||
__jj_all_bookmarks $REV
|
|
||||||
end
|
|
||||||
|
|
||||||
function __jj_revision_modified_files
|
|
||||||
if test $argv[1] = "@"
|
|
||||||
set -f suffix ""
|
|
||||||
else
|
|
||||||
set -l change_id (__jj log --no-graph --limit 1 -T 'change_id.shortest()')
|
|
||||||
set -f suffix " in $change_id"
|
|
||||||
end
|
|
||||||
|
|
||||||
__jj diff -r $argv[1] --summary | while read -l line
|
|
||||||
set -l file (string split " " -m 1 -- $line)
|
|
||||||
switch $file[1]
|
|
||||||
case M
|
|
||||||
set -f change Modified
|
|
||||||
case D
|
|
||||||
set -f change Deleted
|
|
||||||
case A
|
|
||||||
set -f change Added
|
|
||||||
end
|
|
||||||
printf "%s\t%s%s\n" $file[2] $change $suffix
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
function __jj_remotes
|
|
||||||
__jj git remote list | while read -l remote
|
|
||||||
printf "%s\t%s\n" (string split " " -m 1 -- $remote)
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
function __jj_operations
|
|
||||||
__jj operation log --no-graph --limit 1000 -T 'separate("\t", id.short(), description) ++ "\n"'
|
|
||||||
end
|
|
||||||
|
|
||||||
function __jj_parse_revision
|
|
||||||
set -l cmd (commandline -opc)
|
|
||||||
set -e cmd[1]
|
|
||||||
set -l return_next false
|
|
||||||
set -l return_value 1
|
|
||||||
|
|
||||||
# Check aliases.
|
|
||||||
set -l alias $cmd[1]
|
|
||||||
set -l alias_escaped (string escape --style=var -- $alias)
|
|
||||||
set -l varname __jj_alias_$alias_escaped
|
|
||||||
|
|
||||||
if set -q $varname
|
|
||||||
set cmd $$varname[1][2..-1] $cmd[2..-1]
|
|
||||||
end
|
|
||||||
|
|
||||||
# Check command line arguments first.
|
|
||||||
for i in $cmd
|
|
||||||
if $return_next
|
|
||||||
echo $i
|
|
||||||
set return_value 0
|
|
||||||
else if contains -- $i -r --revision --from
|
|
||||||
set return_next true
|
|
||||||
else
|
|
||||||
set -l match (string match --regex '^(?:-r=?|--revision=|--from=)(.+)\s*$' --groups-only -- $i)
|
|
||||||
if set -q match[1]
|
|
||||||
echo $match[1]
|
|
||||||
set return_value 0
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
return $return_value
|
|
||||||
end
|
|
||||||
|
|
||||||
function __jj_revision_files
|
|
||||||
set -l description (__jj log --no-graph --limit 1 -r $argv[1] -T 'change_id.shortest() ++ ": " ++ coalesce(description.first_line().substr(0, 30), "(no description set)")')
|
|
||||||
__jj file list -r $argv[1] | while read -l file
|
|
||||||
printf "%s\t%s\n" $file $description
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
function __jj_revision_conflicted_files
|
|
||||||
__jj resolve --list -r $argv[1] | while read -l line
|
|
||||||
set -l file (string split " " -m 1 -- $line)
|
|
||||||
printf "%s\t%s\n" $file[1] $file[2]
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
function __jj_parse_revision_files
|
|
||||||
set -l rev (__jj_parse_revision)
|
|
||||||
if test $status -eq 1
|
|
||||||
set rev "@"
|
|
||||||
end
|
|
||||||
__jj_revision_files $rev
|
|
||||||
end
|
|
||||||
|
|
||||||
function __jj_parse_revision_conflicted_files
|
|
||||||
set -l rev (__jj_parse_revision)
|
|
||||||
if test $status -eq 1
|
|
||||||
set rev "@"
|
|
||||||
end
|
|
||||||
__jj_revision_conflicted_files $rev
|
|
||||||
end
|
|
||||||
|
|
||||||
function __jj_parse_revision_files_or_wc_modified_files
|
|
||||||
set -l revs (__jj_parse_revision)
|
|
||||||
if test $status -eq 1
|
|
||||||
__jj_revision_modified_files "@"
|
|
||||||
else
|
|
||||||
for rev in $revs
|
|
||||||
__jj_revision_files $rev
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
function __jj_parse_revision_modified_files_or_wc_modified_files
|
|
||||||
set -l revs (__jj_parse_revision)
|
|
||||||
if test $status -eq 1
|
|
||||||
__jj_revision_modified_files "@"
|
|
||||||
else
|
|
||||||
for rev in $revs
|
|
||||||
__jj_revision_modified_files $rev
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
# Aliases.
|
|
||||||
complete -f -c jj -n __fish_use_subcommand -a '(__jj_aliases_with_descriptions)'
|
|
||||||
|
|
||||||
# Files.
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from file; and __jj_seen_subcommand_from show' -ka '(__jj_parse_revision_files)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from file; and __jj_seen_subcommand_from chmod' -ka '(__jj_parse_revision_files)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from commit' -ka '(__jj_revision_modified_files "@")'
|
|
||||||
complete -c jj -n '__jj_seen_subcommand_from diff' -ka '(__jj_parse_revision_files_or_wc_modified_files)'
|
|
||||||
complete -c jj -n '__jj_seen_subcommand_from interdiff' -ka '(__jj_parse_revision_files)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from resolve' -ka '(__jj_parse_revision_conflicted_files)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from restore' -ka '(__jj_parse_revision_files_or_wc_modified_files)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from split' -ka '(__jj_parse_revision_modified_files_or_wc_modified_files)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from squash' -ka '(__jj_parse_revision_modified_files_or_wc_modified_files)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from untrack' -ka '(__jj_parse_revision_files_or_wc_modified_files)'
|
|
||||||
|
|
||||||
# Revisions.
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from abandon' -ka '(__jj_mutable_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from backout' -s r -l revision -rka '(__jj_all_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from backout' -s d -l destination -rka '(__jj_all_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from file; and __jj_seen_subcommand_from show' -s r -l revision -rka '(__jj_all_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from chmod' -s r -l revision -rka '(__jj_mutable_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from describe' -ka '(__jj_mutable_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from diff' -s r -l revision -rka '(__jj_all_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from diff' -l from -rka '(__jj_all_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from diff' -l to -rka '(__jj_all_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from diffedit' -s r -l revision -rka '(__jj_mutable_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from diffedit' -l from -rka '(__jj_all_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from diffedit' -l to -rka '(__jj_mutable_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from duplicate' -ka '(__jj_all_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from edit' -ka '(__jj_mutable_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from file; and __jj_seen_subcommand_from list' -s r -l revision -rka '(__jj_all_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from interdiff' -l from -rka '(__jj_all_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from interdiff' -l to -rka '(__jj_all_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from log' -s r -rka '(__jj_all_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from new' -ka '(__jj_all_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from new' -s A -l after -l insert-after -rka '(__jj_all_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from new' -s B -l before -l insert-before -rka '(__jj_mutable_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from obslog' -s r -l revision -rka '(__jj_all_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from parallelize' -ka '(__jj_mutable_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from rebase' -s r -l revisions -rka '(__jj_mutable_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from rebase' -s s -l source -rka '(__jj_mutable_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from rebase' -s b -l bookmark -rka '(__jj_mutable_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from rebase' -s d -l destination -rka '(__jj_all_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from rebase' -s A -l after -l insert-after -rka '(__jj_all_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from rebase' -s B -l before -l insert-before -rka '(__jj_mutable_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from resolve' -s r -l revision -rka '(__jj_mutable_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from restore' -l from -rka '(__jj_all_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from restore' -l to -rka '(__jj_mutable_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from restore' -s c -l changes-in -rka '(__jj_all_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from show' -ka '(__jj_all_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from split' -s r -l revision -rka '(__jj_mutable_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from squash' -s r -l revision -rka '(__jj_mutable_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from squash' -l from -rka '(__jj_mutable_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from squash' -l to -l into -rka '(__jj_mutable_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from unsquash' -s r -l revision -rka '(__jj_mutable_changes)'
|
|
||||||
|
|
||||||
# Bookmarks
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from bookmark; and __jj_seen_subcommand_from delete forget rename set d f r s' -ka '(__jj_local_bookmarks)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from bookmark; and __jj_seen_subcommand_from track t' -ka '(__jj_bookmarks "remote && !tracked" "")'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from bookmark; and __jj_seen_subcommand_from untrack' -ka '(__jj_bookmarks "remote && tracked && !remote.starts_with(\"git\")" "")'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from bookmark; and __jj_seen_subcommand_from create move set c m s' -s r -l revision -kra '(__jj_all_changes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from bookmark; and __jj_seen_subcommand_from move' -l from -rka '(__jj_changes "all()")'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from bookmark; and __jj_seen_subcommand_from move' -l to -rka '(__jj_changes "all()")'
|
|
||||||
|
|
||||||
# Git.
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from git; and __jj_seen_subcommand_from push' -s c -l change -kra '(__jj_changes "all()")'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from git; and __jj_seen_subcommand_from push' -s r -l revisions -kra '(__jj_changes "all()")'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from git; and __jj_seen_subcommand_from fetch push' -s b -l bookmark -rka '(__jj_local_bookmarks)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from git; and __jj_seen_subcommand_from fetch push' -l remote -rka '(__jj_remotes)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from git; and __jj_seen_subcommand_from remote; and __jj_seen_subcommand_from remove rename set-url' -ka '(__jj_remotes)'
|
|
||||||
|
|
||||||
# Operations.
|
|
||||||
complete -f -c jj -l at-op -l at-operation -rka '(__jj_operations)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from undo' -ka '(__jj_operations)'
|
|
||||||
complete -f -c jj -n '__jj_seen_subcommand_from operation; and __jj_seen_subcommand_from abandon undo restore' -ka '(__jj_operations)'
|
|
|
@ -53,15 +53,6 @@ function vcs_log
|
||||||
commandline -f repaint
|
commandline -f repaint
|
||||||
end
|
end
|
||||||
|
|
||||||
function vcs_ui
|
|
||||||
if __jj_in_repo
|
|
||||||
lazyjj
|
|
||||||
else
|
|
||||||
gitui
|
|
||||||
end
|
|
||||||
commandline -f repaint
|
|
||||||
end
|
|
||||||
|
|
||||||
# Abbreviations
|
# Abbreviations
|
||||||
|
|
||||||
abbr -a d vcs_diff
|
abbr -a d vcs_diff
|
||||||
|
@ -71,6 +62,9 @@ abbr -a s vcs_status
|
||||||
bind \c_ vcs_jump
|
bind \c_ vcs_jump
|
||||||
bind \ea vcs_log
|
bind \ea vcs_log
|
||||||
bind \ee vcs_broot
|
bind \ee vcs_broot
|
||||||
bind \eg vcs_ui
|
|
||||||
bind \eS vcs_diff
|
bind \eS vcs_diff
|
||||||
bind \es vcs_status
|
bind \es vcs_status
|
||||||
|
|
||||||
|
# jj completions
|
||||||
|
|
||||||
|
COMPLETE=fish jj | source
|
||||||
|
|
|
@ -186,3 +186,109 @@ for i in $(seq 255 -1 128); do
|
||||||
echo -n " "
|
echo -n " "
|
||||||
done
|
done
|
||||||
resetOutput
|
resetOutput
|
||||||
|
|
||||||
|
|
||||||
|
## Color test
|
||||||
|
|
||||||
|
# Tom Hale, 2016. MIT Licence.
|
||||||
|
# Print out 256 colours, with each number printed in its corresponding colour
|
||||||
|
# See http://askubuntu.com/questions/821157/print-a-256-color-test-pattern-in-the-terminal/821163#821163
|
||||||
|
|
||||||
|
set -eu # Fail on errors or undeclared variables
|
||||||
|
|
||||||
|
printable_colours=256
|
||||||
|
|
||||||
|
# Return a colour that contrasts with the given colour
|
||||||
|
# Bash only does integer division, so keep it integral
|
||||||
|
function contrast_colour {
|
||||||
|
local r g b luminance
|
||||||
|
colour="$1"
|
||||||
|
|
||||||
|
if (( colour < 16 )); then # Initial 16 ANSI colours
|
||||||
|
(( colour == 0 )) && printf "15" || printf "0"
|
||||||
|
return
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Greyscale # rgb_R = rgb_G = rgb_B = (number - 232) * 10 + 8
|
||||||
|
if (( colour > 231 )); then # Greyscale ramp
|
||||||
|
(( colour < 244 )) && printf "15" || printf "0"
|
||||||
|
return
|
||||||
|
fi
|
||||||
|
|
||||||
|
# All other colours:
|
||||||
|
# 6x6x6 colour cube = 16 + 36*R + 6*G + B # Where RGB are [0..5]
|
||||||
|
# See http://stackoverflow.com/a/27165165/5353461
|
||||||
|
|
||||||
|
# r=$(( (colour-16) / 36 ))
|
||||||
|
g=$(( ((colour-16) % 36) / 6 ))
|
||||||
|
# b=$(( (colour-16) % 6 ))
|
||||||
|
|
||||||
|
# If luminance is bright, print number in black, white otherwise.
|
||||||
|
# Green contributes 587/1000 to human perceived luminance - ITU R-REC-BT.601
|
||||||
|
(( g > 2)) && printf "0" || printf "15"
|
||||||
|
return
|
||||||
|
|
||||||
|
# Uncomment the below for more precise luminance calculations
|
||||||
|
|
||||||
|
# # Calculate percieved brightness
|
||||||
|
# # See https://www.w3.org/TR/AERT#color-contrast
|
||||||
|
# # and http://www.itu.int/rec/R-REC-BT.601
|
||||||
|
# # Luminance is in range 0..5000 as each value is 0..5
|
||||||
|
# luminance=$(( (r * 299) + (g * 587) + (b * 114) ))
|
||||||
|
# (( $luminance > 2500 )) && printf "0" || printf "15"
|
||||||
|
}
|
||||||
|
|
||||||
|
# Print a coloured block with the number of that colour
|
||||||
|
function print_colour {
|
||||||
|
local colour="$1" contrast
|
||||||
|
contrast=$(contrast_colour "$1")
|
||||||
|
printf "\e[48;5;%sm" "$colour" # Start block of colour
|
||||||
|
printf "\e[38;5;%sm%3d" "$contrast" "$colour" # In contrast, print number
|
||||||
|
printf "\e[0m " # Reset colour
|
||||||
|
}
|
||||||
|
|
||||||
|
# Starting at $1, print a run of $2 colours
|
||||||
|
function print_run {
|
||||||
|
local i
|
||||||
|
for (( i = "$1"; i < "$1" + "$2" && i < printable_colours; i++ )) do
|
||||||
|
print_colour "$i"
|
||||||
|
done
|
||||||
|
printf " "
|
||||||
|
}
|
||||||
|
|
||||||
|
# Print blocks of colours
|
||||||
|
function print_blocks {
|
||||||
|
local start="$1" i
|
||||||
|
local end="$2" # inclusive
|
||||||
|
local block_cols="$3"
|
||||||
|
local block_rows="$4"
|
||||||
|
local blocks_per_line="$5"
|
||||||
|
local block_length=$((block_cols * block_rows))
|
||||||
|
|
||||||
|
# Print sets of blocks
|
||||||
|
for (( i = start; i <= end; i += (blocks_per_line-1) * block_length )) do
|
||||||
|
printf "\n" # Space before each set of blocks
|
||||||
|
# For each block row
|
||||||
|
for (( row = 0; row < block_rows; row++ )) do
|
||||||
|
# Print block columns for all blocks on the line
|
||||||
|
for (( block = 0; block < blocks_per_line; block++ )) do
|
||||||
|
print_run $(( i + (block * block_length) )) "$block_cols"
|
||||||
|
done
|
||||||
|
(( i += block_cols )) # Prepare to print the next row
|
||||||
|
printf "\n"
|
||||||
|
done
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
|
echo
|
||||||
|
echo "ANSI 4-bit colors:"
|
||||||
|
echo
|
||||||
|
|
||||||
|
print_run 0 16 # The first 16 colours are spread over the whole spectrum
|
||||||
|
|
||||||
|
echo
|
||||||
|
echo
|
||||||
|
echo "ANSI 8-bit colors:"
|
||||||
|
|
||||||
|
print_blocks 16 231 6 6 3 # 6x6x6 colour cube between 16 and 231 inclusive
|
||||||
|
print_blocks 232 255 12 2 1 # Not 50, but 24 Shades of Grey
|
||||||
|
|
304
flake.lock
304
flake.lock
|
@ -17,6 +17,22 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"flake-compat_2": {
|
"flake-compat_2": {
|
||||||
|
"flake": false,
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1733328505,
|
||||||
|
"narHash": "sha256-NeCCThCEP3eCl2l/+27kNNK7QrwZB1IJCrXfrbv5oqU=",
|
||||||
|
"owner": "edolstra",
|
||||||
|
"repo": "flake-compat",
|
||||||
|
"rev": "ff81ac966bb2cae68946d5ed5fc4994f96d0ffec",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "edolstra",
|
||||||
|
"repo": "flake-compat",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"flake-compat_3": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1696426674,
|
"lastModified": 1696426674,
|
||||||
|
@ -40,11 +56,11 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1730504689,
|
"lastModified": 1736143030,
|
||||||
"narHash": "sha256-hgmguH29K2fvs9szpq2r3pz2/8cJd2LPS+b4tfNFCwE=",
|
"narHash": "sha256-+hu54pAoLDEZT9pjHlqL9DNzWz0NbUn8NEAHP7PQPzU=",
|
||||||
"owner": "hercules-ci",
|
"owner": "hercules-ci",
|
||||||
"repo": "flake-parts",
|
"repo": "flake-parts",
|
||||||
"rev": "506278e768c2a08bec68eb62932193e341f55c90",
|
"rev": "b905f6fc23a9051a6e1b741e1438dbfc0634c6de",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -62,11 +78,11 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1712014858,
|
"lastModified": 1733312601,
|
||||||
"narHash": "sha256-sB4SWl2lX95bExY2gMFG5HIzvva5AVMJd4Igm+GpZNw=",
|
"narHash": "sha256-4pDvzqnegAfRkPwO3wmwBhVi/Sye1mzps0zHWYnP88c=",
|
||||||
"owner": "hercules-ci",
|
"owner": "hercules-ci",
|
||||||
"repo": "flake-parts",
|
"repo": "flake-parts",
|
||||||
"rev": "9126214d0a59633752a136528f5f3b9aa8565b7d",
|
"rev": "205b12d8b7cd4802fbcb8e8ef6a0f1408781a4f9",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -92,64 +108,60 @@
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"ghostty": {
|
"flake-utils_2": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"nixpkgs-stable": [
|
"systems": "systems_2"
|
||||||
"nixpkgs"
|
|
||||||
],
|
|
||||||
"nixpkgs-unstable": [
|
|
||||||
"nixpkgs"
|
|
||||||
],
|
|
||||||
"zig": "zig"
|
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1731971697,
|
"lastModified": 1731533236,
|
||||||
"narHash": "sha256-6JNMcpy0z19yOLBRt3eE4Rk4A96kcEsRv5+ym1hkv1c=",
|
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
|
||||||
"ref": "refs/heads/main",
|
"owner": "numtide",
|
||||||
"rev": "29c3a52e964a97dddaed876ce472aeb167774acf",
|
"repo": "flake-utils",
|
||||||
"revCount": 8021,
|
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
|
||||||
"type": "git",
|
|
||||||
"url": "ssh://git@github.com/ghostty-org/ghostty"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"type": "git",
|
|
||||||
"url": "ssh://git@github.com/ghostty-org/ghostty"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"ghostty-hm": {
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1702368251,
|
|
||||||
"narHash": "sha256-hafrDmzGplzm+vdIo+LkOjRfA4qRcy5JmpGGksnht5c=",
|
|
||||||
"owner": "clo4",
|
|
||||||
"repo": "ghostty-hm-module",
|
|
||||||
"rev": "887e13a6e7acf5ffaab0119d96e476d84db90904",
|
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "clo4",
|
"owner": "numtide",
|
||||||
"repo": "ghostty-hm-module",
|
"repo": "flake-utils",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"ghostty": {
|
||||||
|
"inputs": {
|
||||||
|
"flake-compat": "flake-compat",
|
||||||
|
"nixpkgs-stable": "nixpkgs-stable",
|
||||||
|
"nixpkgs-unstable": "nixpkgs-unstable",
|
||||||
|
"zig": "zig"
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1736911212,
|
||||||
|
"narHash": "sha256-OLly4X2kN1tDb2gMYcWeim6uJECPoc52ltJsz1iD5Ug=",
|
||||||
|
"owner": "ghostty-org",
|
||||||
|
"repo": "ghostty",
|
||||||
|
"rev": "ff9414d9ea7b16a375d41cde8f6f193de7e5db72",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "ghostty-org",
|
||||||
|
"repo": "ghostty",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"git-hooks": {
|
"git-hooks": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"flake-compat": "flake-compat_2",
|
"flake-compat": "flake-compat_3",
|
||||||
"gitignore": "gitignore",
|
"gitignore": "gitignore",
|
||||||
"nixpkgs": [
|
"nixpkgs": [
|
||||||
"neovim-nightly-overlay",
|
"neovim-nightly-overlay",
|
||||||
"nixpkgs"
|
"nixpkgs"
|
||||||
],
|
|
||||||
"nixpkgs-stable": [
|
|
||||||
"neovim-nightly-overlay",
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1731363552,
|
"lastModified": 1735882644,
|
||||||
"narHash": "sha256-vFta1uHnD29VUY4HJOO/D6p6rxyObnf+InnSMT4jlMU=",
|
"narHash": "sha256-3FZAG+pGt3OElQjesCAWeMkQ7C/nB1oTHLRQ8ceP110=",
|
||||||
"owner": "cachix",
|
"owner": "cachix",
|
||||||
"repo": "git-hooks.nix",
|
"repo": "git-hooks.nix",
|
||||||
"rev": "cd1af27aa85026ac759d5d3fccf650abe7e1bbf0",
|
"rev": "a5a961387e75ae44cc20f0a57ae463da5e959656",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -189,11 +201,11 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1730903510,
|
"lastModified": 1735695978,
|
||||||
"narHash": "sha256-mnynlrPeiW0nUQ8KGZHb3WyxAxA3Ye/BH8gMjdoKP6E=",
|
"narHash": "sha256-cwk53OX1S1bCFY09zydubZNmmwcx9l5XEba8mVYuNE4=",
|
||||||
"owner": "hercules-ci",
|
"owner": "hercules-ci",
|
||||||
"repo": "hercules-ci-effects",
|
"repo": "hercules-ci-effects",
|
||||||
"rev": "b89ac4d66d618b915b1f0a408e2775fe3821d141",
|
"rev": "f6233b5cfbada692d93a73d6ed35bdbfd0fdb9c4",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -209,11 +221,11 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1731968878,
|
"lastModified": 1736785676,
|
||||||
"narHash": "sha256-+hTCwETOE9N8voTAaF+IzdUZz28Ws3LDpH90FWADrEE=",
|
"narHash": "sha256-TY0jUwR3EW0fnS0X5wXMAVy6h4Z7Y6a3m+Yq++C9AyE=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "home-manager",
|
"repo": "home-manager",
|
||||||
"rev": "a42fa14b53ceab66274a21da480c9f8e06204173",
|
"rev": "fc52a210b60f2f52c74eac41a8647c1573d2071d",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -222,21 +234,43 @@
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"jujutsu": {
|
||||||
|
"inputs": {
|
||||||
|
"flake-utils": "flake-utils_2",
|
||||||
|
"nixpkgs": "nixpkgs",
|
||||||
|
"rust-overlay": "rust-overlay"
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1735928141,
|
||||||
|
"narHash": "sha256-KN5rfdDj3vB/GNVw4YZU4tJv2BnUQiQdOz1kEQyketI=",
|
||||||
|
"owner": "dln",
|
||||||
|
"repo": "jj",
|
||||||
|
"rev": "cb103fb4692c4e2b90c4663804b81a5ff1e49c06",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "dln",
|
||||||
|
"ref": "openssh",
|
||||||
|
"repo": "jj",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
"neovim-nightly-overlay": {
|
"neovim-nightly-overlay": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"flake-compat": "flake-compat",
|
"flake-compat": "flake-compat_2",
|
||||||
"flake-parts": "flake-parts",
|
"flake-parts": "flake-parts",
|
||||||
"git-hooks": "git-hooks",
|
"git-hooks": "git-hooks",
|
||||||
"hercules-ci-effects": "hercules-ci-effects",
|
"hercules-ci-effects": "hercules-ci-effects",
|
||||||
"neovim-src": "neovim-src",
|
"neovim-src": "neovim-src",
|
||||||
"nixpkgs": "nixpkgs"
|
"nixpkgs": "nixpkgs_2",
|
||||||
|
"treefmt-nix": "treefmt-nix"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1732002290,
|
"lastModified": 1736924666,
|
||||||
"narHash": "sha256-v17KxlCf0O7hoD9AjiF94T2nuZuh7ZREyI6Ww/Tr4R0=",
|
"narHash": "sha256-1Mnw9hNMmsnfZuNbeTgmRev99vLZ9FsgrfCChjwnzSk=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "neovim-nightly-overlay",
|
"repo": "neovim-nightly-overlay",
|
||||||
"rev": "2a9b9e821c7f91eb6ae540925a453f9ebacd0513",
|
"rev": "7e61ee6d94536d30888c2fbeb1e9d53f4aa3f8b8",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -248,11 +282,11 @@
|
||||||
"neovim-src": {
|
"neovim-src": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1731949793,
|
"lastModified": 1736864394,
|
||||||
"narHash": "sha256-ZXZInL8J38JaVpglSPa78ptn1zlqbaRHDtpa73CqpfI=",
|
"narHash": "sha256-QEbgudJG4M9kVmuhGDEG2EP397zAbPmnZ5DX2GFwZCI=",
|
||||||
"owner": "neovim",
|
"owner": "neovim",
|
||||||
"repo": "neovim",
|
"repo": "neovim",
|
||||||
"rev": "989a37a594649528f28432388c0e7e28e8be2753",
|
"rev": "e8a6c1b02122852da83dc52184e78369598d8240",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -261,6 +295,26 @@
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"nix-index-database": {
|
||||||
|
"inputs": {
|
||||||
|
"nixpkgs": [
|
||||||
|
"nixpkgs"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1736652904,
|
||||||
|
"narHash": "sha256-8uolHABgroXqzs03QdulHp8H9e5kWQZnnhcda1MKbBM=",
|
||||||
|
"owner": "nix-community",
|
||||||
|
"repo": "nix-index-database",
|
||||||
|
"rev": "271e5bd7c57e1f001693799518b10a02d1123b12",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "nix-community",
|
||||||
|
"repo": "nix-index-database",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1731890469,
|
"lastModified": 1731890469,
|
||||||
|
@ -279,27 +333,59 @@
|
||||||
},
|
},
|
||||||
"nixpkgs-stable": {
|
"nixpkgs-stable": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1731797254,
|
"lastModified": 1733423277,
|
||||||
"narHash": "sha256-df3dJApLPhd11AlueuoN0Q4fHo/hagP75LlM5K1sz9g=",
|
"narHash": "sha256-TxabjxEgkNbCGFRHgM/b9yZWlBj60gUOUnRT/wbVQR8=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "e8c38b73aeb218e27163376a2d617e61a2ad9b59",
|
"rev": "e36963a147267afc055f7cf65225958633e536bf",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"ref": "nixos-24.05",
|
"ref": "release-24.11",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"nixpkgs-stable_2": {
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1736867362,
|
||||||
|
"narHash": "sha256-i/UJ5I7HoqmFMwZEH6vAvBxOrjjOJNU739lnZnhUln8=",
|
||||||
|
"owner": "nixos",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"rev": "9c6b49aeac36e2ed73a8c472f1546f6d9cf1addc",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "nixos",
|
||||||
|
"ref": "nixos-24.11",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nixpkgs-unstable": {
|
"nixpkgs-unstable": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1731890469,
|
"lastModified": 1733229606,
|
||||||
"narHash": "sha256-D1FNZ70NmQEwNxpSSdTXCSklBH1z2isPR84J6DQrJGs=",
|
"narHash": "sha256-FLYY5M0rpa5C2QAE3CKLYAM6TwbKicdRK6qNrSHlNrE=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "5083ec887760adfe12af64830a66807423a859a7",
|
"rev": "566e53c2ad750c84f6d31f9ccb9d00f823165550",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "nixos",
|
||||||
|
"ref": "nixpkgs-unstable",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"nixpkgs-unstable_2": {
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1736848588,
|
||||||
|
"narHash": "sha256-9B6fQqphF3j9lpcxQnKyIUgp3NyGi7ikb9CjCYqixcY=",
|
||||||
|
"owner": "nixos",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"rev": "357cd3dfdb8993af11268d755d53357720675e66",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -311,11 +397,27 @@
|
||||||
},
|
},
|
||||||
"nixpkgs_2": {
|
"nixpkgs_2": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1731676054,
|
"lastModified": 1736848588,
|
||||||
"narHash": "sha256-OZiZ3m8SCMfh3B6bfGC/Bm4x3qc1m2SVEAlkV6iY7Yg=",
|
"narHash": "sha256-9B6fQqphF3j9lpcxQnKyIUgp3NyGi7ikb9CjCYqixcY=",
|
||||||
|
"owner": "NixOS",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"rev": "357cd3dfdb8993af11268d755d53357720675e66",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "NixOS",
|
||||||
|
"ref": "nixpkgs-unstable",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"nixpkgs_3": {
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1736798957,
|
||||||
|
"narHash": "sha256-qwpCtZhSsSNQtK4xYGzMiyEDhkNzOCz/Vfu4oL2ETsQ=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "5e4fbfb6b3de1aa2872b76d49fafc942626e2add",
|
"rev": "9abb87b552b7f55ac8916b6fc9e5cb486656a2f3",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -328,12 +430,34 @@
|
||||||
"root": {
|
"root": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"ghostty": "ghostty",
|
"ghostty": "ghostty",
|
||||||
"ghostty-hm": "ghostty-hm",
|
|
||||||
"home-manager": "home-manager",
|
"home-manager": "home-manager",
|
||||||
|
"jujutsu": "jujutsu",
|
||||||
"neovim-nightly-overlay": "neovim-nightly-overlay",
|
"neovim-nightly-overlay": "neovim-nightly-overlay",
|
||||||
"nixpkgs": "nixpkgs_2",
|
"nix-index-database": "nix-index-database",
|
||||||
"nixpkgs-stable": "nixpkgs-stable",
|
"nixpkgs": "nixpkgs_3",
|
||||||
"nixpkgs-unstable": "nixpkgs-unstable"
|
"nixpkgs-stable": "nixpkgs-stable_2",
|
||||||
|
"nixpkgs-unstable": "nixpkgs-unstable_2"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"rust-overlay": {
|
||||||
|
"inputs": {
|
||||||
|
"nixpkgs": [
|
||||||
|
"jujutsu",
|
||||||
|
"nixpkgs"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1732242723,
|
||||||
|
"narHash": "sha256-NWI8csIK0ujFlFuEXKnoc+7hWoCiEtINK9r48LUUMeU=",
|
||||||
|
"owner": "oxalica",
|
||||||
|
"repo": "rust-overlay",
|
||||||
|
"rev": "a229311fcb45b88a95fdfa5cecd8349c809a272a",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "oxalica",
|
||||||
|
"repo": "rust-overlay",
|
||||||
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"systems": {
|
"systems": {
|
||||||
|
@ -351,6 +475,42 @@
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"systems_2": {
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1681028828,
|
||||||
|
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||||
|
"owner": "nix-systems",
|
||||||
|
"repo": "default",
|
||||||
|
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "nix-systems",
|
||||||
|
"repo": "default",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"treefmt-nix": {
|
||||||
|
"inputs": {
|
||||||
|
"nixpkgs": [
|
||||||
|
"neovim-nightly-overlay",
|
||||||
|
"nixpkgs"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1736154270,
|
||||||
|
"narHash": "sha256-p2r8xhQZ3TYIEKBoiEhllKWQqWNJNoT9v64Vmg4q8Zw=",
|
||||||
|
"owner": "numtide",
|
||||||
|
"repo": "treefmt-nix",
|
||||||
|
"rev": "13c913f5deb3a5c08bb810efd89dc8cb24dd968b",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "numtide",
|
||||||
|
"repo": "treefmt-nix",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
"zig": {
|
"zig": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"flake-compat": [
|
"flake-compat": [
|
||||||
|
|
26
flake.nix
26
flake.nix
|
@ -3,7 +3,7 @@
|
||||||
|
|
||||||
nixConfig = {
|
nixConfig = {
|
||||||
substituters = [
|
substituters = [
|
||||||
"https://cache.nixos.org/"
|
"https://cache-nixos-org.aarn.patagia.net/"
|
||||||
];
|
];
|
||||||
extra-substituters = [
|
extra-substituters = [
|
||||||
"https://nix-community.cachix.org"
|
"https://nix-community.cachix.org"
|
||||||
|
@ -14,29 +14,25 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
|
ghostty.url = "github:ghostty-org/ghostty";
|
||||||
|
jujutsu.url = "github:dln/jj/openssh";
|
||||||
neovim-nightly-overlay.url = "github:nix-community/neovim-nightly-overlay";
|
neovim-nightly-overlay.url = "github:nix-community/neovim-nightly-overlay";
|
||||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||||
nixpkgs-stable.url = "github:nixos/nixpkgs/nixos-24.05";
|
nixpkgs-stable.url = "github:nixos/nixpkgs/nixos-24.11";
|
||||||
nixpkgs-unstable.url = "github:nixos/nixpkgs/nixpkgs-unstable";
|
nixpkgs-unstable.url = "github:nixos/nixpkgs/nixpkgs-unstable";
|
||||||
|
|
||||||
|
nix-index-database.url = "github:nix-community/nix-index-database";
|
||||||
|
nix-index-database.inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
|
||||||
home-manager.url = "github:nix-community/home-manager";
|
home-manager.url = "github:nix-community/home-manager";
|
||||||
home-manager.inputs.nixpkgs.follows = "nixpkgs";
|
home-manager.inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
|
||||||
ghostty = {
|
|
||||||
url = "git+ssh://git@github.com/ghostty-org/ghostty";
|
|
||||||
inputs = {
|
|
||||||
nixpkgs-stable.follows = "nixpkgs";
|
|
||||||
nixpkgs-unstable.follows = "nixpkgs";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
ghostty-hm.url = "github:clo4/ghostty-hm-module";
|
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs =
|
outputs =
|
||||||
inputs@{
|
inputs@{
|
||||||
self,
|
self,
|
||||||
|
nix-index-database,
|
||||||
nixpkgs,
|
nixpkgs,
|
||||||
ghostty-hm,
|
|
||||||
home-manager,
|
home-manager,
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
|
@ -62,8 +58,8 @@
|
||||||
inherit inputs outputs;
|
inherit inputs outputs;
|
||||||
};
|
};
|
||||||
modules = [
|
modules = [
|
||||||
ghostty-hm.homeModules.default
|
|
||||||
./home/common
|
./home/common
|
||||||
|
nix-index-database.hmModules.nix-index
|
||||||
] ++ modules;
|
] ++ modules;
|
||||||
};
|
};
|
||||||
in
|
in
|
||||||
|
@ -74,6 +70,9 @@
|
||||||
packages = with pkgs; [
|
packages = with pkgs; [
|
||||||
just
|
just
|
||||||
nh
|
nh
|
||||||
|
nil
|
||||||
|
nixd
|
||||||
|
nixfmt-rfc-style
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -87,7 +86,6 @@
|
||||||
"dln@dinky" = mkHome [ ./home/dln/dinky.nix ];
|
"dln@dinky" = mkHome [ ./home/dln/dinky.nix ];
|
||||||
"dln@nemo" = mkHome [ ./home/dln/nemo.nix ];
|
"dln@nemo" = mkHome [ ./home/dln/nemo.nix ];
|
||||||
"dln@pearl" = mkHome [ ./home/dln/pearl.nix ];
|
"dln@pearl" = mkHome [ ./home/dln/pearl.nix ];
|
||||||
"lsjostro@nemo" = mkHome [ ./home/lsjostro/nemo.nix ];
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
search_mode_shell_up_key_binding = "prefix";
|
search_mode_shell_up_key_binding = "prefix";
|
||||||
show_help = false;
|
show_help = false;
|
||||||
style = "compact";
|
style = "compact";
|
||||||
sync_address = "https://atuin.patagia.dev";
|
sync_address = "https://atuin.patagia.net";
|
||||||
sync.records = true;
|
sync.records = true;
|
||||||
|
|
||||||
daemon = {
|
daemon = {
|
||||||
|
|
|
@ -19,4 +19,6 @@
|
||||||
];
|
];
|
||||||
|
|
||||||
options.patagia.desktop.enable = lib.mkEnableOption "Desktop environment";
|
options.patagia.desktop.enable = lib.mkEnableOption "Desktop environment";
|
||||||
|
options.patagia.laptop.enable = lib.mkEnableOption "Laptop";
|
||||||
|
options.patagia.oled.enable = lib.mkEnableOption "Darker darks on oled screens";
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,33 +2,16 @@
|
||||||
{
|
{
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
age-plugin-fido2-hmac
|
age-plugin-fido2-hmac
|
||||||
bacon
|
|
||||||
cargo
|
|
||||||
clang
|
|
||||||
codeium
|
|
||||||
comma
|
comma
|
||||||
dogdns
|
dogdns
|
||||||
file
|
file
|
||||||
gnumake
|
|
||||||
go
|
|
||||||
just
|
just
|
||||||
ldns
|
|
||||||
minio-client
|
|
||||||
nil
|
|
||||||
nix-output-monitor
|
nix-output-monitor
|
||||||
nixd
|
|
||||||
nixfmt-rfc-style
|
|
||||||
nodejs_22
|
|
||||||
passage
|
passage
|
||||||
rage
|
rage
|
||||||
prettierd
|
|
||||||
rust-analyzer
|
|
||||||
rustc
|
|
||||||
stylua
|
|
||||||
tree-sitter
|
|
||||||
];
|
];
|
||||||
|
|
||||||
home.sessionVariables = {
|
home.sessionVariables = {
|
||||||
GOPROXY = "https://athena.patagia.dev";
|
GOPROXY = "https://athena.patagia.net";
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,12 +3,7 @@
|
||||||
programs.fish = {
|
programs.fish = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
||||||
|
|
||||||
plugins = [
|
plugins = [
|
||||||
{
|
|
||||||
name = "grc";
|
|
||||||
src = pkgs.fishPlugins.grc.src;
|
|
||||||
}
|
|
||||||
{
|
{
|
||||||
name = "transient";
|
name = "transient";
|
||||||
src = pkgs.fishPlugins.transient-fish.src;
|
src = pkgs.fishPlugins.transient-fish.src;
|
||||||
|
@ -43,40 +38,11 @@
|
||||||
body = ''confirm "⚠ Really shutdown $(hostname)?" && command shutdown $argv'';
|
body = ''confirm "⚠ Really shutdown $(hostname)?" && command shutdown $argv'';
|
||||||
};
|
};
|
||||||
|
|
||||||
tmux-refresh-env = {
|
e = {
|
||||||
description = "Refresh environment variables from tmux session";
|
description = "Open a file in already running nvim";
|
||||||
body = ''
|
|
||||||
for var in (tmux show-environment | string match -rv '^-')
|
|
||||||
set -l parts (string split -m 1 '=' $var)
|
|
||||||
if test (count $parts) -eq 2
|
|
||||||
set -Ux $parts[1] $parts[2]
|
|
||||||
end
|
|
||||||
end
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
kubectl = {
|
|
||||||
description = "Wraps kubectl in grc";
|
|
||||||
wraps = "kubectl";
|
|
||||||
body = "grc.wrap kubectl $argv";
|
|
||||||
};
|
|
||||||
|
|
||||||
edit = {
|
|
||||||
description = "Open a file in already running nvim and switch tab";
|
|
||||||
argumentNames = [ "file" ];
|
argumentNames = [ "file" ];
|
||||||
body = ''
|
body = ''
|
||||||
set _file (readlink -f "$file")
|
nvim-remote --remote (readlink -f "$file")
|
||||||
if test -z "$file"
|
|
||||||
set _root (vcs_root)
|
|
||||||
set _file (fd --type f . "$_root" | sed -e "s#^$_root/##" | fzf --no-sort --layout=reverse)
|
|
||||||
set _file "$_root/$_file"
|
|
||||||
end
|
|
||||||
set _nvim_socket "$XDG_RUNTIME_DIR/nvim-persistent.sock"
|
|
||||||
if test -S "$_nvim_socket" && tmux select-window -t nvim 2>/dev/null
|
|
||||||
nvim --server "$_nvim_socket" --remote "$_file"
|
|
||||||
return 0
|
|
||||||
end
|
|
||||||
tmux new-window -S -n nvim nvim --listen "$_nvim_socket" "$_file"
|
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -94,31 +60,12 @@
|
||||||
return 1
|
return 1
|
||||||
end
|
end
|
||||||
|
|
||||||
# Generate prompt
|
|
||||||
jj log --ignore-working-copy --no-graph --color never -r @ -T '
|
jj log --ignore-working-copy --no-graph --color never -r @ -T '
|
||||||
surround(
|
surround(
|
||||||
" \e[2;3m",
|
" \e[2;3m",
|
||||||
"\e[0m",
|
"\e[0m",
|
||||||
separate(
|
separate(
|
||||||
" ",
|
" ",
|
||||||
surround("\e[0;1;95m ", "\e[0;2;3m", change_id.shortest()),
|
|
||||||
surround("\e[0;35m ", "\e[0m", bookmarks.join("╱")),
|
|
||||||
surround("\e[0;34m ", "\e[0;2;3m", commit_id.shortest()),
|
|
||||||
if(conflict, ""),
|
|
||||||
if(empty, ""),
|
|
||||||
if(divergent, ""),
|
|
||||||
if(hidden, ""),
|
|
||||||
)
|
|
||||||
)
|
|
||||||
'
|
|
||||||
'';
|
|
||||||
|
|
||||||
fish_jj_desc.body = ''
|
|
||||||
if not command -sq jj || not jj root --quiet &>/dev/null
|
|
||||||
return 1
|
|
||||||
end
|
|
||||||
|
|
||||||
jj log --ignore-working-copy --no-graph --color never -r @ -T '
|
|
||||||
surround(
|
surround(
|
||||||
"\e[0;2;3m",
|
"\e[0;2;3m",
|
||||||
"\e[0m",
|
"\e[0m",
|
||||||
|
@ -134,29 +81,27 @@
|
||||||
),
|
),
|
||||||
"…"
|
"…"
|
||||||
),
|
),
|
||||||
|
),
|
||||||
|
surround("\e[0;1;95m ", "\e[0;2;3m", change_id.shortest()),
|
||||||
|
surround("\e[0;35m ", "\e[0m", bookmarks.join("╱")),
|
||||||
|
surround("\e[0;34m ", "\e[0;2;3m", commit_id.shortest()),
|
||||||
|
if(conflict, ""),
|
||||||
|
if(empty, ""),
|
||||||
|
if(divergent, ""),
|
||||||
|
if(hidden, ""),
|
||||||
|
)
|
||||||
)
|
)
|
||||||
'
|
'
|
||||||
'';
|
'';
|
||||||
|
|
||||||
fish_prompt.body = ''
|
fish_prompt.body = ''
|
||||||
echo -e "\033[1;2;38;5;236m"
|
echo -e "\033[s\033[$LINES;1H\033[1;2;38;5;238m$(string pad -c '┄' -w $COLUMNS (fish_jj_prompt || fish_vcs_prompt))\033[0m\033[u"
|
||||||
string pad -c '┄' -w $COLUMNS (fish_jj_desc)
|
string join "" -- (set_color --dim) (prompt_hostname) ':' (prompt_pwd --full-length-dirs=4) (set_color --bold normal) ' ❯ ' (set_color normal)
|
||||||
echo -ne "\033[0;3m"
|
|
||||||
string join "" -- (set_color --italics) (prompt_hostname) ':' (prompt_pwd --full-length-dirs=4) (set_color yellow) ' ❯ ' (set_color normal)
|
|
||||||
'';
|
|
||||||
|
|
||||||
fish_right_prompt.body = ''
|
|
||||||
if test $CMD_DURATION -gt 3000
|
|
||||||
# Show duration of the last command in seconds
|
|
||||||
set duration (echo "$CMD_DURATION 1000" | awk '{printf "%.1fs", $1 / $2}')
|
|
||||||
echo -n "⏳$duration "
|
|
||||||
end
|
|
||||||
fish_jj_prompt || fish_vcs_prompt
|
|
||||||
'';
|
'';
|
||||||
|
|
||||||
transient_prompt_func.body = ''
|
transient_prompt_func.body = ''
|
||||||
echo
|
echo
|
||||||
string join "" -- (set_color yellow) '❯ ' (set_color normal)
|
string join "" -- (set_color --bold) '❯ ' (set_color normal)
|
||||||
'';
|
'';
|
||||||
|
|
||||||
rg.body = ''
|
rg.body = ''
|
||||||
|
@ -171,19 +116,14 @@
|
||||||
interactiveShellInit = lib.concatStringsSep "\n" [
|
interactiveShellInit = lib.concatStringsSep "\n" [
|
||||||
(builtins.readFile ../../files/config/fish/config.fish)
|
(builtins.readFile ../../files/config/fish/config.fish)
|
||||||
(builtins.readFile ../../files/config/fish/semantic-prompt.fish)
|
(builtins.readFile ../../files/config/fish/semantic-prompt.fish)
|
||||||
(builtins.readFile ../../files/config/fish/go-task.fish)
|
|
||||||
(builtins.readFile ../../files/config/fish/jj.fish)
|
|
||||||
(builtins.readFile ../../files/config/fish/vcs.fish)
|
(builtins.readFile ../../files/config/fish/vcs.fish)
|
||||||
];
|
];
|
||||||
|
|
||||||
shellAbbrs = {
|
shellAbbrs = {
|
||||||
e = "edit";
|
|
||||||
l = "bat";
|
l = "bat";
|
||||||
ls = "eza";
|
|
||||||
tree = "eza --tree";
|
|
||||||
top = "btm --basic --enable_cache_memory --battery";
|
top = "btm --basic --enable_cache_memory --battery";
|
||||||
ts = "TZ=Z date '+%Y%m%dT%H%M%SZ'";
|
ts = "TZ=Z date '+%Y%m%dT%H%M%SZ'";
|
||||||
w = "viddy -n1 $history[1]";
|
w = "viddy $history[1]";
|
||||||
xc = "fish_clipboard_copy";
|
xc = "fish_clipboard_copy";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -5,82 +5,59 @@
|
||||||
pkgs,
|
pkgs,
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
let
|
|
||||||
launch-ghostty = pkgs.writeShellApplication {
|
|
||||||
name = "launch-ghostty";
|
|
||||||
text = ''
|
|
||||||
if [ "$(gsettings get org.gnome.desktop.interface color-scheme)" = "'prefer-dark'" ]; then
|
|
||||||
theme="theme_dark"
|
|
||||||
else
|
|
||||||
theme="theme_light"
|
|
||||||
fi
|
|
||||||
exec ghostty --config-file="$HOME/.config/ghostty/$theme" "$@"
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
in
|
|
||||||
{
|
{
|
||||||
config = lib.mkIf config.patagia.desktop.enable {
|
config = lib.mkIf config.patagia.desktop.enable {
|
||||||
|
|
||||||
home.packages = with pkgs; [
|
|
||||||
inputs.ghostty.packages.${pkgs.system}.default
|
|
||||||
launch-ghostty
|
|
||||||
];
|
|
||||||
|
|
||||||
programs.ghostty = {
|
programs.ghostty = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
enableFishIntegration = true;
|
||||||
|
package = inputs.ghostty.packages.${pkgs.system}.default;
|
||||||
settings = {
|
settings = {
|
||||||
font-size = 14;
|
font-size = 12.5;
|
||||||
font-family = "Berkeley Mono Variable";
|
font-family = "TX-02";
|
||||||
font-family-bold-italic = "Monaspace Xenon";
|
font-family-bold-italic = "Monaspace Xenon";
|
||||||
|
font-style-bold = "Bold";
|
||||||
|
font-style-italic = "Light Oblique";
|
||||||
font-style-bold-italic = "ExtraLight Italic";
|
font-style-bold-italic = "ExtraLight Italic";
|
||||||
font-synthetic-style = false;
|
font-synthetic-style = false;
|
||||||
font-variation-italic = [ "wght=100" ];
|
|
||||||
|
|
||||||
adjust-cell-height = 1;
|
adjust-cursor-thickness = 4;
|
||||||
adjust-cursor-thickness = 5;
|
adjust-underline-position = 5;
|
||||||
adjust-font-baseline = 1;
|
adjust-underline-thickness = -2;
|
||||||
adjust-underline-position = 2;
|
|
||||||
adjust-underline-thickness = -1;
|
|
||||||
|
|
||||||
mouse-hide-while-typing = true;
|
mouse-hide-while-typing = true;
|
||||||
cursor-style = "block";
|
|
||||||
unfocused-split-opacity = 1.0;
|
unfocused-split-opacity = 1.0;
|
||||||
|
|
||||||
shell-integration = "fish";
|
shell-integration = "fish";
|
||||||
|
|
||||||
window-decoration = false;
|
gtk-tabs-location = "hidden";
|
||||||
gtk-tabs-location = "bottom";
|
gtk-titlebar = true;
|
||||||
gtk-titlebar = false;
|
gtk-titlebar-hide-when-maximized = true;
|
||||||
window-padding-x = 12;
|
|
||||||
window-padding-y = 0;
|
|
||||||
window-padding-balance = true;
|
window-padding-balance = true;
|
||||||
window-padding-color = "extend";
|
window-padding-color = "extend";
|
||||||
window-theme = "system";
|
window-theme = "system";
|
||||||
|
theme = "light:PatagiaLight,dark:PatagiaDark";
|
||||||
|
|
||||||
keybind = [
|
keybind = [
|
||||||
"alt+shift+c=copy_to_clipboard"
|
"alt+shift+c=copy_to_clipboard"
|
||||||
"alt+shift+v=paste_from_clipboard"
|
"alt+shift+v=paste_from_clipboard"
|
||||||
|
"ctrl+i=text:\\x09"
|
||||||
|
"ctrl+m=text:\\x0D"
|
||||||
"ctrl+tab=goto_split:previous"
|
"ctrl+tab=goto_split:previous"
|
||||||
|
"ctrl+[=text:\\x1B"
|
||||||
"super+enter=toggle_fullscreen"
|
"super+enter=toggle_fullscreen"
|
||||||
"ctrl+enter=unbind"
|
|
||||||
"alt+one=unbind"
|
|
||||||
"alt+two=unbind"
|
|
||||||
"alt+three=unbind"
|
|
||||||
"alt+four=unbind"
|
|
||||||
"alt+five=unbind"
|
|
||||||
"alt+six=unbind"
|
|
||||||
"alt+seven=unbind"
|
|
||||||
"alt+eight=unbind"
|
|
||||||
"alt+nine=unbind"
|
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
xdg.configFile."ghostty/theme_dark".text = ''
|
xdg.configFile."ghostty/themes/PatagiaDark".text =
|
||||||
background = #0d1117
|
let
|
||||||
foreground = #b2b2b2
|
background = if config.patagia.oled.enable then "#000000" else "#14151a";
|
||||||
cursor-color = #00d992
|
in
|
||||||
selection-background = #d7d7d7
|
''
|
||||||
|
background = "${background}"
|
||||||
|
foreground = #b7bec7
|
||||||
|
cursor-color = #e7e7b7
|
||||||
|
selection-background = #84979f
|
||||||
selection-foreground = #000000
|
selection-foreground = #000000
|
||||||
palette = 0=#000000
|
palette = 0=#000000
|
||||||
palette = 1=#ff0035
|
palette = 1=#ff0035
|
||||||
|
@ -89,7 +66,7 @@ in
|
||||||
palette = 4=#00a7ff
|
palette = 4=#00a7ff
|
||||||
palette = 5=#cb01ff
|
palette = 5=#cb01ff
|
||||||
palette = 6=#00e0ff
|
palette = 6=#00e0ff
|
||||||
palette = 7=#f0f0f0
|
palette = 7=#b7bec7
|
||||||
palette = 8=#444444
|
palette = 8=#444444
|
||||||
palette = 9=#ff8c88
|
palette = 9=#ff8c88
|
||||||
palette = 10=#baff94
|
palette = 10=#baff94
|
||||||
|
@ -100,7 +77,7 @@ in
|
||||||
palette = 15=#ffffff
|
palette = 15=#ffffff
|
||||||
'';
|
'';
|
||||||
|
|
||||||
xdg.configFile."ghostty/theme_light".text = ''
|
xdg.configFile."ghostty/themes/PatagiaLight".text = ''
|
||||||
background = #fefeff
|
background = #fefeff
|
||||||
foreground = #222222
|
foreground = #222222
|
||||||
cursor-color = #aa0000
|
cursor-color = #aa0000
|
||||||
|
@ -125,35 +102,58 @@ in
|
||||||
'';
|
'';
|
||||||
|
|
||||||
xdg.desktopEntries = {
|
xdg.desktopEntries = {
|
||||||
ghostty-local = {
|
ghostty-secondary = {
|
||||||
categories = [
|
categories = [
|
||||||
"System"
|
"System"
|
||||||
"TerminalEmulator"
|
"TerminalEmulator"
|
||||||
];
|
];
|
||||||
exec = ''launch-ghostty --class=com.mitchellh.ghostty-local -e "tmux new-session -A -s0 -nt1"'';
|
exec = ''
|
||||||
genericName = "Ghostty (local)";
|
ghostty --class=com.mitchellh.ghostty-secondary --font-style="ExtraCondensed" --font-style-bold="Bold ExtraCondensed" --font-style-italic="ExtraCondensed Oblique" -e bash
|
||||||
|
'';
|
||||||
|
genericName = "Ghostty Secondary";
|
||||||
icon = "com.mitchellh.ghostty";
|
icon = "com.mitchellh.ghostty";
|
||||||
name = "Ghostty (local)";
|
name = "Ghostty Secondary";
|
||||||
settings = {
|
settings = {
|
||||||
StartupWMClass = "com.mitchellh.ghostty-local";
|
StartupWMClass = "com.mitchellh.ghostty-secondary";
|
||||||
TryExec = "launch-ghostty";
|
TryExec = "ghostty";
|
||||||
};
|
};
|
||||||
terminal = false;
|
terminal = false;
|
||||||
type = "Application";
|
type = "Application";
|
||||||
};
|
};
|
||||||
|
|
||||||
ghostty-nemo = {
|
ghostty-devel = {
|
||||||
categories = [
|
categories = [
|
||||||
"System"
|
"System"
|
||||||
"TerminalEmulator"
|
"TerminalEmulator"
|
||||||
];
|
];
|
||||||
exec = ''launch-ghostty --class=com.mitchellh.ghostty-nemo -e "ssh -t nemo tmux new-session -A -s0 -nt1"'';
|
exec = ''
|
||||||
genericName = "Ghostty (nemo)";
|
ghostty --class=com.mitchellh.ghostty-devel --command="ssh -t devel" --initial-command="ssh -t devel"
|
||||||
|
'';
|
||||||
|
genericName = "Ghostty (devel)";
|
||||||
icon = "com.mitchellh.ghostty";
|
icon = "com.mitchellh.ghostty";
|
||||||
name = "Ghostty (nemo)";
|
name = "Ghostty (devel)";
|
||||||
settings = {
|
settings = {
|
||||||
StartupWMClass = "com.mitchellh.ghostty-nemo";
|
StartupWMClass = "com.mitchellh.ghostty-devel";
|
||||||
TryExec = "launch-ghostty";
|
TryExec = "ghostty";
|
||||||
|
};
|
||||||
|
terminal = false;
|
||||||
|
type = "Application";
|
||||||
|
};
|
||||||
|
|
||||||
|
ghostty-devel-secondary = {
|
||||||
|
categories = [
|
||||||
|
"System"
|
||||||
|
"TerminalEmulator"
|
||||||
|
];
|
||||||
|
exec = ''
|
||||||
|
ghostty --class=com.mitchellh.ghostty-devel-secondary --font-style="ExtraCondensed" --font-style-bold="Bold ExtraCondensed" --font-style-italic="ExtraCondensed Oblique" --command="ssh -t devel" --initial-command="ssh -t devel"
|
||||||
|
'';
|
||||||
|
genericName = "Ghostty Secondary (devel)";
|
||||||
|
icon = "com.mitchellh.ghostty";
|
||||||
|
name = "Ghostty Secondary (devel)";
|
||||||
|
settings = {
|
||||||
|
StartupWMClass = "com.mitchellh.ghostty-devel-secondary";
|
||||||
|
TryExec = "ghostty";
|
||||||
};
|
};
|
||||||
terminal = false;
|
terminal = false;
|
||||||
type = "Application";
|
type = "Application";
|
||||||
|
|
|
@ -13,7 +13,6 @@ with lib.hm.gvariant;
|
||||||
gnomeExtensions.desktop-clock
|
gnomeExtensions.desktop-clock
|
||||||
gnomeExtensions.emoji-copy
|
gnomeExtensions.emoji-copy
|
||||||
gnomeExtensions.just-perfection
|
gnomeExtensions.just-perfection
|
||||||
gnomeExtensions.vitals
|
|
||||||
];
|
];
|
||||||
|
|
||||||
dconf.settings = {
|
dconf.settings = {
|
||||||
|
@ -168,7 +167,6 @@ with lib.hm.gvariant;
|
||||||
enabled-extensions = [
|
enabled-extensions = [
|
||||||
"emoji-copy@felipeftn"
|
"emoji-copy@felipeftn"
|
||||||
"just-perfection-desktop@just-perfection"
|
"just-perfection-desktop@just-perfection"
|
||||||
"Vitals@CoreCoding.com"
|
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -187,10 +185,6 @@ with lib.hm.gvariant;
|
||||||
top-panel-position = 0;
|
top-panel-position = 0;
|
||||||
};
|
};
|
||||||
|
|
||||||
"org/gnome/shell/extensions/vitals" = {
|
|
||||||
update-time = 15;
|
|
||||||
};
|
|
||||||
|
|
||||||
"org/gnome/tweaks" = {
|
"org/gnome/tweaks" = {
|
||||||
show-extensions-notice = false;
|
show-extensions-notice = false;
|
||||||
};
|
};
|
||||||
|
|
69
home/common/nvim/blink-cmp.lua
Normal file
69
home/common/nvim/blink-cmp.lua
Normal file
|
@ -0,0 +1,69 @@
|
||||||
|
require 'blink-cmp'.setup({
|
||||||
|
keymap = {
|
||||||
|
preset = 'enter',
|
||||||
|
['<Tab>'] = { 'select_next', 'fallback' },
|
||||||
|
['<S-Tab>'] = { 'select_prev', 'fallback' },
|
||||||
|
['<PageDown>'] = { 'scroll_documentation_down', 'fallback' },
|
||||||
|
['<PageUp>'] = { 'scroll_documentation_up', 'fallback' },
|
||||||
|
},
|
||||||
|
completion = {
|
||||||
|
accept = {
|
||||||
|
auto_brackets = { enabled = true, },
|
||||||
|
},
|
||||||
|
|
||||||
|
documentation = {
|
||||||
|
auto_show = true,
|
||||||
|
auto_show_delay_ms = 800,
|
||||||
|
window = { border = 'rounded', },
|
||||||
|
},
|
||||||
|
|
||||||
|
ghost_text = { enabled = false },
|
||||||
|
|
||||||
|
list = {
|
||||||
|
selection = {
|
||||||
|
preselect = false,
|
||||||
|
auto_insert = false
|
||||||
|
},
|
||||||
|
},
|
||||||
|
|
||||||
|
menu = {
|
||||||
|
auto_show = true,
|
||||||
|
border = 'rounded',
|
||||||
|
direction_priority = { 'n' },
|
||||||
|
draw = {
|
||||||
|
components = {
|
||||||
|
kind_icon = {
|
||||||
|
ellipsis = false,
|
||||||
|
text = function(ctx)
|
||||||
|
local kind_icon, _, _ = require('mini.icons').get('lsp', ctx.kind)
|
||||||
|
return kind_icon
|
||||||
|
end,
|
||||||
|
-- Optionally, you may also use the highlights from mini.icons
|
||||||
|
highlight = function(ctx)
|
||||||
|
local _, hl, _ = require('mini.icons').get('lsp', ctx.kind)
|
||||||
|
return hl
|
||||||
|
end,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
fuzzy = {
|
||||||
|
prebuilt_binaries = {
|
||||||
|
download = false
|
||||||
|
},
|
||||||
|
},
|
||||||
|
|
||||||
|
signature = {
|
||||||
|
enabled = true,
|
||||||
|
window = { border = 'rounded', },
|
||||||
|
},
|
||||||
|
|
||||||
|
sources = {
|
||||||
|
default = { 'lsp' },
|
||||||
|
cmdline = {},
|
||||||
|
providers = {},
|
||||||
|
},
|
||||||
|
|
||||||
|
})
|
|
@ -4,11 +4,23 @@
|
||||||
pkgs,
|
pkgs,
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
|
let
|
||||||
|
nvim-remote = pkgs.writeShellApplication {
|
||||||
|
name = "nvim-remote";
|
||||||
|
text = ''
|
||||||
|
_sess=$(echo -n "$USER@''${SSH_CONNECTION:-$HOSTNAME}" | tr -c '[:alnum:]@.' '_')
|
||||||
|
_nvim_sock="''${XDG_RUNTIME_DIR:-/tmp}/nvim.$_sess.sock"
|
||||||
|
exec nvim --listen "$_nvim_sock" --server "$_nvim_sock" "$@"
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
in
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./treesitter.nix
|
./treesitter.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
|
home.packages = [ nvim-remote ];
|
||||||
|
|
||||||
programs.man.generateCaches = false;
|
programs.man.generateCaches = false;
|
||||||
|
|
||||||
programs.neovim = {
|
programs.neovim = {
|
||||||
|
@ -24,34 +36,38 @@
|
||||||
extraLuaConfig = lib.fileContents ./init.lua;
|
extraLuaConfig = lib.fileContents ./init.lua;
|
||||||
|
|
||||||
extraPackages = with pkgs; [
|
extraPackages = with pkgs; [
|
||||||
black
|
|
||||||
codeium
|
codeium
|
||||||
cue
|
harper
|
||||||
go
|
|
||||||
gopls
|
|
||||||
gotools
|
|
||||||
lua-language-server
|
lua-language-server
|
||||||
nil
|
|
||||||
nixd
|
nixd
|
||||||
nodePackages.prettier
|
|
||||||
nodePackages.typescript
|
|
||||||
nodePackages.typescript-language-server
|
|
||||||
nodePackages.bash-language-server
|
|
||||||
rust-analyzer
|
|
||||||
rustfmt
|
|
||||||
shellcheck
|
shellcheck
|
||||||
shfmt
|
shfmt
|
||||||
stylua
|
stylua
|
||||||
vscode-langservers-extracted
|
|
||||||
];
|
];
|
||||||
|
|
||||||
plugins = with pkgs.vimPlugins; [
|
plugins = with pkgs.vimPlugins; [
|
||||||
friendly-snippets
|
friendly-snippets
|
||||||
go-nvim
|
go-nvim
|
||||||
rustaceanvim
|
|
||||||
targets-vim
|
targets-vim
|
||||||
ts-comments-nvim
|
ts-comments-nvim
|
||||||
|
|
||||||
|
{
|
||||||
|
plugin = pkgs.vimUtils.buildVimPlugin {
|
||||||
|
name = "direnv-nvim";
|
||||||
|
src = pkgs.fetchFromGitHub {
|
||||||
|
owner = "actionshrimp";
|
||||||
|
repo = "direnv.nvim";
|
||||||
|
rev = "main";
|
||||||
|
hash = "sha256-7NcVskgAurbIuEVIXxHvXZfYQBOEXLURGzllfVEQKNE=";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
type = "lua";
|
||||||
|
config = ''
|
||||||
|
require('direnv-nvim').setup {
|
||||||
|
type = "dir"
|
||||||
|
}
|
||||||
|
'';
|
||||||
|
}
|
||||||
{
|
{
|
||||||
plugin = nvim-lspconfig;
|
plugin = nvim-lspconfig;
|
||||||
type = "lua";
|
type = "lua";
|
||||||
|
@ -59,47 +75,41 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
plugin = pkgs.nixpkgs-unstable.vimPlugins.blink-cmp;
|
plugin = blink-cmp;
|
||||||
|
type = "lua";
|
||||||
|
config = lib.fileContents ./blink-cmp.lua;
|
||||||
|
}
|
||||||
|
|
||||||
|
{
|
||||||
|
plugin = pkgs.vimUtils.buildVimPlugin {
|
||||||
|
name = "blink.compat";
|
||||||
|
src = pkgs.fetchFromGitHub {
|
||||||
|
owner = "saghen";
|
||||||
|
repo = "blink.compat";
|
||||||
|
rev = "5ca8848c8cc32abdc980e5db4f0eb7bb8fbf84dc"; # Dec 25, 2024
|
||||||
|
hash = "sha256-tFQeKyqdo3mvptYnWxKhTpI4ROFNQ6u3P8cLqtlsozw=";
|
||||||
|
};
|
||||||
|
};
|
||||||
type = "lua";
|
type = "lua";
|
||||||
config = ''
|
config = ''
|
||||||
require'blink-cmp'.setup({
|
require('blink.compat').setup()
|
||||||
keymap = {
|
|
||||||
preset = 'enter',
|
|
||||||
["<PageDown>"] = { "scroll_documentation_down" },
|
|
||||||
["<PageUp>"] = { "scroll_documentation_up" },
|
|
||||||
},
|
|
||||||
trigger = {
|
|
||||||
completion = {
|
|
||||||
show_in_snippet = true,
|
|
||||||
},
|
|
||||||
signature_help = {
|
|
||||||
enabled = true,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
windows = {
|
|
||||||
autocomplete = {
|
|
||||||
border = 'none',
|
|
||||||
selection = 'preselect',
|
|
||||||
},
|
|
||||||
documentation = {
|
|
||||||
border = 'rounded',
|
|
||||||
auto_show = false,
|
|
||||||
auto_show_delay_ms = 800,
|
|
||||||
},
|
|
||||||
signature_help = {
|
|
||||||
border = 'rounded',
|
|
||||||
},
|
|
||||||
},
|
|
||||||
})
|
|
||||||
'';
|
'';
|
||||||
}
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
plugin = codeium-nvim;
|
plugin = pkgs.vimUtils.buildVimPlugin {
|
||||||
|
name = "inlay-hints";
|
||||||
|
src = pkgs.fetchFromGitHub {
|
||||||
|
owner = "MysticalDevil";
|
||||||
|
repo = "inlay-hints.nvim";
|
||||||
|
rev = "3259b54f3b954b4d8260f3ee49ceabe978ea5636";
|
||||||
|
hash = "sha256-99KCGoPowa4PA1jkCm4ZbbgrFl84NWnKQMgkfy8KS5E=";
|
||||||
|
};
|
||||||
|
};
|
||||||
type = "lua";
|
type = "lua";
|
||||||
config = ''
|
config = ''
|
||||||
require'codeium'.setup {
|
require('inlay-hints').setup {
|
||||||
enable_chat = false,
|
autocmd = { enable = false },
|
||||||
}
|
}
|
||||||
'';
|
'';
|
||||||
}
|
}
|
||||||
|
@ -113,6 +123,7 @@
|
||||||
rev = "4da81528468b33585c411f31eb390dce573ccb14"; # v1.8.0
|
rev = "4da81528468b33585c411f31eb390dce573ccb14"; # v1.8.0
|
||||||
hash = "sha256-1n9nNqBNwNDSzbAkm8eB4HZLNy5HmMg25jPwQAnW5OU=";
|
hash = "sha256-1n9nNqBNwNDSzbAkm8eB4HZLNy5HmMg25jPwQAnW5OU=";
|
||||||
};
|
};
|
||||||
|
doCheck = false;
|
||||||
};
|
};
|
||||||
type = "lua";
|
type = "lua";
|
||||||
config = ''
|
config = ''
|
||||||
|
@ -154,7 +165,7 @@
|
||||||
};
|
};
|
||||||
type = "lua";
|
type = "lua";
|
||||||
config = ''
|
config = ''
|
||||||
vim.cmd.colorscheme "dieter"
|
vim.cmd.colorscheme "dieter-nocolor"
|
||||||
'';
|
'';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -163,6 +174,13 @@
|
||||||
type = "lua";
|
type = "lua";
|
||||||
config = lib.fileContents ./mini.lua;
|
config = lib.fileContents ./mini.lua;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
{
|
||||||
|
plugin = rustaceanvim;
|
||||||
|
type = "lua";
|
||||||
|
config = lib.fileContents ./rust.lua;
|
||||||
|
}
|
||||||
|
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
2
home/common/nvim/dieter/colors/dieter-nocolor.lua
Normal file
2
home/common/nvim/dieter/colors/dieter-nocolor.lua
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
package.loaded["dieter"] = nil
|
||||||
|
require("dieter").setup_nocolor()
|
|
@ -1,2 +1,2 @@
|
||||||
package.loaded["dieter"] = nil
|
package.loaded["dieter"] = nil
|
||||||
require("dieter")
|
require("dieter").setup()
|
||||||
|
|
|
@ -2,8 +2,8 @@ local hsl = require("dieter.hsl").hslToHex
|
||||||
|
|
||||||
local colors = {
|
local colors = {
|
||||||
light = {
|
light = {
|
||||||
background = hsl(240, 100, 100),
|
background = "NONE",
|
||||||
foreground = hsl(0, 0, 13),
|
foreground = "NONE",
|
||||||
|
|
||||||
accent1 = hsl(12, 100, 50),
|
accent1 = hsl(12, 100, 50),
|
||||||
|
|
||||||
|
@ -29,35 +29,41 @@ local colors = {
|
||||||
change = hsl(41, 80, 80),
|
change = hsl(41, 80, 80),
|
||||||
change_quarter = hsl(224, 100, 85),
|
change_quarter = hsl(224, 100, 85),
|
||||||
delete = hsl(350, 100, 40),
|
delete = hsl(350, 100, 40),
|
||||||
delete_quarter = hsl(350, 100, 85),
|
|
||||||
|
|
||||||
dialog_bg = hsl(224, 5, 92),
|
dialog_bg = hsl(224, 5, 92),
|
||||||
selection = hsl(270, 75, 92),
|
selection = hsl(270, 75, 92),
|
||||||
highlight_subtle = hsl(0, 0, 94),
|
highlight_subtle = hsl(0, 0, 94),
|
||||||
highlight_intense = hsl(42, 100, 30),
|
highlight_intense = hsl(42, 100, 30),
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
dark = {
|
dark = {
|
||||||
background = hsl(216, 28, 7),
|
background = "NONE",
|
||||||
foreground = hsl(0, 0, 80),
|
foreground = "NONE",
|
||||||
|
|
||||||
accent1 = hsl(12, 100, 50),
|
accent1 = hsl(202, 57, 57), -- Blue
|
||||||
|
accent2 = hsl(40, 57, 57), -- Yellow
|
||||||
|
|
||||||
dimmed = hsl(0, 0, 25),
|
dimmed = hsl(212, 19, 25),
|
||||||
dimmed_subtle = hsl(0, 0, 50),
|
dimmed_subtle = hsl(212, 19, 50),
|
||||||
|
|
||||||
highlight_subtle = hsl(0, 0, 6),
|
highlight_subtle = hsl(212, 27, 11),
|
||||||
|
highlight = hsl(212, 27, 18),
|
||||||
highlight_intense = hsl(58, 100, 60),
|
highlight_intense = hsl(58, 100, 60),
|
||||||
|
|
||||||
string = hsl(96, 50, 70),
|
dialog_fg = hsl(191, 15, 75),
|
||||||
comment = hsl(220, 50, 60),
|
|
||||||
|
string = hsl(90, 30, 60),
|
||||||
|
-- comment = hsl(2, 69, 68),
|
||||||
|
comment = hsl(216, 30, 55),
|
||||||
comment_error = hsl(2, 85, 50),
|
comment_error = hsl(2, 85, 50),
|
||||||
|
func = hsl(40, 57, 87),
|
||||||
|
member = hsl(213, 45, 75),
|
||||||
|
punc = hsl(213, 45, 50),
|
||||||
|
|
||||||
diagnostic_error = hsl(353, 100, 45),
|
diagnostic_error = hsl(353, 100, 45),
|
||||||
diagnostic_warning = hsl(30, 100, 50),
|
diagnostic_warning = hsl(30, 100, 50),
|
||||||
diagnostic_info = hsl(176, 80, 60),
|
diagnostic_info = hsl(176, 80, 60),
|
||||||
diagnostic_hint = hsl(176, 80, 60),
|
diagnostic_hint = hsl(210, 74, 60),
|
||||||
|
|
||||||
popup_error_bg = hsl(0, 95, 7),
|
popup_error_bg = hsl(0, 95, 7),
|
||||||
popup_warning_bg = hsl(27, 95, 7),
|
popup_warning_bg = hsl(27, 95, 7),
|
||||||
|
@ -71,14 +77,13 @@ local colors = {
|
||||||
delete = hsl(350, 100, 40),
|
delete = hsl(350, 100, 40),
|
||||||
delete_quarter = hsl(350, 100, 15),
|
delete_quarter = hsl(350, 100, 15),
|
||||||
|
|
||||||
-- dialog_bg = background,
|
selection = hsl(218, 90, 20),
|
||||||
-- dialog_fg = hsl(216, 70, 80),
|
|
||||||
-- dialog_bg = hsl(216, 25, 20),
|
search_bg = hsl(43, 100, 8),
|
||||||
-- selection = hsl(216, 25, 33),
|
search_fg = hsl(43, 100, 85),
|
||||||
selection = hsl(213, 60, 40),
|
|
||||||
|
|
||||||
cmp_bg = hsl(218, 30, 13),
|
cmp_bg = hsl(218, 30, 13),
|
||||||
cmp_fg = hsl(218, 30, 60),
|
cmp_fg = hsl(218, 30, 80),
|
||||||
cmp_selected_bg = hsl(218, 30, 25),
|
cmp_selected_bg = hsl(218, 30, 25),
|
||||||
cmp_selected_fg = hsl(218, 50, 80),
|
cmp_selected_fg = hsl(218, 50, 80),
|
||||||
|
|
||||||
|
@ -90,23 +95,30 @@ local colors = {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
local c = colors[vim.o.background]
|
local setupGroups = function(c)
|
||||||
c.dialog_fg = c.foreground
|
|
||||||
c.dialog_bg = c.background
|
c.dialog_bg = c.background
|
||||||
|
|
||||||
local theme = {
|
return {
|
||||||
Normal = { fg = c.foreground, bg = c.background },
|
Normal = { fg = c.foreground, bg = c.background },
|
||||||
|
|
||||||
Constant = { link = "NormalNC" },
|
Constant = { link = "NormalNC" },
|
||||||
Delimiter = { link = "NormalNC" },
|
Delimiter = { link = "NormalNC" },
|
||||||
|
Function = { fg = c.func },
|
||||||
Identifier = { link = "NormalNC" },
|
Identifier = { link = "NormalNC" },
|
||||||
Keyword = { fg = c.foreground, bold = true },
|
Keyword = { fg = c.foreground, bold = true },
|
||||||
Operator = { link = "NormalNC" },
|
Operator = { link = "NormalNC" },
|
||||||
Special = { link = "NormalNC" },
|
Special = { link = "NormalNC" },
|
||||||
Type = { link = "NormalNC" },
|
Type = { link = "NormalNC" },
|
||||||
|
|
||||||
|
MsgArea = { fg = c.dimmed_subtle },
|
||||||
|
|
||||||
String = { fg = c.string },
|
String = { fg = c.string },
|
||||||
|
|
||||||
|
Visual = { bg = c.selection },
|
||||||
|
|
||||||
|
Search = { bg = c.search_bg, fg = c.search_fg },
|
||||||
|
CurSearch = { link = "Search" },
|
||||||
|
|
||||||
Comment = { fg = c.comment, italic = true, bold = true },
|
Comment = { fg = c.comment, italic = true, bold = true },
|
||||||
CommentError = { fg = c.comment_error, italic = true, bold = true },
|
CommentError = { fg = c.comment_error, italic = true, bold = true },
|
||||||
["@comment.note"] = { link = "Comment" },
|
["@comment.note"] = { link = "Comment" },
|
||||||
|
@ -125,10 +137,11 @@ local theme = {
|
||||||
GitSignsDeleteNr = { link = "DiffDelete" },
|
GitSignsDeleteNr = { link = "DiffDelete" },
|
||||||
|
|
||||||
-- Treesitter
|
-- Treesitter
|
||||||
["@function"] = { link = "NormalNC" },
|
["@punctuation.special"] = { fg = c.punc },
|
||||||
["@special"] = { link = "NormalNC" },
|
["@special"] = { link = "NormalNC" },
|
||||||
["@variable"] = { link = "NormalNC" },
|
["@variable"] = { link = "NormalNC" },
|
||||||
["@lsp.type.variable"] = { fg = c.dimmed_subtle },
|
["@variable.member"] = { fg = c.member },
|
||||||
|
["@variable.parameter"] = { fg = c.accent2 },
|
||||||
|
|
||||||
-- UI Elements
|
-- UI Elements
|
||||||
CursorLine = { bg = c.highlight_subtle },
|
CursorLine = { bg = c.highlight_subtle },
|
||||||
|
@ -138,42 +151,49 @@ local theme = {
|
||||||
DiagnosticFloatingWarn = { fg = c.diagnostic_warning, bg = c.popup_warning_bg },
|
DiagnosticFloatingWarn = { fg = c.diagnostic_warning, bg = c.popup_warning_bg },
|
||||||
DiagnosticFloatingInfo = { fg = c.diagnostic_info, bg = c.popup_info_bg },
|
DiagnosticFloatingInfo = { fg = c.diagnostic_info, bg = c.popup_info_bg },
|
||||||
DiagnosticFloatingHint = { fg = c.diagnostic_hint, bg = c.popup_hint_bg },
|
DiagnosticFloatingHint = { fg = c.diagnostic_hint, bg = c.popup_hint_bg },
|
||||||
DiagnosticUnderlineError = { fg = c.diagnostic_error, undercurl = true },
|
DiagnosticUnderlineError = { fg = c.foreground, undercurl = true, sp = c.diagnostic_error },
|
||||||
DiagnosticUnderlineWarn = { fg = c.diagnostic_warn, undercurl = true },
|
DiagnosticUnderlineWarn = { fg = c.foreground, undercurl = true, sp = c.diagnostic_warn },
|
||||||
DiagnosticUnderlineInfo = { fg = c.diagnostic_info, undercurl = true },
|
DiagnosticUnderlineInfo = { fg = c.foreground, undercurl = true, sp = c.diagnostic_info },
|
||||||
DiagnosticUnderlinehint = { fg = c.diagnostic_hint, undercurl = true },
|
DiagnosticUnderlinehint = { fg = c.foreground, undercurl = true, sp = c.diagnostic_hint },
|
||||||
|
|
||||||
DiagnosticSignError = { fg = c.diagnostic_error },
|
DiagnosticSignError = { fg = c.diagnostic_error },
|
||||||
DiagnosticSignHint = { fg = c.diagnostic_hint },
|
DiagnosticSignHint = { fg = c.diagnostic_hint },
|
||||||
DiagnosticSignInfo = { fg = c.diagnostic_info },
|
DiagnosticSignInfo = { fg = c.diagnostic_info },
|
||||||
DiagnosticSignWarn = { fg = c.diagnostic_warning },
|
DiagnosticSignWarn = { fg = c.diagnostic_warning },
|
||||||
LineNr = { fg = c.dimmed, italic = true },
|
LineNr = { fg = c.dimmed },
|
||||||
IndentLine = { fg = c.background },
|
CursorLineNr = { fg = c.dimmed_subtle, bg = c.highlight_subtle },
|
||||||
IndentLineCurrent = { fg = c.dimmed },
|
|
||||||
|
IndentLine = { fg = c.highlight },
|
||||||
|
IndentLineCurrent = { fg = c.highlight },
|
||||||
|
MiniIndentscopeSymbol = { link = "IndentLine" },
|
||||||
|
MiniIndentscopeSymbolOff = { link = "IndentLine" },
|
||||||
|
|
||||||
TreesitterContext = { reverse = true },
|
TreesitterContext = { reverse = true },
|
||||||
TreesitterContextLineNumber = { bg = c.dimmed, reverse = true, italic = true },
|
TreesitterContextLineNumber = { bg = c.dimmed, reverse = true, italic = true },
|
||||||
InclineNormal = { bg = c.background },
|
InclineNormal = { bg = c.background },
|
||||||
InclineNormalNC = { bg = c.background },
|
InclineNormalNC = { bg = c.background },
|
||||||
|
|
||||||
WinSeparator = { bg = c.dialog_bg, fg = c.dialog_fg },
|
WinSeparator = { bg = c.dialog_bg, fg = c.dialog_fg },
|
||||||
NormalFloat = { bg = c.doc_bg, fg = c.doc_fg },
|
NormalFloat = { bg = c.background, fg = c.foreground },
|
||||||
FloatBorder = { fg = c.doc_fg },
|
FloatBorder = { fg = c.foreground },
|
||||||
FloatTitle = { fg = c.doc_fg, bold = true },
|
FloatTitle = { fg = c.doc_fg, bold = true },
|
||||||
|
|
||||||
Title = { fg = c.foreground, bold = true },
|
Title = { fg = c.foreground, bold = true },
|
||||||
|
|
||||||
MiniPickNormal = { link = "Normal" },
|
MiniPickNormal = { bg = c.dialog_bg, fg = c.dialog_fg },
|
||||||
MiniPickBorder = { link = "MiniPickNormal" },
|
MiniPickBorder = { link = "MiniPickNormal" },
|
||||||
MiniPickBorderText = { link = "MiniPickBorder" },
|
MiniPickBorderText = { link = "MiniPickBorder" },
|
||||||
MiniPickMatchCurrent = { bg = c.background, fg = c.foreground, reverse = true },
|
MiniPickMatchCurrent = { bg = c.dialog_bg, fg = c.dialog_fg, reverse = true },
|
||||||
|
|
||||||
MiniClueBorder = { link = "MiniPickNormal" },
|
MiniClueBorder = { link = "MiniPicBorder" },
|
||||||
MiniClueTitle = { bg = c.background, fg = c.foreground, bold = true },
|
MiniClueTitle = { bg = c.background, fg = c.foreground, bold = true },
|
||||||
MiniClueNextKey = { link = "MiniClueTitle" },
|
MiniClueNextKey = { link = "MiniClueTitle" },
|
||||||
MiniClueDescGroup = { bg = c.background, fg = c.foreground, italic = true },
|
MiniClueDescGroup = { bg = c.background, fg = c.foreground, italic = true },
|
||||||
MiniClueDescSingle = { bg = c.background, fg = c.foreground },
|
MiniClueDescSingle = { bg = c.background, fg = c.foreground },
|
||||||
MiniClueSeparator = { link = "MiniClueBorder" },
|
MiniClueSeparator = { link = "MiniClueBorder" },
|
||||||
|
|
||||||
|
MiniCursorWord = { underdotted = true, bold = true, sp = c.diagnostic_hint },
|
||||||
|
|
||||||
MiniStarterCurrent = { link = "MiniPickMatchCurrent" },
|
MiniStarterCurrent = { link = "MiniPickMatchCurrent" },
|
||||||
|
|
||||||
BlinkCmpMenu = { bg = c.cmp_bg, fg = c.cmp_fg },
|
BlinkCmpMenu = { bg = c.cmp_bg, fg = c.cmp_fg },
|
||||||
|
@ -189,27 +209,61 @@ local theme = {
|
||||||
BlinkCmpSignatureHelpBorder = { link = 'BlinkCmpDocBorder' },
|
BlinkCmpSignatureHelpBorder = { link = 'BlinkCmpDocBorder' },
|
||||||
|
|
||||||
NeoCodeiumSuggestion = { fg = c.suggestion, bold = true, italic = true },
|
NeoCodeiumSuggestion = { fg = c.suggestion, bold = true, italic = true },
|
||||||
|
|
||||||
NoiceMini = { fg = c.foreground, italic = true },
|
|
||||||
|
|
||||||
TelescopeNormal = { fg = c.foreground, bg = c.background },
|
|
||||||
TelescopeBorder = { bold = true },
|
|
||||||
TelescopeSelection = { bg = c.selection },
|
|
||||||
TelescopeResultsNormal = { fg = c.foreground, bold = true },
|
|
||||||
TelescopeResultsComment = { fg = c.dimmed_subtle, italic = true, bold = false },
|
|
||||||
|
|
||||||
Visual = { bg = c.selection },
|
|
||||||
LspReferenceText = { fg = c.highlight_intense, undercurl = true },
|
LspReferenceText = { fg = c.highlight_intense, undercurl = true },
|
||||||
|
LspInlayHint = { fg = c.accent1, italic = true, bold = true },
|
||||||
}
|
}
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
local setupGroupsNoColor = function(c)
|
||||||
|
local g = setupGroups(c)
|
||||||
|
local cl = { link = "NormalNC" }
|
||||||
|
g.Constant = cl
|
||||||
|
g.Delimiter = cl
|
||||||
|
g.Function = cl
|
||||||
|
g.Identifier = cl
|
||||||
|
g.Keyword = cl
|
||||||
|
g.Operator = cl
|
||||||
|
g["@punctuation.special"] = cl
|
||||||
|
g["@special"] = cl
|
||||||
|
g["@string"] = cl
|
||||||
|
g["@lsp.type.string"] = cl
|
||||||
|
g.Special = cl
|
||||||
|
g.String = cl
|
||||||
|
g.Type = cl
|
||||||
|
g.Variable = cl
|
||||||
|
g["@variable"] = cl
|
||||||
|
g["@variable.member"] = cl
|
||||||
|
g["@variable.parameter"] = cl
|
||||||
|
-- g.Comment = { fg = c.dimmed_subtle, italic = true, bold = true }
|
||||||
|
g.CommentError = { link = "Comment" }
|
||||||
|
return g
|
||||||
|
end
|
||||||
|
|
||||||
|
local setup_common = function(groups)
|
||||||
vim.cmd("hi clear")
|
vim.cmd("hi clear")
|
||||||
|
|
||||||
if vim.fn.exists("syntax_on") == 1 then
|
if vim.fn.exists("syntax_on") == 1 then
|
||||||
vim.cmd("syntax reset")
|
vim.cmd("syntax reset")
|
||||||
end
|
end
|
||||||
|
for group, hl in pairs(groups) do
|
||||||
for group, hl in pairs(theme) do
|
|
||||||
vim.api.nvim_set_hl(0, group, hl)
|
vim.api.nvim_set_hl(0, group, hl)
|
||||||
end
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
local T = {}
|
||||||
|
|
||||||
|
T.setup = function()
|
||||||
|
local c = colors[vim.o.background]
|
||||||
|
local groups = setupGroups(c)
|
||||||
|
setup_common(groups)
|
||||||
vim.g.colors_name = "dieter"
|
vim.g.colors_name = "dieter"
|
||||||
|
end
|
||||||
|
|
||||||
|
T.setup_nocolor = function()
|
||||||
|
local c = colors[vim.o.background]
|
||||||
|
local groups = setupGroupsNoColor(c)
|
||||||
|
setup_common(groups)
|
||||||
|
vim.g.colors_name = "dieter-nocolor"
|
||||||
|
end
|
||||||
|
|
||||||
|
return T
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
vim.env.RIPGREP_CONFIG_PATH = vim.env.HOME .. "/.config/ripgrep/ripgreprc"
|
||||||
|
|
||||||
vim.g.mapleader = ' '
|
vim.g.mapleader = ' '
|
||||||
vim.g.maplocalleader = ","
|
vim.g.maplocalleader = ","
|
||||||
|
|
||||||
|
@ -5,8 +7,8 @@ vim.g.maplocalleader = ","
|
||||||
|
|
||||||
vim.opt.cursorline = true
|
vim.opt.cursorline = true
|
||||||
vim.opt.laststatus = 0
|
vim.opt.laststatus = 0
|
||||||
vim.opt.number = true
|
vim.opt.number = false
|
||||||
vim.opt.relativenumber = true
|
vim.opt.relativenumber = false
|
||||||
vim.opt.ruler = true
|
vim.opt.ruler = true
|
||||||
vim.opt.syntax = "on"
|
vim.opt.syntax = "on"
|
||||||
vim.opt.termguicolors = true
|
vim.opt.termguicolors = true
|
||||||
|
@ -22,7 +24,25 @@ function GetIndicators()
|
||||||
return warn_string .. error_string
|
return warn_string .. error_string
|
||||||
end
|
end
|
||||||
|
|
||||||
vim.opt.rulerformat = "%40(%=%{%v:lua.GetIndicators()%}%#Label#│ %t %)"
|
function CondensedPath()
|
||||||
|
local path = vim.fn.expand("%:p")
|
||||||
|
local home = os.getenv("HOME")
|
||||||
|
if home then
|
||||||
|
path = vim.fn.substitute(path, '^' .. home, '~', '')
|
||||||
|
end
|
||||||
|
|
||||||
|
local segments = vim.fn.split(path, '/')
|
||||||
|
if #segments <= 3 then
|
||||||
|
return path
|
||||||
|
end
|
||||||
|
|
||||||
|
local early_path = table.concat(vim.list_slice(segments, 1, #segments - 2), '/')
|
||||||
|
local late_path = table.concat(vim.list_slice(segments, #segments - 1), '/')
|
||||||
|
|
||||||
|
return vim.fn.pathshorten(early_path) .. '/' .. late_path
|
||||||
|
end
|
||||||
|
|
||||||
|
vim.opt.rulerformat = "%50(%=%{%v:lua.GetIndicators()%}%#MsgArea#%{%v:lua.CondensedPath()%}%)%7(%l:%c%)"
|
||||||
|
|
||||||
-- Search
|
-- Search
|
||||||
vim.opt.ignorecase = true
|
vim.opt.ignorecase = true
|
||||||
|
@ -63,10 +83,8 @@ vim.o.showcmd = false
|
||||||
vim.o.showmode = false
|
vim.o.showmode = false
|
||||||
vim.o.smoothscroll = true
|
vim.o.smoothscroll = true
|
||||||
vim.o.splitkeep = "screen"
|
vim.o.splitkeep = "screen"
|
||||||
vim.o.timeoutlen = 10
|
vim.o.timeout = false
|
||||||
vim.o.timeout = true
|
vim.o.updatetime = 250
|
||||||
vim.o.updatetime = 50
|
|
||||||
|
|
||||||
|
|
||||||
-- Use rg
|
-- Use rg
|
||||||
vim.o.grepprg = [[rg --glob "!.jj" --glob "!.git" --no-heading --vimgrep --follow $*]]
|
vim.o.grepprg = [[rg --glob "!.jj" --glob "!.git" --no-heading --vimgrep --follow $*]]
|
||||||
|
@ -100,6 +118,29 @@ vim.keymap.set({ "i", "s" }, "<Tab>", function()
|
||||||
end, { expr = true })
|
end, { expr = true })
|
||||||
|
|
||||||
|
|
||||||
|
-- Autoformat
|
||||||
|
|
||||||
|
vim.g.autoformat_enabled = true -- set to true by default
|
||||||
|
|
||||||
|
vim.api.nvim_create_user_command('ToggleAutoFormat', function()
|
||||||
|
vim.g.autoformat_enabled = not vim.g.autoformat_enabled
|
||||||
|
print('Autoformatting ' .. (vim.g.autoformat_enabled and 'enabled' or 'disabled'))
|
||||||
|
end, {})
|
||||||
|
|
||||||
|
vim.api.nvim_create_augroup("AutoFormat", {})
|
||||||
|
|
||||||
|
vim.api.nvim_create_autocmd("BufWritePre", {
|
||||||
|
group = "AutoFormat",
|
||||||
|
callback = function()
|
||||||
|
if vim.g.autoformat_enabled then
|
||||||
|
vim.lsp.buf.format({
|
||||||
|
async = false,
|
||||||
|
timeout_ms = 2000 -- Adjust timeout as needed
|
||||||
|
})
|
||||||
|
end
|
||||||
|
end,
|
||||||
|
})
|
||||||
|
|
||||||
-- Keymap
|
-- Keymap
|
||||||
local opts = function(label)
|
local opts = function(label)
|
||||||
return { noremap = true, silent = true, desc = label }
|
return { noremap = true, silent = true, desc = label }
|
||||||
|
@ -115,6 +156,7 @@ vim.keymap.set({ "n", "v" }, "<Leader>a", vim.lsp.buf.code_action, { remap = tru
|
||||||
vim.keymap.set("n", "<Leader>af", function()
|
vim.keymap.set("n", "<Leader>af", function()
|
||||||
vim.lsp.buf.format({ async = true })
|
vim.lsp.buf.format({ async = true })
|
||||||
end, opts("Format Buffer"))
|
end, opts("Format Buffer"))
|
||||||
|
vim.keymap.set('n', '<Leader><Leader>', "<cmd>Pick visit_paths cwd=''<cr>", opts("Visits"))
|
||||||
vim.keymap.set('n', '<Leader>b', "<cmd>Pick buffers<cr>", opts("Open buffer picker"))
|
vim.keymap.set('n', '<Leader>b', "<cmd>Pick buffers<cr>", opts("Open buffer picker"))
|
||||||
vim.keymap.set('n', '<Leader>/', "<cmd>Pick grep_live_root<cr>", opts("Search workspace files"))
|
vim.keymap.set('n', '<Leader>/', "<cmd>Pick grep_live_root<cr>", opts("Search workspace files"))
|
||||||
vim.keymap.set('n', '<Leader>d', "<cmd>Pick diagnostic<cr>", opts("Open diagnostics picker"))
|
vim.keymap.set('n', '<Leader>d', "<cmd>Pick diagnostic<cr>", opts("Open diagnostics picker"))
|
||||||
|
@ -122,13 +164,16 @@ vim.keymap.set("n", "<Leader>D", vim.diagnostic.setloclist, { desc = "Diagnostic
|
||||||
vim.keymap.set("n", "<Leader>r", vim.lsp.buf.rename, opts("Rename Symbol"))
|
vim.keymap.set("n", "<Leader>r", vim.lsp.buf.rename, opts("Rename Symbol"))
|
||||||
vim.keymap.set('n', '<Leader>F', "<cmd>Pick files<cr>", opts("Open file picker CWD"))
|
vim.keymap.set('n', '<Leader>F', "<cmd>Pick files<cr>", opts("Open file picker CWD"))
|
||||||
vim.keymap.set('n', '<Leader>f', "<cmd>Pick files_root<cr>", opts("Open file picker"))
|
vim.keymap.set('n', '<Leader>f', "<cmd>Pick files_root<cr>", opts("Open file picker"))
|
||||||
|
vim.keymap.set('n', '<c-p>', "<Leader>f", { remap = true })
|
||||||
vim.keymap.set('n', '<Leader>g', "<cmd>Pick oldfiles<cr>", opts("Open file picker history"))
|
vim.keymap.set('n', '<Leader>g', "<cmd>Pick oldfiles<cr>", opts("Open file picker history"))
|
||||||
vim.keymap.set("n", '<Leader>k', vim.lsp.buf.hover, opts("Show docs for item under cursor"))
|
vim.keymap.set("n", '<Leader>k', vim.lsp.buf.hover, opts("Show docs for item under cursor"))
|
||||||
|
vim.keymap.set('n', '<Leader>p', "<cmd>Pick projects<cr>", opts("Open projects picker"))
|
||||||
vim.keymap.set('n', '<Leader>q', require('mini.bufremove').delete, opts("Delete buffer"))
|
vim.keymap.set('n', '<Leader>q', require('mini.bufremove').delete, opts("Delete buffer"))
|
||||||
vim.keymap.set('n', '<Leader>s', "<cmd>Pick lsp scope='document_symbol'<cr>", opts("Open symbol picker"))
|
vim.keymap.set('n', '<Leader>s', "<cmd>Pick lsp scope='document_symbol'<cr>", opts("Open symbol picker"))
|
||||||
vim.keymap.set('n', '<Leader>S', "<cmd>Pick lsp scope='workspace_symbol'<cr>", opts("Open workspace symbol picker"))
|
vim.keymap.set('n', '<Leader>S', "<cmd>Pick lsp scope='workspace_symbol'<cr>", opts("Open workspace symbol picker"))
|
||||||
vim.keymap.set("n", "<Leader>ws", "<C-w>s", opts("Horizontal split"))
|
vim.keymap.set("n", "<Leader>ws", "<C-w>s", opts("Horizontal split"))
|
||||||
vim.keymap.set("n", "<Leader>wv", "<C-w>v", opts("Vertical split"))
|
vim.keymap.set("n", "<Leader>wv", "<C-w>v", opts("Vertical split"))
|
||||||
|
vim.keymap.set("n", "<m-f>", require('mini.files').open, opts("Open file manager"))
|
||||||
vim.keymap.set('n', '<tab>', "<cmd>Pick buffers include_current=false<cr>", opts("Buffers"))
|
vim.keymap.set('n', '<tab>', "<cmd>Pick buffers include_current=false<cr>", opts("Buffers"))
|
||||||
vim.keymap.set("n", "zz", "zt", { remap = true })
|
vim.keymap.set("n", "zz", "zt", { remap = true })
|
||||||
vim.keymap.set({ "n", "v" }, "<Leader>y", '"+y', opts("Yank to clipboard"))
|
vim.keymap.set({ "n", "v" }, "<Leader>y", '"+y', opts("Yank to clipboard"))
|
||||||
|
@ -147,5 +192,17 @@ vim.keymap.set("n", "K", function()
|
||||||
offset_x = 2,
|
offset_x = 2,
|
||||||
}
|
}
|
||||||
end, {})
|
end, {})
|
||||||
|
vim.keymap.set("n", "<Leader>ub", function()
|
||||||
|
vim.o.background = (vim.o.background == "light" and "dark" or "light")
|
||||||
|
end, opts("Toggle dark/light background"))
|
||||||
|
vim.keymap.set("n", "<Leader>uc", function()
|
||||||
|
if vim.g.colors_name == "dieter-nocolor" then
|
||||||
|
vim.cmd [[colorscheme dieter]]
|
||||||
|
else
|
||||||
|
vim.cmd [[colorscheme dieter-nocolor]]
|
||||||
|
end
|
||||||
|
end, opts("Toggle Dieter colors"))
|
||||||
|
vim.keymap.set("n", "<Leader>uf", "<cmd>ToggleAutoFormat<cr>", opts("Toggle autoformat on save"))
|
||||||
|
vim.keymap.set("n", "<Leader>uh", "<cmd>InlayHintsToggle<cr>", opts("Toggle inlay hints"))
|
||||||
|
vim.keymap.set("n", "<Leader>un", "<cmd>set invnumber<cr>", opts("Toggle line numbers"))
|
||||||
|
vim.keymap.set("n", "<Leader>uw", "<cmd>set invwrap<cr>", opts("Toggle line wrapping"))
|
||||||
|
|
|
@ -1,31 +1,36 @@
|
||||||
local configs = require('lspconfig.configs')
|
|
||||||
local lspconfig = require("lspconfig")
|
local lspconfig = require("lspconfig")
|
||||||
local capabilities = vim.lsp.protocol.make_client_capabilities()
|
|
||||||
local servers = {
|
local servers = {
|
||||||
'gopls',
|
cssls = {},
|
||||||
'ts_ls',
|
html = {},
|
||||||
}
|
jsonls = {},
|
||||||
|
sqls = {},
|
||||||
|
superhtml = {},
|
||||||
|
ts_ls = {},
|
||||||
|
|
||||||
for _, ls in ipairs(servers) do
|
gopls = {
|
||||||
lspconfig[ls].setup {
|
|
||||||
capabilities = capabilities,
|
|
||||||
}
|
|
||||||
end
|
|
||||||
|
|
||||||
lspconfig.nixd.setup({
|
|
||||||
capabilities = capabilities,
|
|
||||||
cmd = { "nixd" },
|
|
||||||
settings = {
|
settings = {
|
||||||
nixd = {
|
gopls = {
|
||||||
nixpkgs = { expr = "import <nixpkgs> { }" },
|
hints = {
|
||||||
formatting = { command = { "nixfmt" } },
|
rangeVariableTypes = true,
|
||||||
options = {},
|
parameterNames = true,
|
||||||
|
constantValues = true,
|
||||||
|
assignVariableTypes = true,
|
||||||
|
compositeLiteralFields = true,
|
||||||
|
compositeLiteralTypes = true,
|
||||||
|
functionTypeParameters = true,
|
||||||
|
},
|
||||||
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
})
|
|
||||||
|
|
||||||
lspconfig.lua_ls.setup({
|
harper_ls = {
|
||||||
capabilities = capabilities,
|
filetypes = {
|
||||||
|
"asciidoc", "c", "gitcommit", "go", "html", "javascript", "just", "lua", "markdown",
|
||||||
|
"nix", "python", "ruby", "rust", "text", "toml", "typescript", "zig",
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
lua_ls = {
|
||||||
settings = {
|
settings = {
|
||||||
Lua = {
|
Lua = {
|
||||||
runtime = {
|
runtime = {
|
||||||
|
@ -33,6 +38,7 @@ lspconfig.lua_ls.setup({
|
||||||
path = vim.split(package.path, ";"),
|
path = vim.split(package.path, ";"),
|
||||||
},
|
},
|
||||||
diagnostics = { globals = { "vim", "hs" } },
|
diagnostics = { globals = { "vim", "hs" } },
|
||||||
|
hint = { enable = true },
|
||||||
workspace = {
|
workspace = {
|
||||||
library = {
|
library = {
|
||||||
[vim.fn.expand("$VIMRUNTIME/lua")] = true,
|
[vim.fn.expand("$VIMRUNTIME/lua")] = true,
|
||||||
|
@ -41,4 +47,21 @@ lspconfig.lua_ls.setup({
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
})
|
},
|
||||||
|
|
||||||
|
nixd = {
|
||||||
|
cmd = { "nixd" },
|
||||||
|
settings = {
|
||||||
|
nixd = {
|
||||||
|
nixpkgs = { expr = "import <nixpkgs> { }" },
|
||||||
|
formatting = { command = { "nixfmt" } },
|
||||||
|
options = {},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
for server, config in pairs(servers) do
|
||||||
|
config.capabilities = require('blink.cmp').get_lsp_capabilities(config.capabilities)
|
||||||
|
lspconfig[server].setup(config)
|
||||||
|
end
|
||||||
|
|
|
@ -5,11 +5,13 @@ require('mini.bufremove').setup()
|
||||||
require('mini.comment').setup()
|
require('mini.comment').setup()
|
||||||
require('mini.diff').setup()
|
require('mini.diff').setup()
|
||||||
require('mini.extra').setup()
|
require('mini.extra').setup()
|
||||||
|
require('mini.files').setup()
|
||||||
require('mini.icons').setup()
|
require('mini.icons').setup()
|
||||||
require('mini.jump').setup()
|
require('mini.jump').setup()
|
||||||
require('mini.surround').setup()
|
require('mini.surround').setup()
|
||||||
require('mini.splitjoin').setup()
|
require('mini.splitjoin').setup()
|
||||||
require('mini.trailspace').setup()
|
require('mini.trailspace').setup()
|
||||||
|
require('mini.visits').setup()
|
||||||
|
|
||||||
require('mini.cursorword').setup({
|
require('mini.cursorword').setup({
|
||||||
delay = 800
|
delay = 800
|
||||||
|
@ -49,13 +51,14 @@ local picker_win_config = function()
|
||||||
height = height,
|
height = height,
|
||||||
width = width,
|
width = width,
|
||||||
row = 2,
|
row = 2,
|
||||||
col = math.floor((vim.o.columns - width) / 2),
|
col = 5,
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
require('mini.pick').setup({
|
require('mini.pick').setup({
|
||||||
mappings = {
|
mappings = {
|
||||||
move_down = '<tab>',
|
move_down = '<tab>',
|
||||||
|
move_up = '<S-tab>',
|
||||||
toggle_info = '<C-k>',
|
toggle_info = '<C-k>',
|
||||||
toggle_preview = '<C-p>',
|
toggle_preview = '<C-p>',
|
||||||
},
|
},
|
||||||
|
@ -64,13 +67,54 @@ require('mini.pick').setup({
|
||||||
config = picker_win_config,
|
config = picker_win_config,
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
|
||||||
|
local MiniPick = require('mini.pick')
|
||||||
|
MiniPick.registry.projects = function(local_opts)
|
||||||
|
local root = vim.fn.expand("~/src")
|
||||||
|
|
||||||
|
local command = {
|
||||||
|
"fd",
|
||||||
|
"--max-depth=8",
|
||||||
|
"--one-file-system",
|
||||||
|
"--unrestricted",
|
||||||
|
"--full-path",
|
||||||
|
"/.jj/repo/store/type$|/.git/HEAD$",
|
||||||
|
root,
|
||||||
|
}
|
||||||
|
|
||||||
|
local postprocess = function(paths)
|
||||||
|
local result = {}
|
||||||
|
for _, path in ipairs(paths) do
|
||||||
|
path = path:gsub("%/.jj/repo/store/type$", "")
|
||||||
|
path = path:gsub("%/.git/HEAD$", "")
|
||||||
|
local item = {
|
||||||
|
path = path,
|
||||||
|
text = path:gsub("%" .. root .. "/", " "),
|
||||||
|
}
|
||||||
|
table.insert(result, item)
|
||||||
|
end
|
||||||
|
return result
|
||||||
|
end
|
||||||
|
|
||||||
|
local choose = function(item)
|
||||||
|
local_opts.cwd = item.path
|
||||||
|
vim.fn.chdir(item.path)
|
||||||
|
vim.schedule(function()
|
||||||
|
MiniPick.builtin.files(local_opts, { source = { cwd = item.path, tool = "rg" } })
|
||||||
|
end)
|
||||||
|
end
|
||||||
|
|
||||||
|
return MiniPick.builtin.cli({ command = command, postprocess = postprocess }, { source = { choose = choose } })
|
||||||
|
end
|
||||||
|
|
||||||
MiniPick.registry.files_root = function(local_opts)
|
MiniPick.registry.files_root = function(local_opts)
|
||||||
local root_patterns = { ".jj", ".git" }
|
local root_patterns = { ".jj", ".git" }
|
||||||
local root_dir = vim.fs.dirname(vim.fs.find(root_patterns, { upward = true })[1])
|
local root_dir = vim.fs.dirname(vim.fs.find(root_patterns, { upward = true })[1])
|
||||||
local_opts.cwd = root_dir
|
local_opts.cwd = root_dir
|
||||||
local_opts.tool = "rg"
|
local_opts.tool = "rg"
|
||||||
return MiniPick.builtin.files(local_opts, { source = { cwd = root_dir, tool = "ripgrep" } })
|
return MiniPick.builtin.files(local_opts, { source = { cwd = root_dir, tool = "rg" } })
|
||||||
end
|
end
|
||||||
|
|
||||||
MiniPick.registry.grep_live_root = function(local_opts)
|
MiniPick.registry.grep_live_root = function(local_opts)
|
||||||
local root_patterns = { ".jj", ".git" }
|
local root_patterns = { ".jj", ".git" }
|
||||||
local root_dir = vim.fs.dirname(vim.fs.find(root_patterns, { upward = true })[1])
|
local root_dir = vim.fs.dirname(vim.fs.find(root_patterns, { upward = true })[1])
|
||||||
|
@ -130,9 +174,6 @@ require("mini.pick").registry.buffers = function(local_opts, opts)
|
||||||
return require("mini.pick").start(opts)
|
return require("mini.pick").start(opts)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
local miniclue = require('mini.clue')
|
local miniclue = require('mini.clue')
|
||||||
miniclue.setup({ -- cute prompts about bindings
|
miniclue.setup({ -- cute prompts about bindings
|
||||||
triggers = {
|
triggers = {
|
||||||
|
@ -202,11 +243,14 @@ require('mini.notify').setup({
|
||||||
|
|
||||||
require('mini.starter').setup({
|
require('mini.starter').setup({
|
||||||
header =
|
header =
|
||||||
[[ ______ _
|
[[
|
||||||
(_____ \ _ (_)
|
████████▄ ▄▄ ▒▒
|
||||||
_____) )___| |_ ____ ____ _ ____
|
██ ▀██ ██
|
||||||
| ____/ _ | _)/ _ |/ _ | |/ _ |
|
██ ▄██ ▄██████▄ ██████ ▄██████▄ ▄████▄██ ██ ▄██████▄
|
||||||
| | ( ( | | |_( ( | ( ( | | ( ( | |
|
████████▀ ▀▀ ██ ██ ▀▀ ██ ██▀ ▀██ ██ ▀▀ ██
|
||||||
|_| \_||_|\___)_||_|\_|| |_|\_||_|
|
██ ▄███████ ██ ▄███████ ██ ██ ██ ▄███████
|
||||||
(_____|]]
|
██ ██ ██ ██ ██ ██ ██▄ ▄██ ██ ██ ██
|
||||||
|
██ ▀████▀██ ▀███ ▀████▀██ ▀████▀██ ██ ▀████▀██
|
||||||
|
▄▄ ██
|
||||||
|
▀██████▀ ]]
|
||||||
})
|
})
|
||||||
|
|
40
home/common/nvim/rust.lua
Normal file
40
home/common/nvim/rust.lua
Normal file
|
@ -0,0 +1,40 @@
|
||||||
|
vim.g.rustaceanvim = {
|
||||||
|
server = {
|
||||||
|
settings = {
|
||||||
|
["rust-analyzer"] = {
|
||||||
|
inlayHints = {
|
||||||
|
bindingModeHints = {
|
||||||
|
enable = false,
|
||||||
|
},
|
||||||
|
chainingHints = {
|
||||||
|
enable = true,
|
||||||
|
},
|
||||||
|
closingBraceHints = {
|
||||||
|
enable = true,
|
||||||
|
minLines = 25,
|
||||||
|
},
|
||||||
|
closureReturnTypeHints = {
|
||||||
|
enable = "never",
|
||||||
|
},
|
||||||
|
lifetimeElisionHints = {
|
||||||
|
enable = "never",
|
||||||
|
useParameterNames = false,
|
||||||
|
},
|
||||||
|
maxLength = 25,
|
||||||
|
parameterHints = {
|
||||||
|
enable = true,
|
||||||
|
},
|
||||||
|
reborrowHints = {
|
||||||
|
enable = "never",
|
||||||
|
},
|
||||||
|
renderColons = true,
|
||||||
|
typeHints = {
|
||||||
|
enable = true,
|
||||||
|
hideClosureInitialization = false,
|
||||||
|
hideNamedConstructor = false,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
|
@ -11,8 +11,9 @@
|
||||||
];
|
];
|
||||||
|
|
||||||
plugins = with pkgs.vimPlugins; [
|
plugins = with pkgs.vimPlugins; [
|
||||||
ts-comments-nvim
|
|
||||||
nvim-ts-context-commentstring
|
nvim-ts-context-commentstring
|
||||||
|
playground
|
||||||
|
ts-comments-nvim
|
||||||
|
|
||||||
{
|
{
|
||||||
plugin = nvim-treesitter-context;
|
plugin = nvim-treesitter-context;
|
||||||
|
@ -43,20 +44,6 @@
|
||||||
'';
|
'';
|
||||||
}
|
}
|
||||||
|
|
||||||
{
|
|
||||||
plugin = pkgs.vimUtils.buildVimPlugin {
|
|
||||||
name = "nvim-tree-pairs"; # make % match in TS
|
|
||||||
src = pkgs.fetchFromGitHub {
|
|
||||||
owner = "yorickpeterse";
|
|
||||||
repo = "nvim-tree-pairs";
|
|
||||||
rev = "e7f7b6cc28dda6f3fa271ce63b0d371d5b7641da";
|
|
||||||
hash = "sha256-fb4EsrWAbm8+dWAhiirCPuR44MEg+KYb9hZOIuEuT24=";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
type = "lua";
|
|
||||||
config = "require('tree-pairs').setup()";
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
{
|
||||||
plugin = nvim-treesitter-textobjects;
|
plugin = nvim-treesitter-textobjects;
|
||||||
type = "lua";
|
type = "lua";
|
||||||
|
|
|
@ -25,7 +25,6 @@
|
||||||
set -g status-right '%F | %R'
|
set -g status-right '%F | %R'
|
||||||
set -g status off
|
set -g status off
|
||||||
set -g update-environment "SSH_AUTH_SOCK"
|
set -g update-environment "SSH_AUTH_SOCK"
|
||||||
setenv -g "SSH_AUTH_SOCK" "$XDG_RUNTIME_DIR/ssh-agent"
|
|
||||||
setw -g alternate-screen on
|
setw -g alternate-screen on
|
||||||
setw -g automatic-rename off
|
setw -g automatic-rename off
|
||||||
setw -g window-status-format ""
|
setw -g window-status-format ""
|
||||||
|
@ -34,16 +33,15 @@
|
||||||
|
|
||||||
set -s command-alias[1000] stty='run-shell "tmux send-keys \"stty cols #{pane_width} rows #{pane_height}\" Enter"'
|
set -s command-alias[1000] stty='run-shell "tmux send-keys \"stty cols #{pane_width} rows #{pane_height}\" Enter"'
|
||||||
|
|
||||||
bind -n M-1 if-shell 'tmux select-window -t nvim' refresh-client 'new-window -S -n nvim nvim --listen $XDG_RUNTIME_DIR/nvim-persistent.sock'
|
bind -n C-2 if-shell 'tmux select-window -t t1' refresh-client 'new-window -S -n t1'
|
||||||
bind -n M-2 if-shell 'tmux select-window -t t1' refresh-client 'new-window -S -n t1'
|
bind -n C-3 if-shell 'tmux select-window -t t2' refresh-client 'new-window -S -n t2'
|
||||||
bind -n M-3 if-shell 'tmux select-window -t t2' refresh-client 'new-window -S -n t2'
|
bind -n C-4 if-shell 'tmux select-window -t t3' refresh-client 'new-window -S -n t3'
|
||||||
bind -n M-4 if-shell 'tmux select-window -t t3' refresh-client 'new-window -S -n t3'
|
bind -n C-5 if-shell 'tmux select-window -t t4' refresh-client 'new-window -S -n t4'
|
||||||
bind -n M-5 if-shell 'tmux select-window -t t4' refresh-client 'new-window -S -n t4'
|
bind -n C-6 if-shell 'tmux select-window -t t5' refresh-client 'new-window -S -n t5'
|
||||||
bind -n M-6 if-shell 'tmux select-window -t t5' refresh-client 'new-window -S -n t5'
|
bind -n C-7 if-shell 'tmux select-window -t t6' refresh-client 'new-window -S -n t6'
|
||||||
bind -n M-7 if-shell 'tmux select-window -t t6' refresh-client 'new-window -S -n t6'
|
bind -n C-8 if-shell 'tmux select-window -t t7' refresh-client 'new-window -S -n t7'
|
||||||
bind -n M-8 if-shell 'tmux select-window -t t7' refresh-client 'new-window -S -n t7'
|
bind -n C-9 if-shell 'tmux select-window -t t8' refresh-client 'new-window -S -n t8'
|
||||||
bind -n M-9 if-shell 'tmux select-window -t t8' refresh-client 'new-window -S -n t8'
|
bind -n C-0 if-shell 'tmux select-window -t t9' refresh-client 'new-window -S -n t9'
|
||||||
bind -n M-0 if-shell 'tmux select-window -t t9' refresh-client 'new-window -S -n t9'
|
|
||||||
bind -T copy-mode-vi WheelUpPane select-pane \; send-keys -X -N 1 scroll-up
|
bind -T copy-mode-vi WheelUpPane select-pane \; send-keys -X -N 1 scroll-up
|
||||||
bind -T copy-mode-vi WheelDownPane select-pane \; send-keys -X -N 1 scroll-down
|
bind -T copy-mode-vi WheelDownPane select-pane \; send-keys -X -N 1 scroll-down
|
||||||
bind C-s set-option -g status
|
bind C-s set-option -g status
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
{ pkgs, ... }:
|
{ pkgs, ... }:
|
||||||
{
|
{
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
grc
|
|
||||||
dust
|
dust
|
||||||
jless
|
jless
|
||||||
procs
|
procs
|
||||||
|
@ -33,11 +32,6 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
eza = {
|
|
||||||
enable = true;
|
|
||||||
enableFishIntegration = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
fd.enable = true;
|
fd.enable = true;
|
||||||
|
|
||||||
fzf = {
|
fzf = {
|
||||||
|
@ -53,17 +47,29 @@
|
||||||
ripgrep = {
|
ripgrep = {
|
||||||
enable = true;
|
enable = true;
|
||||||
arguments = [
|
arguments = [
|
||||||
"--glob=!.git/*"
|
"--glob=!**/.cache/*"
|
||||||
"--glob=!.jj/*"
|
"--glob=!**/.direnv/*"
|
||||||
"--glob=!result/*"
|
"--glob=!**/.git/*"
|
||||||
"--glob=!target/*"
|
"--glob=!**/.jj/*"
|
||||||
|
"--glob=!**/{node_modules,.npm,dist}/*"
|
||||||
|
"--glob=!**/target/*"
|
||||||
|
"--glob=!**/result/*"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
zoxide = {
|
};
|
||||||
|
|
||||||
|
programs.eza = {
|
||||||
|
enable = true;
|
||||||
|
enableFishIntegration = true;
|
||||||
|
};
|
||||||
|
home.sessionVariables.EZA_COLORS = "reset:oc=0:ur=0:uw=0:ux=0:ue=0:gr=0:gw=0:gx=0:tr=0:tw=0:tx=0:su=0:sf=0:xa=0:sn=0:nb=0:nk=0:nm=0:ng=0:nt=0:sb=0:ub=0:uk=0:um=0:ug=0:ut=0:df=0:ds=0:uu=0:uR=0:un=0:gu=0:gR=0:gn=0:lc=0:lm=0:ga=0:gm=0:gd=0:gv=0:gt=0:gi=0:gc=0:Gm=0:Go=0:Gc=0:Gd=0:xx=0:da=0:in=0:bl=0:hd=0:lp=3:cc=0:bO=0:sp=0:mp=0:im=0:vi=0:mu=0:lo=0:cr=0:do=0:co=0:tm=0:cm=0:bu=0:sc=0:ic=0:Sn=0:Su=0:Sr=0:St=0:Sl=0:ff=0:di=1:ex=0:fi=0:pi=0:so=0:bd=0:cd=0:ln=3:or=3";
|
||||||
|
|
||||||
|
programs.zoxide = {
|
||||||
enable = true;
|
enable = true;
|
||||||
enableFishIntegration = true;
|
enableFishIntegration = true;
|
||||||
options = [ "--cmd=cd" ];
|
options = [ "--cmd=cd" ];
|
||||||
};
|
};
|
||||||
};
|
home.sessionVariables._ZO_FZF_OPTS="--reverse --height=10 --border=rounded --no-info --no-separator --no-scrollbar --no-color --no-sort";
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{ config, pkgs, ... }:
|
{ config, inputs, pkgs, ... }:
|
||||||
{
|
{
|
||||||
|
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
|
@ -7,7 +7,6 @@
|
||||||
difftastic
|
difftastic
|
||||||
git-get
|
git-get
|
||||||
git-graph
|
git-graph
|
||||||
lazyjj
|
|
||||||
tea
|
tea
|
||||||
];
|
];
|
||||||
|
|
||||||
|
@ -116,9 +115,12 @@
|
||||||
"*.so"
|
"*.so"
|
||||||
"*.swp"
|
"*.swp"
|
||||||
".direnv"
|
".direnv"
|
||||||
|
".env"
|
||||||
".idea"
|
".idea"
|
||||||
|
".nixos-test-history"
|
||||||
".null-ls_*"
|
".null-ls_*"
|
||||||
"result"
|
"/result*"
|
||||||
|
"/target"
|
||||||
];
|
];
|
||||||
|
|
||||||
signing = {
|
signing = {
|
||||||
|
@ -127,45 +129,8 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
programs.gitui = {
|
|
||||||
enable = true;
|
|
||||||
keyConfig = ''
|
|
||||||
(
|
|
||||||
open_help: Some(( code: F(1), modifiers: "")),
|
|
||||||
move_left: Some(( code: Char('h'), modifiers: "")),
|
|
||||||
move_right: Some(( code: Char('l'), modifiers: "")),
|
|
||||||
move_up: Some(( code: Char('k'), modifiers: "")),
|
|
||||||
move_down: Some(( code: Char('j'), modifiers: "")),
|
|
||||||
popup_up: Some(( code: Char('p'), modifiers: "CONTROL")),
|
|
||||||
popup_down: Some(( code: Char('n'), modifiers: "CONTROL")),
|
|
||||||
page_up: Some(( code: Char('b'), modifiers: "CONTROL")),
|
|
||||||
page_down: Some(( code: Char('f'), modifiers: "CONTROL")),
|
|
||||||
home: Some(( code: Char('g'), modifiers: "")),
|
|
||||||
end: Some(( code: Char('G'), modifiers: "SHIFT")),
|
|
||||||
shift_up: Some(( code: Char('K'), modifiers: "SHIFT")),
|
|
||||||
shift_down: Some(( code: Char('J'), modifiers: "SHIFT")),
|
|
||||||
edit_file: Some(( code: Char('I'), modifiers: "SHIFT")),
|
|
||||||
status_reset_item: Some(( code: Char('U'), modifiers: "SHIFT")),
|
|
||||||
diff_reset_lines: Some(( code: Char('u'), modifiers: "")),
|
|
||||||
diff_stage_lines: Some(( code: Char('s'), modifiers: "")),
|
|
||||||
stashing_save: Some(( code: Char('w'), modifiers: "")),
|
|
||||||
stashing_toggle_index: Some(( code: Char('m'), modifiers: "")),
|
|
||||||
stash_open: Some(( code: Char('l'), modifiers: "")),
|
|
||||||
abort_merge: Some(( code: Char('M'), modifiers: "SHIFT")),
|
|
||||||
)
|
|
||||||
'';
|
|
||||||
theme = ''
|
|
||||||
(
|
|
||||||
selection_bg: Some(Black),
|
|
||||||
selection_fg: Some(Reset),
|
|
||||||
cmdbar_bg: Some(Reset),
|
|
||||||
cmdbar_extra_lines_bg: Some(Reset),
|
|
||||||
)
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.jujutsu = {
|
programs.jujutsu = {
|
||||||
enable = true;
|
enable = true;
|
||||||
package = pkgs.jujutsu-openssh;
|
package = inputs.jujutsu.packages.${pkgs.system}.default;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -7,15 +7,13 @@
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
cameractrls-gtk4
|
cameractrls-gtk4
|
||||||
dynamic-wallpaper
|
dynamic-wallpaper
|
||||||
gimp-with-plugins
|
gimp
|
||||||
inkscape
|
inkscape
|
||||||
inputs.ghostty.packages.${pkgs.system}.default
|
|
||||||
moonlight-qt
|
moonlight-qt
|
||||||
obsidian
|
obsidian
|
||||||
pavucontrol
|
pavucontrol
|
||||||
plexamp
|
plexamp
|
||||||
signal-desktop
|
signal-desktop
|
||||||
zed-editor
|
|
||||||
];
|
];
|
||||||
|
|
||||||
xdg.desktopEntries = {
|
xdg.desktopEntries = {
|
||||||
|
|
|
@ -5,6 +5,11 @@
|
||||||
./desktop.nix
|
./desktop.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
|
patagia = {
|
||||||
|
laptop.enable = true;
|
||||||
|
oled.enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
dconf.settings = {
|
dconf.settings = {
|
||||||
"org/gnome/shell" = {
|
"org/gnome/shell" = {
|
||||||
enabled-extensions = [ "Battery-Health-Charging@maniacx.github.com" ];
|
enabled-extensions = [ "Battery-Health-Charging@maniacx.github.com" ];
|
||||||
|
|
|
@ -1,4 +1,9 @@
|
||||||
{ config, pkgs, ... }:
|
{
|
||||||
|
config,
|
||||||
|
lib,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}:
|
||||||
let
|
let
|
||||||
realName = "Daniel Lundin";
|
realName = "Daniel Lundin";
|
||||||
email = "dln@arity.se";
|
email = "dln@arity.se";
|
||||||
|
@ -60,12 +65,7 @@ in
|
||||||
};
|
};
|
||||||
|
|
||||||
ui = {
|
ui = {
|
||||||
"default-command" = [
|
"default-command" = [ "s" ];
|
||||||
"log"
|
|
||||||
"--limit=10"
|
|
||||||
"-T"
|
|
||||||
"builtin_log_comfortable"
|
|
||||||
];
|
|
||||||
pager = "delta";
|
pager = "delta";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -107,23 +107,35 @@ in
|
||||||
];
|
];
|
||||||
d = [
|
d = [
|
||||||
"diff"
|
"diff"
|
||||||
"--tool=difftu"
|
"--tool=difft"
|
||||||
];
|
];
|
||||||
dd = [
|
dd = [
|
||||||
"diff"
|
"diff"
|
||||||
"--git"
|
"--git"
|
||||||
];
|
];
|
||||||
ds = [
|
du = [
|
||||||
"diff"
|
"diff"
|
||||||
"--tool=difft"
|
|
||||||
];
|
|
||||||
s = [
|
|
||||||
"show"
|
|
||||||
"--tool=difftu"
|
"--tool=difftu"
|
||||||
];
|
];
|
||||||
ss = [
|
s = [
|
||||||
"show"
|
"util"
|
||||||
"--tool=difft"
|
"exec"
|
||||||
|
"--"
|
||||||
|
"bash"
|
||||||
|
"-c"
|
||||||
|
''
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
set -eo pipefail
|
||||||
|
printf '\e[38;5;240m\u2504%.0s\e[0m' $(seq 1 $(tput cols)) '\n'
|
||||||
|
jj show --stat
|
||||||
|
printf '\e[38;5;240m\u2504%.0s\e[0m' $(seq 1 $(tput cols)) '\n'
|
||||||
|
if [ -n "$1" ]; then
|
||||||
|
jj diff --tool=difft -r "$@"
|
||||||
|
else
|
||||||
|
jj log --limit=15 -T builtin_log_comfortable
|
||||||
|
fi
|
||||||
|
''
|
||||||
|
""
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -136,26 +148,137 @@ in
|
||||||
"ready" = "open() ~ (wip::)";
|
"ready" = "open() ~ (wip::)";
|
||||||
};
|
};
|
||||||
|
|
||||||
colors = {
|
colors =
|
||||||
"commit_id prefix" = {
|
let
|
||||||
|
bold = {
|
||||||
bold = true;
|
bold = true;
|
||||||
};
|
};
|
||||||
|
dim = {
|
||||||
"rest" = {
|
|
||||||
fg = "bright black";
|
fg = "bright black";
|
||||||
bold = false;
|
|
||||||
};
|
};
|
||||||
|
underline = {
|
||||||
"diff added token" = {
|
fg = "default";
|
||||||
bg = "#002200";
|
|
||||||
fg = "#66ffcc";
|
|
||||||
underline = false;
|
|
||||||
};
|
|
||||||
"diff removed token" = {
|
|
||||||
bg = "#220011";
|
|
||||||
underline = true;
|
underline = true;
|
||||||
};
|
};
|
||||||
|
in
|
||||||
|
{
|
||||||
|
"error" = bold;
|
||||||
|
"warning" = bold;
|
||||||
|
"error heading" = bold;
|
||||||
|
"error_source heading" = bold;
|
||||||
|
"warning heading" = bold;
|
||||||
|
"hint heading" = bold;
|
||||||
|
"prefix" = bold;
|
||||||
|
"rest" = "bright black";
|
||||||
|
"divergent prefix" = underline;
|
||||||
|
"bookmark" = "bright magenta";
|
||||||
|
"bookmarks" = "bright magenta";
|
||||||
|
"change_id" = "bright magenta";
|
||||||
|
"local_bookmarks" = "bright magenta";
|
||||||
|
|
||||||
|
"diff file_header" = bold;
|
||||||
|
"diff hunk_header" = "cyan";
|
||||||
|
"diff removed" = "red";
|
||||||
|
"diff removed token" = "red";
|
||||||
|
"diff added" = "green";
|
||||||
|
"diff added token" = "green";
|
||||||
|
"diff modified" = "cyan";
|
||||||
|
"diff untracked" = "blue";
|
||||||
|
"diff renamed" = "cyan";
|
||||||
|
"diff copied" = "green";
|
||||||
|
"diff access-denied" = {
|
||||||
|
bg = "red";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
"empty" = "green";
|
||||||
|
"elided" = "blue";
|
||||||
|
"node elided" = dim;
|
||||||
|
"node working_copy" = {
|
||||||
|
fg = "green";
|
||||||
|
bold = true;
|
||||||
|
};
|
||||||
|
"node current_operation" = bold;
|
||||||
|
"node immutable" = bold;
|
||||||
|
"node conflict" = {
|
||||||
|
fg = "red";
|
||||||
|
bold = true;
|
||||||
|
};
|
||||||
|
"operation id" = "blue";
|
||||||
|
"operation current_operation" = bold;
|
||||||
|
"remote_bookmarks" = "bright magenta";
|
||||||
|
"working_copy" = {
|
||||||
|
fg = "green";
|
||||||
|
bold = true;
|
||||||
|
};
|
||||||
|
"working_copy empty" = {
|
||||||
|
fg = "green";
|
||||||
|
bold = true;
|
||||||
|
};
|
||||||
|
"working_copy change_id" = "bright magenta";
|
||||||
|
"working_copy description placeholder" = "green";
|
||||||
|
"working_copy empty description placeholder" = "green";
|
||||||
|
"working_copy bookmark" = "bright magenta";
|
||||||
|
"working_copy bookmarks" = "bright magenta";
|
||||||
|
"working_copy local_bookmarks" = "bright magenta";
|
||||||
|
"working_copy remote_bookmarks" = "bright magenta";
|
||||||
|
}
|
||||||
|
// lib.genAttrs [
|
||||||
|
"author"
|
||||||
|
"branch"
|
||||||
|
"branches"
|
||||||
|
"commit_id"
|
||||||
|
"committer"
|
||||||
|
"config_list name"
|
||||||
|
"config_list overridden"
|
||||||
|
"config_list overridden name"
|
||||||
|
"config_list overridden value"
|
||||||
|
"config_list value"
|
||||||
|
"conflict"
|
||||||
|
"conflict_description"
|
||||||
|
"conflict_description difficult"
|
||||||
|
"description placeholder"
|
||||||
|
"diff token"
|
||||||
|
"divergent"
|
||||||
|
"divergent change_id"
|
||||||
|
"divergent rest"
|
||||||
|
"empty description placeholder"
|
||||||
|
"error_source"
|
||||||
|
"git_head"
|
||||||
|
"git_refs"
|
||||||
|
"hidden prefix"
|
||||||
|
"hint"
|
||||||
|
"local_branches"
|
||||||
|
"operation current_operation id"
|
||||||
|
"operation current_operation time"
|
||||||
|
"operation current_operation user"
|
||||||
|
"operation time"
|
||||||
|
"operation user"
|
||||||
|
"placeholder"
|
||||||
|
"remote_branches"
|
||||||
|
"root"
|
||||||
|
"separator"
|
||||||
|
"tag"
|
||||||
|
"tags"
|
||||||
|
"timestamp"
|
||||||
|
"working_copies"
|
||||||
|
"working_copy author"
|
||||||
|
"working_copy branch"
|
||||||
|
"working_copy branches"
|
||||||
|
"working_copy commit_id"
|
||||||
|
"working_copy committer"
|
||||||
|
"working_copy conflict"
|
||||||
|
"working_copy divergent"
|
||||||
|
"working_copy divergent change_id"
|
||||||
|
"working_copy git_refs"
|
||||||
|
"working_copy local_branches"
|
||||||
|
"working_copy placeholder"
|
||||||
|
"working_copy remote_branches"
|
||||||
|
"working_copy tag"
|
||||||
|
"working_copy tags"
|
||||||
|
"working_copy timestamp"
|
||||||
|
"working_copy working_copies"
|
||||||
|
] (_: "default");
|
||||||
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -164,12 +287,12 @@ in
|
||||||
'';
|
'';
|
||||||
|
|
||||||
programs.ssh.matchBlocks = {
|
programs.ssh.matchBlocks = {
|
||||||
dev = {
|
dev-old = {
|
||||||
hostname = "10.1.100.16";
|
hostname = "10.1.100.16";
|
||||||
forwardAgent = true;
|
forwardAgent = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
nemo = {
|
devel = {
|
||||||
hostname = "10.1.100.20";
|
hostname = "10.1.100.20";
|
||||||
forwardAgent = true;
|
forwardAgent = true;
|
||||||
localForwards = [
|
localForwards = [
|
||||||
|
|
|
@ -1,40 +0,0 @@
|
||||||
{ pkgs, ... }:
|
|
||||||
{
|
|
||||||
home = {
|
|
||||||
username = "lsjostro";
|
|
||||||
homeDirectory = "/home/lsjostro";
|
|
||||||
packages = with pkgs; [ openconnect ];
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.git = {
|
|
||||||
userName = "Lars Sjöstrom";
|
|
||||||
userEmail = "lars@radicore.se";
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.ssh.matchBlocks = {
|
|
||||||
dev = {
|
|
||||||
hostname = "10.1.100.17";
|
|
||||||
};
|
|
||||||
|
|
||||||
nemo = {
|
|
||||||
hostname = "10.1.100.20";
|
|
||||||
forwardAgent = true;
|
|
||||||
localForwards = [
|
|
||||||
{
|
|
||||||
bind.address = "localhost";
|
|
||||||
bind.port = 8000;
|
|
||||||
host.address = "localhost";
|
|
||||||
host.port = 8000;
|
|
||||||
}
|
|
||||||
{
|
|
||||||
bind.address = "localhost";
|
|
||||||
bind.port = 8080;
|
|
||||||
host.address = "localhost";
|
|
||||||
host.port = 8080;
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
home.stateVersion = "24.05"; # https://nixos.wiki/wiki/FAQ/When_do_I_update_stateVersion
|
|
||||||
}
|
|
|
@ -1,6 +0,0 @@
|
||||||
{ ... }:
|
|
||||||
{
|
|
||||||
imports = [ ./home.nix ];
|
|
||||||
|
|
||||||
# Host specific user config goes here
|
|
||||||
}
|
|
|
@ -78,10 +78,10 @@
|
||||||
|
|
||||||
networking = {
|
networking = {
|
||||||
hostName = "dinky";
|
hostName = "dinky";
|
||||||
domain = "aarn.patagia.dev";
|
domain = "aarn.patagia.net";
|
||||||
search = [
|
search = [
|
||||||
"patagia.dev"
|
"patagia.net"
|
||||||
"aarn.patagia.dev"
|
"aarn.patagia.net"
|
||||||
];
|
];
|
||||||
useDHCP = lib.mkDefault true;
|
useDHCP = lib.mkDefault true;
|
||||||
};
|
};
|
||||||
|
@ -120,7 +120,7 @@
|
||||||
nix.settings.trusted-users = [ "dln" ];
|
nix.settings.trusted-users = [ "dln" ];
|
||||||
nix.buildMachines = [
|
nix.buildMachines = [
|
||||||
{
|
{
|
||||||
hostName = "nemo.aarn.patagia.dev";
|
hostName = "nemo.aarn.patagia.net";
|
||||||
sshUser = "nixremote";
|
sshUser = "nixremote";
|
||||||
sshKey = "/root/.ssh/id_ed25519";
|
sshKey = "/root/.ssh/id_ed25519";
|
||||||
system = "x86_64-linux";
|
system = "x86_64-linux";
|
||||||
|
@ -138,7 +138,7 @@
|
||||||
nix.distributedBuilds = true;
|
nix.distributedBuilds = true;
|
||||||
nix.settings.builders-use-substitutes = true;
|
nix.settings.builders-use-substitutes = true;
|
||||||
nix.settings.trusted-substituters = [
|
nix.settings.trusted-substituters = [
|
||||||
"ssh-ng://nemo.aarn.patagia.dev"
|
"ssh-ng://nemo.aarn.patagia.net"
|
||||||
];
|
];
|
||||||
|
|
||||||
system.stateVersion = "24.05"; # Did you read the comment?
|
system.stateVersion = "24.05"; # Did you read the comment?
|
||||||
|
|
|
@ -87,7 +87,7 @@
|
||||||
|
|
||||||
networking = {
|
networking = {
|
||||||
hostName = "nemo"; # Define your hostname.
|
hostName = "nemo"; # Define your hostname.
|
||||||
domain = "aarn.patagia.dev";
|
domain = "aarn.patagia.net";
|
||||||
nameservers = [
|
nameservers = [
|
||||||
"10.1.100.11"
|
"10.1.100.11"
|
||||||
"10.1.100.12"
|
"10.1.100.12"
|
||||||
|
@ -124,27 +124,26 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
# FIXME: pam_rssh is broken from rust 1.80 upgrade
|
# FIXME: pam_rssh is broken from rust 1.80 upgrade
|
||||||
# environment.systemPackages = [ pkgs.pam_rssh ];
|
security = {
|
||||||
# security = {
|
pam.services.doas =
|
||||||
# pam.services.doas =
|
{ config, ... }:
|
||||||
# { config, ... }:
|
{
|
||||||
# {
|
rules.auth.rssh = {
|
||||||
# rules.auth.rssh = {
|
order = config.rules.auth.ssh_agent_auth.order - 1;
|
||||||
# order = config.rules.auth.ssh_agent_auth.order - 1;
|
control = "sufficient";
|
||||||
# control = "sufficient";
|
modulePath = "${pkgs.pam_rssh}/lib/libpam_rssh.so";
|
||||||
# modulePath = "${pkgs.pam_rssh}/lib/libpam_rssh.so";
|
settings.authorized_keys_command = pkgs.writeShellScript "get-authorized-keys" ''
|
||||||
# settings.authorized_keys_command = pkgs.writeShellScript "get-authorized-keys" ''
|
cat "/etc/ssh/authorized_keys.d/$1"
|
||||||
# cat "/etc/ssh/authorized_keys.d/$1"
|
'';
|
||||||
# '';
|
};
|
||||||
# };
|
};
|
||||||
# };
|
};
|
||||||
# };
|
|
||||||
|
|
||||||
services.resolved = {
|
services.resolved = {
|
||||||
enable = true;
|
enable = true;
|
||||||
domains = [
|
domains = [
|
||||||
"patagia.dev"
|
"patagia.net"
|
||||||
"aarn.patagia.dev"
|
"aarn.patagia.net"
|
||||||
];
|
];
|
||||||
llmnr = "false";
|
llmnr = "false";
|
||||||
fallbackDns = [ "9.9.9.9" ];
|
fallbackDns = [ "9.9.9.9" ];
|
||||||
|
@ -159,12 +158,6 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
services.sunshine = {
|
|
||||||
enable = true;
|
|
||||||
openFirewall = true;
|
|
||||||
settings = { };
|
|
||||||
};
|
|
||||||
|
|
||||||
patagia = {
|
patagia = {
|
||||||
desktop.enable = true;
|
desktop.enable = true;
|
||||||
plymouth.enable = true;
|
plymouth.enable = true;
|
||||||
|
@ -175,17 +168,29 @@
|
||||||
ffado
|
ffado
|
||||||
libcamera
|
libcamera
|
||||||
lm_sensors
|
lm_sensors
|
||||||
# pkgs.pam_rssh
|
pam_rssh
|
||||||
openconnect
|
openconnect
|
||||||
|
tpm2-tools
|
||||||
v4l-utils
|
v4l-utils
|
||||||
];
|
];
|
||||||
|
|
||||||
programs.coolercontrol.enable = true;
|
environment.variables = {
|
||||||
|
OTEL_EXPORTER_OTLP_ENDPOINT = "https://otel.aarn.patagia.net";
|
||||||
|
};
|
||||||
|
|
||||||
|
security.tpm2 = {
|
||||||
|
enable = true;
|
||||||
|
pkcs11.enable = true;
|
||||||
|
tctiEnvironment.enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
users.users.dln = {
|
users.users.dln = {
|
||||||
isNormalUser = true;
|
isNormalUser = true;
|
||||||
description = "Daniel Lundin";
|
description = "Daniel Lundin";
|
||||||
extraGroups = [ "wheel" ];
|
extraGroups = [
|
||||||
|
"tss"
|
||||||
|
"wheel"
|
||||||
|
];
|
||||||
openssh.authorizedKeys.keys = [
|
openssh.authorizedKeys.keys = [
|
||||||
"sk-ssh-ed25519@openssh.com AAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY29tAAAAIIHMAEZx02kbHrEygyPQYStiXlrIe6EIqBCv7anIkL0pAAAABHNzaDo= dln@dinky"
|
"sk-ssh-ed25519@openssh.com AAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY29tAAAAIIHMAEZx02kbHrEygyPQYStiXlrIe6EIqBCv7anIkL0pAAAABHNzaDo= dln@dinky"
|
||||||
"sk-ssh-ed25519@openssh.com AAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY29tAAAAIJNOBFoU7Cdsgi4KpYRcv7EhR/8kD4DYjEZnwk6urRx7AAAABHNzaDo= dln@nemo"
|
"sk-ssh-ed25519@openssh.com AAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY29tAAAAIJNOBFoU7Cdsgi4KpYRcv7EhR/8kD4DYjEZnwk6urRx7AAAABHNzaDo= dln@nemo"
|
||||||
|
@ -195,7 +200,10 @@
|
||||||
users.users.lsjostro = {
|
users.users.lsjostro = {
|
||||||
isNormalUser = true;
|
isNormalUser = true;
|
||||||
description = "Lars Sjöström";
|
description = "Lars Sjöström";
|
||||||
extraGroups = [ "wheel" ];
|
extraGroups = [
|
||||||
|
"tss"
|
||||||
|
"wheel"
|
||||||
|
];
|
||||||
openssh.authorizedKeys.keys = [
|
openssh.authorizedKeys.keys = [
|
||||||
"sk-ecdsa-sha2-nistp256@openssh.com AAAAInNrLWVjZHNhLXNoYTItbmlzdHAyNTZAb3BlbnNzaC5jb20AAAAIbmlzdHAyNTYAAABBBJ10mLOpInoqDaySyrxbzvcOrJfLw48Y6eWHa9501lw+hEEBXya3ib7nlvpCqEQJ8aPU5fVRqpkOW5zSimCiRbwAAAAEc3NoOg=="
|
"sk-ecdsa-sha2-nistp256@openssh.com AAAAInNrLWVjZHNhLXNoYTItbmlzdHAyNTZAb3BlbnNzaC5jb20AAAAIbmlzdHAyNTYAAABBBJ10mLOpInoqDaySyrxbzvcOrJfLw48Y6eWHa9501lw+hEEBXya3ib7nlvpCqEQJ8aPU5fVRqpkOW5zSimCiRbwAAAAEc3NoOg=="
|
||||||
"sk-ecdsa-sha2-nistp256@openssh.com AAAAInNrLWVjZHNhLXNoYTItbmlzdHAyNTZAb3BlbnNzaC5jb20AAAAIbmlzdHAyNTYAAABBBLpoKvsZDIQQLfgzJhe1jAQubBNxjydkj8UfdUPaSXqgfB02OypMOC1m5ZuJYcQIxox0I+4Z8xstFhYP6s8zKZwAAAAEc3NoOg=="
|
"sk-ecdsa-sha2-nistp256@openssh.com AAAAInNrLWVjZHNhLXNoYTItbmlzdHAyNTZAb3BlbnNzaC5jb20AAAAIbmlzdHAyNTYAAABBBLpoKvsZDIQQLfgzJhe1jAQubBNxjydkj8UfdUPaSXqgfB02OypMOC1m5ZuJYcQIxox0I+4Z8xstFhYP6s8zKZwAAAAEc3NoOg=="
|
||||||
|
@ -213,11 +221,19 @@
|
||||||
};
|
};
|
||||||
users.groups.nixremote = { };
|
users.groups.nixremote = { };
|
||||||
|
|
||||||
|
nix.sshServe.enable = true;
|
||||||
|
nix.sshServe.keys = [
|
||||||
|
"sk-ssh-ed25519@openssh.com AAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY29tAAAAIIHMAEZx02kbHrEygyPQYStiXlrIe6EIqBCv7anIkL0pAAAABHNzaDo= dln@dinky"
|
||||||
|
"sk-ssh-ed25519@openssh.com AAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY29tAAAAIJNOBFoU7Cdsgi4KpYRcv7EhR/8kD4DYjEZnwk6urRx7AAAABHNzaDo= dln@nemo"
|
||||||
|
"sk-ecdsa-sha2-nistp256@openssh.com AAAAInNrLWVjZHNhLXNoYTItbmlzdHAyNTZAb3BlbnNzaC5jb20AAAAIbmlzdHAyNTYAAABBBJ10mLOpInoqDaySyrxbzvcOrJfLw48Y6eWHa9501lw+hEEBXya3ib7nlvpCqEQJ8aPU5fVRqpkOW5zSimCiRbwAAAAEc3NoOg=="
|
||||||
|
"sk-ecdsa-sha2-nistp256@openssh.com AAAAInNrLWVjZHNhLXNoYTItbmlzdHAyNTZAb3BlbnNzaC5jb20AAAAIbmlzdHAyNTYAAABBBLpoKvsZDIQQLfgzJhe1jAQubBNxjydkj8UfdUPaSXqgfB02OypMOC1m5ZuJYcQIxox0I+4Z8xstFhYP6s8zKZwAAAAEc3NoOg=="
|
||||||
|
];
|
||||||
|
|
||||||
nix.settings.trusted-users = [
|
nix.settings.trusted-users = [
|
||||||
"dln"
|
"dln"
|
||||||
"lsjostro"
|
"lsjostro"
|
||||||
"nixremote"
|
"nixremote"
|
||||||
];
|
];
|
||||||
|
|
||||||
system.stateVersion = "24.05"; # https://nixos.wiki/wiki/FAQ/When_do_I_update_stateVersion
|
system.stateVersion = "24.11"; # https://nixos.wiki/wiki/FAQ/When_do_I_update_stateVersion
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,6 +4,20 @@
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
{
|
{
|
||||||
|
|
||||||
|
users.users.woodpecker = {
|
||||||
|
isSystemUser = true;
|
||||||
|
group = "woodpecker";
|
||||||
|
extraGroups = [
|
||||||
|
"docker"
|
||||||
|
"podman"
|
||||||
|
];
|
||||||
|
createHome = true;
|
||||||
|
home = "/etc/woodpecker";
|
||||||
|
homeMode = "764";
|
||||||
|
};
|
||||||
|
users.groups.woodpecker = { };
|
||||||
|
|
||||||
services.woodpecker-agents.agents.docker = {
|
services.woodpecker-agents.agents.docker = {
|
||||||
enable = true;
|
enable = true;
|
||||||
package = pkgs.woodpecker-agent;
|
package = pkgs.woodpecker-agent;
|
||||||
|
@ -27,7 +41,11 @@
|
||||||
];
|
];
|
||||||
# restartIfChanged = false;
|
# restartIfChanged = false;
|
||||||
serviceConfig = {
|
serviceConfig = {
|
||||||
|
User = "woodpecker";
|
||||||
|
Group = "woodpecker";
|
||||||
|
WorkingDirectory = "/etc/woodpecker";
|
||||||
BindPaths = [ "/run/podman/podman.sock" ];
|
BindPaths = [ "/run/podman/podman.sock" ];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -33,10 +33,10 @@
|
||||||
|
|
||||||
networking = {
|
networking = {
|
||||||
hostName = "pearl";
|
hostName = "pearl";
|
||||||
domain = "aarn.patagia.dev";
|
domain = "aarn.patagia.net";
|
||||||
search = [
|
search = [
|
||||||
"patagia.dev"
|
"patagia.dev"
|
||||||
"aarn.patagia.dev"
|
"aarn.patagia.net"
|
||||||
];
|
];
|
||||||
useDHCP = lib.mkDefault true;
|
useDHCP = lib.mkDefault true;
|
||||||
};
|
};
|
||||||
|
@ -99,7 +99,7 @@
|
||||||
console.keyMap = "sv-latin1";
|
console.keyMap = "sv-latin1";
|
||||||
|
|
||||||
# Enable sound with pipewire.
|
# Enable sound with pipewire.
|
||||||
hardware.pulseaudio.enable = false;
|
services.pulseaudio.enable = false;
|
||||||
security.rtkit.enable = true;
|
security.rtkit.enable = true;
|
||||||
services.pipewire = {
|
services.pipewire = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
|
@ -1,5 +1,3 @@
|
||||||
pkgs: {
|
pkgs: {
|
||||||
gnome-ssh-askpass4 = pkgs.callPackage ./gnome-ssh-askpass4 { };
|
gnome-ssh-askpass4 = pkgs.callPackage ./gnome-ssh-askpass4 { };
|
||||||
jujutsu-openssh = pkgs.callPackage ./jujutsu-openssh { };
|
|
||||||
lazyjj = pkgs.callPackage ./lazyjj { };
|
|
||||||
}
|
}
|
||||||
|
|
3828
pkgs/jujutsu-openssh/Cargo.lock
generated
3828
pkgs/jujutsu-openssh/Cargo.lock
generated
File diff suppressed because it is too large
Load diff
|
@ -1,89 +0,0 @@
|
||||||
{
|
|
||||||
lib,
|
|
||||||
fetchFromGitHub,
|
|
||||||
rustPlatform,
|
|
||||||
pkg-config,
|
|
||||||
openssl,
|
|
||||||
gzip,
|
|
||||||
libgit2,
|
|
||||||
openssh,
|
|
||||||
zstd,
|
|
||||||
installShellFiles,
|
|
||||||
nix-update-script,
|
|
||||||
testers,
|
|
||||||
jujutsu-openssh,
|
|
||||||
}:
|
|
||||||
|
|
||||||
rustPlatform.buildRustPackage rec {
|
|
||||||
pname = "jujutsu-openssh";
|
|
||||||
version = "0.23.0+pr3191.openssh";
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "dln";
|
|
||||||
repo = "jj";
|
|
||||||
rev = "aa61f294708502d4faf120720252b4aa76157f2d"; # https://github.com/dln/jj/tree/openssh
|
|
||||||
hash = "sha256-5U873EtczuQBysXmfhLh0wrZ7rdkszOKHlakROBckWI=";
|
|
||||||
};
|
|
||||||
|
|
||||||
cargoLock.lockFile = ./Cargo.lock;
|
|
||||||
cargoLock.outputHashes = {
|
|
||||||
"git2-0.19.0" = "sha256-fV8dFChGeDhb20bMyqefpAD5/+raQQ2sMdkEtlA1jaE=";
|
|
||||||
};
|
|
||||||
|
|
||||||
cargoBuildFlags = [
|
|
||||||
"--bin"
|
|
||||||
"jj"
|
|
||||||
]; # don't install the fake editors
|
|
||||||
useNextest = false; # nextest is the upstream integration framework, but is problematic for test skipping
|
|
||||||
ZSTD_SYS_USE_PKG_CONFIG = "1"; # disable vendored zlib
|
|
||||||
|
|
||||||
nativeBuildInputs = [
|
|
||||||
gzip
|
|
||||||
installShellFiles
|
|
||||||
pkg-config
|
|
||||||
];
|
|
||||||
|
|
||||||
buildInputs = [
|
|
||||||
openssl
|
|
||||||
zstd
|
|
||||||
libgit2
|
|
||||||
openssh
|
|
||||||
];
|
|
||||||
|
|
||||||
postInstall = ''
|
|
||||||
$out/bin/jj util mangen > ./jj.1
|
|
||||||
installManPage ./jj.1
|
|
||||||
|
|
||||||
installShellCompletion --cmd jj \
|
|
||||||
--bash <($out/bin/jj util completion bash) \
|
|
||||||
--fish <($out/bin/jj util completion fish) \
|
|
||||||
--zsh <($out/bin/jj util completion zsh)
|
|
||||||
'';
|
|
||||||
|
|
||||||
checkFlags = [
|
|
||||||
# signing tests spin up an ssh-agent and do git checkouts
|
|
||||||
"--skip=test_ssh_signing"
|
|
||||||
];
|
|
||||||
|
|
||||||
passthru = {
|
|
||||||
updateScript = nix-update-script { };
|
|
||||||
tests = {
|
|
||||||
version = testers.testVersion {
|
|
||||||
package = jujutsu-openssh;
|
|
||||||
command = "jj --version";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
meta = with lib; {
|
|
||||||
description = "Git-compatible DVCS that is both simple and powerful";
|
|
||||||
homepage = "https://github.com/martinvonz/jj";
|
|
||||||
changelog = "https://github.com/martinvonz/jj/blob/v${version}/CHANGELOG.md";
|
|
||||||
license = licenses.asl20;
|
|
||||||
maintainers = with maintainers; [
|
|
||||||
_0x4A6F
|
|
||||||
thoughtpolice
|
|
||||||
];
|
|
||||||
mainProgram = "jj";
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,30 +0,0 @@
|
||||||
{
|
|
||||||
stdenvNoCC,
|
|
||||||
fetchzip,
|
|
||||||
}:
|
|
||||||
let
|
|
||||||
version = "0.3.1";
|
|
||||||
in
|
|
||||||
stdenvNoCC.mkDerivation {
|
|
||||||
name = "lazyjj";
|
|
||||||
inherit version;
|
|
||||||
|
|
||||||
src = fetchzip {
|
|
||||||
url = "https://github.com/Cretezy/lazyjj/releases/download/v0.3.1/lazyjj-v0.3.1-x86_64-unknown-linux-musl.tar.gz";
|
|
||||||
hash = "sha256-6R4W6uyq8sns8WLoJxp06xAYaJ0Zn+pZLtwhVIPobmc=";
|
|
||||||
};
|
|
||||||
|
|
||||||
installPhase = ''
|
|
||||||
runHook preInstall
|
|
||||||
mkdir -p $out/bin
|
|
||||||
install -m755 -D $src/lazyjj $out/bin/lazyjj
|
|
||||||
runHook postInstall
|
|
||||||
'';
|
|
||||||
|
|
||||||
meta = {
|
|
||||||
homepage = "https://github.com/Cretezy/lazyjj";
|
|
||||||
description = "TUI for jj";
|
|
||||||
mainProgram = "lazyjj";
|
|
||||||
platforms = [ "x86_64-linux" ];
|
|
||||||
};
|
|
||||||
}
|
|
Loading…
Reference in a new issue