Compare commits
7 commits
742a7e910e
...
2cacfb7907
Author | SHA1 | Date | |
---|---|---|---|
|
2cacfb7907 | ||
|
096313cb82 | ||
|
789b096077 | ||
|
ff6a56b52b | ||
0299545228 | |||
5a3d9a1d31 | |||
b619eaacf4 |
15 changed files with 272 additions and 119 deletions
|
@ -76,17 +76,18 @@ map ctrl+shift+left resize_window narrower
|
||||||
map ctrl+shift+right resize_window wider
|
map ctrl+shift+right resize_window wider
|
||||||
map ctrl+shift+up resize_window taller
|
map ctrl+shift+up resize_window taller
|
||||||
map ctrl+shift+down resize_window shorter 3
|
map ctrl+shift+down resize_window shorter 3
|
||||||
|
map ctrl+shift+enter new_window_with_cwd
|
||||||
|
|
||||||
# reset all windows in the tab to default sizes
|
# reset all windows in the tab to default sizes
|
||||||
map ctrl+shift+0 resize_window reset
|
map ctrl+shift+0 resize_window reset
|
||||||
|
|
||||||
confirm_os_window_close 0
|
confirm_os_window_close 0
|
||||||
enable_audio_bell no
|
enable_audio_bell no
|
||||||
window_padding_width 6
|
window_padding_width 2
|
||||||
#hide_window_decorations yes
|
#hide_window_decorations yes
|
||||||
font_size 14.0
|
font_size 14.0
|
||||||
#background_opacity 1
|
background_opacity 1
|
||||||
background_opacity 0.98
|
#background_opacity 0.98
|
||||||
#background_image ~/Nextcloud/Images/Wallpapers/kitty-bg.png
|
#background_image ~/Nextcloud/Images/Wallpapers/kitty-bg.png
|
||||||
#background_image_layout cscaled
|
#background_image_layout cscaled
|
||||||
#background_tint 0.99
|
#background_tint 0.99
|
||||||
|
|
|
@ -79,6 +79,10 @@ require("nvim-tree").setup {
|
||||||
quit_on_open = true,
|
quit_on_open = true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
filters = {
|
||||||
|
custom = { ".git" },
|
||||||
|
exclude = { ".gitignore" },
|
||||||
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
local autocmd = vim.api.nvim_create_autocmd
|
local autocmd = vim.api.nvim_create_autocmd
|
||||||
|
@ -101,6 +105,37 @@ local function open_nvim_tree(data)
|
||||||
|
|
||||||
-- open the tree
|
-- open the tree
|
||||||
require("nvim-tree.api").tree.open()
|
require("nvim-tree.api").tree.open()
|
||||||
|
|
||||||
|
-- Get a list of all buffers
|
||||||
|
local buffers = vim.api.nvim_list_bufs()
|
||||||
|
|
||||||
|
-- Iterate over each buffer
|
||||||
|
for _, bufnr in ipairs(buffers) do
|
||||||
|
-- Check if the buffer is empty and doesn't have a name
|
||||||
|
if
|
||||||
|
vim.api.nvim_buf_is_loaded(bufnr)
|
||||||
|
and vim.api.nvim_buf_get_name(bufnr) == ""
|
||||||
|
and vim.api.nvim_buf_get_option(bufnr, "buftype") == ""
|
||||||
|
then
|
||||||
|
-- Get all lines in the buffer
|
||||||
|
local lines = vim.api.nvim_buf_get_lines(bufnr, 0, -1, false)
|
||||||
|
|
||||||
|
-- Initialize a variable to store the total number of characters
|
||||||
|
local total_characters = 0
|
||||||
|
|
||||||
|
-- Iterate over each line and calculate the number of characters
|
||||||
|
for _, line in ipairs(lines) do
|
||||||
|
total_characters = total_characters + #line
|
||||||
|
end
|
||||||
|
|
||||||
|
-- Close the buffer if it's empty:
|
||||||
|
if total_characters == 0 then
|
||||||
|
vim.api.nvim_buf_delete(bufnr, {
|
||||||
|
force = true,
|
||||||
|
})
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
autocmd({ "VimEnter" }, { callback = open_nvim_tree })
|
autocmd({ "VimEnter" }, { callback = open_nvim_tree })
|
||||||
|
|
|
@ -16,6 +16,6 @@ M.ui = {
|
||||||
}
|
}
|
||||||
|
|
||||||
M.nvdash = {
|
M.nvdash = {
|
||||||
load_on_startup = true,
|
load_on_startup = false,
|
||||||
}
|
}
|
||||||
return M
|
return M
|
||||||
|
|
|
@ -4,11 +4,14 @@ local options = {
|
||||||
css = { "prettier" },
|
css = { "prettier" },
|
||||||
html = { "prettier" },
|
html = { "prettier" },
|
||||||
js = { "prettier" },
|
js = { "prettier" },
|
||||||
|
javascript = { "prettier" },
|
||||||
|
typescript = { "prettier" },
|
||||||
php = { "php_cs_fixer" },
|
php = { "php_cs_fixer" },
|
||||||
|
python = { "black" },
|
||||||
},
|
},
|
||||||
|
|
||||||
format_on_save = {
|
format_on_save = {
|
||||||
timeout_ms = 500,
|
timeout_ms = 15000,
|
||||||
lsp_fallback = true,
|
lsp_fallback = true,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,19 +3,19 @@ require("nvchad.configs.lspconfig").defaults()
|
||||||
|
|
||||||
local lspconfig = require "lspconfig"
|
local lspconfig = require "lspconfig"
|
||||||
|
|
||||||
-- EXAMPLE
|
-- cf. https://github.com/neovim/nvim-lspconfig/blob/master/doc/configs.md
|
||||||
local servers = {
|
local servers = {
|
||||||
"html",
|
"html",
|
||||||
"cssls",
|
"cssls",
|
||||||
"phpactor",
|
"phpactor",
|
||||||
"gopls",
|
"gopls",
|
||||||
-- "intelephense",
|
|
||||||
"jsonls",
|
"jsonls",
|
||||||
"lua_ls",
|
"lua_ls",
|
||||||
"nixd",
|
"nixd",
|
||||||
|
"pylsp",
|
||||||
"tailwindcss",
|
"tailwindcss",
|
||||||
"templ",
|
"templ",
|
||||||
"vuels",
|
-- "volar",
|
||||||
}
|
}
|
||||||
local nvlsp = require "nvchad.configs.lspconfig"
|
local nvlsp = require "nvchad.configs.lspconfig"
|
||||||
|
|
||||||
|
|
|
@ -45,6 +45,44 @@ return {
|
||||||
"ThePrimeagen/harpoon",
|
"ThePrimeagen/harpoon",
|
||||||
branch = "harpoon2",
|
branch = "harpoon2",
|
||||||
dependencies = { "nvim-lua/plenary.nvim" },
|
dependencies = { "nvim-lua/plenary.nvim" },
|
||||||
|
opts = {
|
||||||
|
menu = {
|
||||||
|
width = vim.api.nvim_win_get_width(0) - 4,
|
||||||
|
},
|
||||||
|
settings = {
|
||||||
|
save_on_toggle = true,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
keys = function()
|
||||||
|
local keys = {
|
||||||
|
{
|
||||||
|
"<leader>H",
|
||||||
|
function()
|
||||||
|
require("harpoon"):list():add()
|
||||||
|
end,
|
||||||
|
desc = "Harpoon File",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"<leader>h",
|
||||||
|
function()
|
||||||
|
local harpoon = require "harpoon"
|
||||||
|
harpoon.ui:toggle_quick_menu(harpoon:list())
|
||||||
|
end,
|
||||||
|
desc = "Harpoon Quick Menu",
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
for i = 1, 6 do
|
||||||
|
table.insert(keys, {
|
||||||
|
"<F" .. i .. ">",
|
||||||
|
function()
|
||||||
|
require("harpoon"):list():select(i)
|
||||||
|
end,
|
||||||
|
desc = "Harpoon to File " .. i,
|
||||||
|
})
|
||||||
|
end
|
||||||
|
return keys
|
||||||
|
end,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"nvim-treesitter/nvim-treesitter",
|
"nvim-treesitter/nvim-treesitter",
|
||||||
|
@ -64,6 +102,7 @@ return {
|
||||||
"php",
|
"php",
|
||||||
"python",
|
"python",
|
||||||
"rust",
|
"rust",
|
||||||
|
"templ",
|
||||||
"toml",
|
"toml",
|
||||||
"tsx",
|
"tsx",
|
||||||
"typescript",
|
"typescript",
|
||||||
|
|
|
@ -8,15 +8,15 @@ set -g escape-time 0 # zero-out escape time delay
|
||||||
set -g history-limit 1000000 # increase history size (from 2,000)
|
set -g history-limit 1000000 # increase history size (from 2,000)
|
||||||
set -g renumber-windows on # renumber all windows when any window is closed
|
set -g renumber-windows on # renumber all windows when any window is closed
|
||||||
set -g set-clipboard on # use system clipboard
|
set -g set-clipboard on # use system clipboard
|
||||||
set -g status-position top # macOS / darwin style
|
set -g status-position bottom # macOS / darwin style
|
||||||
set -g default-terminal "${TERM}"
|
set -g default-terminal "${TERM}"
|
||||||
set -g pane-active-border-style 'fg=magenta,bg=default'
|
set -g pane-active-border-style 'fg=magenta,bg=default'
|
||||||
set -g pane-border-style 'fg=brightblack,bg=default'
|
set -g pane-border-style 'fg=brightblack,bg=default'
|
||||||
set -g mouse on
|
set -g mouse on
|
||||||
#bind-key -r B run-shell "~/.config/tmux/scripts/sessionizer.sh ~/omerxx/omerxx.com"
|
#bind-key -r B run-shell "~/.config/tmux/scripts/sessionizer.sh ~/omerxx/omerxx.com"
|
||||||
|
|
||||||
set -g @fzf-url-fzf-options '-p 60%,30% --prompt=" " --border-label=" Open URL "'
|
#set -g @fzf-url-fzf-options '-p 60%,30% --prompt=" " --border-label=" Open URL "'
|
||||||
set -g @fzf-url-history-limit '2000'
|
#set -g @fzf-url-history-limit '2000'
|
||||||
|
|
||||||
# Vim style pane selection
|
# Vim style pane selection
|
||||||
bind h select-pane -L
|
bind h select-pane -L
|
||||||
|
@ -31,18 +31,18 @@ set-window-option -g pane-base-index 1
|
||||||
set-option -g renumber-windows on
|
set-option -g renumber-windows on
|
||||||
|
|
||||||
# Use Alt-arrow keys without prefix key to switch panes
|
# Use Alt-arrow keys without prefix key to switch panes
|
||||||
bind -n M-Left select-pane -L
|
#bind -n M-Left select-pane -L
|
||||||
bind -n M-Right select-pane -R
|
#bind -n M-Right select-pane -R
|
||||||
bind -n M-Up select-pane -U
|
#bind -n M-Up select-pane -U
|
||||||
bind -n M-Down select-pane -D
|
#bind -n M-Down select-pane -D
|
||||||
|
|
||||||
# Shift arrow to switch windows
|
# Shift arrow to switch windows
|
||||||
bind -n S-Left previous-window
|
#bind -n S-Left previous-window
|
||||||
bind -n S-Right next-window
|
#bind -n S-Right next-window
|
||||||
|
|
||||||
# Shift Alt vim keys to switch windows
|
# Shift Alt vim keys to switch windows
|
||||||
bind -n M-H previous-window
|
#bind -n M-H previous-window
|
||||||
bind -n M-L next-window
|
#bind -n M-L next-window
|
||||||
|
|
||||||
# set vi-mode
|
# set vi-mode
|
||||||
set-window-option -g mode-keys vi
|
set-window-option -g mode-keys vi
|
||||||
|
@ -51,45 +51,45 @@ bind-key -T copy-mode-vi v send-keys -X begin-selection
|
||||||
bind-key -T copy-mode-vi C-v send-keys -X rectangle-toggle
|
bind-key -T copy-mode-vi C-v send-keys -X rectangle-toggle
|
||||||
bind-key -T copy-mode-vi y send-keys -X copy-selection-and-cancel
|
bind-key -T copy-mode-vi y send-keys -X copy-selection-and-cancel
|
||||||
|
|
||||||
bind '"' split-window -v -c "#{pane_current_path}"
|
#bind '"' split-window -v -c "#{pane_current_path}"
|
||||||
bind % split-window -h -c "#{pane_current_path}"
|
#bind % split-window -h -c "#{pane_current_path}"
|
||||||
|
|
||||||
set -g @plugin 'tmux-plugins/tpm'
|
set -g @plugin 'tmux-plugins/tpm'
|
||||||
set -g @plugin 'tmux-plugins/tmux-sensible'
|
set -g @plugin 'tmux-plugins/tmux-sensible'
|
||||||
set -g @plugin 'tmux-plugins/tmux-yank'
|
set -g @plugin 'tmux-plugins/tmux-yank'
|
||||||
set -g @plugin 'tmux-plugins/tmux-resurrect'
|
set -g @plugin 'tmux-plugins/tmux-resurrect'
|
||||||
set -g @plugin 'tmux-plugins/tmux-continuum'
|
set -g @plugin 'tmux-plugins/tmux-continuum'
|
||||||
set -g @plugin 'fcsonline/tmux-thumbs'
|
#set -g @plugin 'fcsonline/tmux-thumbs'
|
||||||
set -g @plugin 'sainnhe/tmux-fzf'
|
#set -g @plugin 'sainnhe/tmux-fzf'
|
||||||
set -g @plugin 'wfxr/tmux-fzf-url'
|
#set -g @plugin 'wfxr/tmux-fzf-url'
|
||||||
set -g @plugin 'omerxx/catppuccin-tmux' # My fork that holds the meetings script bc I'm lazy af
|
#set -g @plugin 'omerxx/catppuccin-tmux' # My fork that holds the meetings script bc I'm lazy af
|
||||||
set -g @plugin 'omerxx/tmux-sessionx'
|
#set -g @plugin 'omerxx/tmux-sessionx'
|
||||||
|
|
||||||
set -g @sessionx-bind 'o'
|
#set -g @sessionx-bind 'o'
|
||||||
set -g @sessionx-x-path '~/dotfiles'
|
#set -g @sessionx-x-path '~/dotfiles'
|
||||||
set -g @sessionx-window-height '85%'
|
#set -g @sessionx-window-height '85%'
|
||||||
set -g @sessionx-window-width '75%'
|
#set -g @sessionx-window-width '75%'
|
||||||
set -g @sessionx-zoxide-mode 'on'
|
#set -g @sessionx-zoxide-mode 'on'
|
||||||
set -g @continuum-restore 'on'
|
#set -g @continuum-restore 'on'
|
||||||
set -g @resurrect-strategy-nvim 'session'
|
#set -g @resurrect-strategy-nvim 'session'
|
||||||
set -g @catppuccin_window_left_separator ""
|
#set -g @catppuccin_window_left_separator ""
|
||||||
set -g @catppuccin_window_right_separator " "
|
#set -g @catppuccin_window_right_separator " "
|
||||||
set -g @catppuccin_window_middle_separator " █"
|
#set -g @catppuccin_window_middle_separator " █"
|
||||||
set -g @catppuccin_window_number_position "right"
|
#set -g @catppuccin_window_number_position "right"
|
||||||
set -g @catppuccin_window_default_fill "number"
|
#set -g @catppuccin_window_default_fill "number"
|
||||||
set -g @catppuccin_window_default_text "#W"
|
#set -g @catppuccin_window_default_text "#W"
|
||||||
set -g @catppuccin_window_current_fill "number"
|
#set -g @catppuccin_window_current_fill "number"
|
||||||
set -g @catppuccin_window_current_text "#W#{?window_zoomed_flag,(),}"
|
#set -g @catppuccin_window_current_text "#W#{?window_zoomed_flag,(),}"
|
||||||
set -g @catppuccin_status_modules_right "directory date_time"
|
#set -g @catppuccin_status_modules_right "directory date_time"
|
||||||
set -g @catppuccin_status_modules_left "session"
|
#set -g @catppuccin_status_modules_left "session"
|
||||||
set -g @catppuccin_status_left_separator " "
|
#set -g @catppuccin_status_left_separator " "
|
||||||
set -g @catppuccin_status_right_separator " "
|
#set -g @catppuccin_status_right_separator " "
|
||||||
set -g @catppuccin_status_right_separator_inverse "no"
|
#set -g @catppuccin_status_right_separator_inverse "no"
|
||||||
set -g @catppuccin_status_fill "icon"
|
#set -g @catppuccin_status_fill "icon"
|
||||||
set -g @catppuccin_status_connect_separator "no"
|
#set -g @catppuccin_status_connect_separator "no"
|
||||||
set -g @catppuccin_directory_text "#{b:pane_current_path}"
|
#set -g @catppuccin_directory_text "#{b:pane_current_path}"
|
||||||
#set -g @catppuccin_meetings_text "#($HOME/.config/tmux/scripts/cal.sh)"
|
#set -g @catppuccin_meetings_text "#($HOME/.config/tmux/scripts/cal.sh)"
|
||||||
set -g @catppuccin_meetings_text ""
|
#set -g @catppuccin_meetings_text ""
|
||||||
set -g @catppuccin_date_time_text "%H:%M"
|
#set -g @catppuccin_date_time_text "%H:%M"
|
||||||
|
|
||||||
run '~/.config/tmux/plugins/tpm/tpm'
|
run '~/.config/tmux/plugins/tpm/tpm'
|
||||||
|
|
|
@ -8,6 +8,7 @@
|
||||||
ansible
|
ansible
|
||||||
atuin
|
atuin
|
||||||
bat
|
bat
|
||||||
|
black
|
||||||
btop
|
btop
|
||||||
cargo
|
cargo
|
||||||
catnip
|
catnip
|
||||||
|
@ -24,6 +25,7 @@
|
||||||
gnugrep
|
gnugrep
|
||||||
gnumake
|
gnumake
|
||||||
gnupg
|
gnupg
|
||||||
|
go
|
||||||
imagemagick
|
imagemagick
|
||||||
jq
|
jq
|
||||||
git
|
git
|
||||||
|
@ -54,7 +56,9 @@
|
||||||
php83Packages.php-cs-fixer
|
php83Packages.php-cs-fixer
|
||||||
phpactor
|
phpactor
|
||||||
pinentry
|
pinentry
|
||||||
|
python312
|
||||||
python312Packages.pip
|
python312Packages.pip
|
||||||
|
python312Packages.python-lsp-server
|
||||||
ripgrep
|
ripgrep
|
||||||
slides
|
slides
|
||||||
starship
|
starship
|
||||||
|
@ -240,8 +244,6 @@
|
||||||
settings = with builtins; fromTOML (readFile ../dotfiles/starship/starship.toml);
|
settings = with builtins; fromTOML (readFile ../dotfiles/starship/starship.toml);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
zsh = {
|
zsh = {
|
||||||
enable = true;
|
enable = true;
|
||||||
autosuggestion.enable = true;
|
autosuggestion.enable = true;
|
||||||
|
|
|
@ -12,8 +12,7 @@
|
||||||
|
|
||||||
networking.hostName = "dragon"; # Define your hostname.
|
networking.hostName = "dragon"; # Define your hostname.
|
||||||
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
|
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
|
||||||
networking.extraHosts =
|
networking.extraHosts = ''
|
||||||
''
|
|
||||||
163.172.173.184 aleks-test-install-bookworm.test
|
163.172.173.184 aleks-test-install-bookworm.test
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
@ -42,47 +41,94 @@
|
||||||
LC_TIME = "fr_FR.UTF-8";
|
LC_TIME = "fr_FR.UTF-8";
|
||||||
};
|
};
|
||||||
|
|
||||||
# Enable the X11 windowing system.
|
hardware.graphics = {
|
||||||
services.xserver.enable = true;
|
enable = true;
|
||||||
services.xserver.videoDrivers = [ "amdgpu" ];
|
};
|
||||||
|
|
||||||
# Configure keymap in X11
|
nixpkgs.config.allowUnfree = true;
|
||||||
|
nixpkgs.config.nvidia.acceptLicense = true;
|
||||||
|
hardware.nvidia = {
|
||||||
|
|
||||||
|
# Modesetting is required.
|
||||||
|
modesetting.enable = true;
|
||||||
|
|
||||||
|
# Nvidia power management. Experimental, and can cause sleep/suspend to fail.
|
||||||
|
# Enable this if you have graphical corruption issues or application crashes after waking
|
||||||
|
# up from sleep. This fixes it by saving the entire VRAM memory to /tmp/ instead
|
||||||
|
# of just the bare essentials.
|
||||||
|
powerManagement.enable = true;
|
||||||
|
|
||||||
|
# Fine-grained power management. Turns off GPU when not in use.
|
||||||
|
# Experimental and only works on modern Nvidia GPUs (Turing or newer).
|
||||||
|
powerManagement.finegrained = false;
|
||||||
|
|
||||||
|
# Use the NVidia open source kernel module (not to be confused with the
|
||||||
|
# independent third-party "nouveau" open source driver).
|
||||||
|
# Support is limited to the Turing and later architectures. Full list of
|
||||||
|
# supported GPUs is at:
|
||||||
|
# https://github.com/NVIDIA/open-gpu-kernel-modules#compatible-gpus
|
||||||
|
# Only available from driver 515.43.04+
|
||||||
|
# Currently alpha-quality/buggy, so false is currently the recommended setting.
|
||||||
|
open = false;
|
||||||
|
|
||||||
|
# Enable the Nvidia settings menu,
|
||||||
|
# accessible via `nvidia-settings`.
|
||||||
|
nvidiaSettings = true;
|
||||||
|
|
||||||
|
# Optionally, you may need to select the appropriate driver version for your specific GPU.
|
||||||
|
package = config.boot.kernelPackages.nvidiaPackages.latest;
|
||||||
|
};
|
||||||
services.xserver = {
|
services.xserver = {
|
||||||
|
enable = true;
|
||||||
|
videoDrivers = [
|
||||||
|
"intel"
|
||||||
|
"nvidia"
|
||||||
|
];
|
||||||
xkb.layout = "us";
|
xkb.layout = "us";
|
||||||
xkb.variant = "";
|
xkb.variant = "";
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/mnt/nas/music" =
|
fileSystems."/mnt/nas/music" = {
|
||||||
{
|
|
||||||
device = "192.168.1.2:/volume1/music";
|
device = "192.168.1.2:/volume1/music";
|
||||||
options = [ "nfsvers=4.2" "x-systemd.automount" "noauto" "rw" "relatime" "user" "acl" "defaults"];
|
options = [
|
||||||
|
"nfsvers=4.2"
|
||||||
|
"x-systemd.automount"
|
||||||
|
"noauto"
|
||||||
|
"rw"
|
||||||
|
"relatime"
|
||||||
|
"user"
|
||||||
|
"acl"
|
||||||
|
"defaults"
|
||||||
|
];
|
||||||
fsType = "nfs";
|
fsType = "nfs";
|
||||||
};
|
};
|
||||||
|
|
||||||
services.rpcbind.enable = true; # needed for NFS
|
services.rpcbind.enable = true; # needed for NFS
|
||||||
systemd.mounts = [{
|
systemd.mounts = [
|
||||||
|
{
|
||||||
type = "nfs";
|
type = "nfs";
|
||||||
mountConfig = {
|
mountConfig = {
|
||||||
Options = "defaults,acl,user,noauto,relatime,rw";
|
Options = "defaults,acl,user,noauto,relatime,rw";
|
||||||
};
|
};
|
||||||
what = "192.168.1.2:/volume1/music";
|
what = "192.168.1.2:/volume1/music";
|
||||||
where = "/mnt/nas/music";
|
where = "/mnt/nas/music";
|
||||||
}];
|
}
|
||||||
|
];
|
||||||
|
|
||||||
systemd.automounts = [{
|
systemd.automounts = [
|
||||||
|
{
|
||||||
wantedBy = [ "multi-user.target" ];
|
wantedBy = [ "multi-user.target" ];
|
||||||
automountConfig = {
|
automountConfig = {
|
||||||
TimeoutIdleSec = "600";
|
TimeoutIdleSec = "600";
|
||||||
};
|
};
|
||||||
where = "/mnt/nas/music";
|
where = "/mnt/nas/music";
|
||||||
}];
|
}
|
||||||
|
];
|
||||||
|
|
||||||
# Enable CUPS to print documents.
|
# Enable CUPS to print documents.
|
||||||
services.printing.enable = true;
|
services.printing.enable = true;
|
||||||
|
|
||||||
# Enable sound with pipewire.
|
# Enable sound with pipewire.
|
||||||
sound.enable = true;
|
|
||||||
hardware.pulseaudio.enable = false;
|
hardware.pulseaudio.enable = false;
|
||||||
security.rtkit.enable = true;
|
security.rtkit.enable = true;
|
||||||
services.pipewire = {
|
services.pipewire = {
|
||||||
|
@ -102,12 +148,12 @@
|
||||||
# services.xserver.libinput.enable = true;
|
# services.xserver.libinput.enable = true;
|
||||||
|
|
||||||
imports = [
|
imports = [
|
||||||
../modules/console.nix
|
../../modules/console.nix
|
||||||
../modules/desktop.nix
|
../../modules/desktop.nix
|
||||||
../modules/fonts.nix
|
../../modules/fonts.nix
|
||||||
../modules/home-config.nix
|
../../modules/home-config.nix
|
||||||
../modules/local-dev.nix
|
../../modules/local-dev.nix
|
||||||
../modules/nixos.nix
|
../../modules/nixos.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
# This value determines the NixOS release from which the default
|
# This value determines the NixOS release from which the default
|
|
@ -1,29 +1,34 @@
|
||||||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||||
# and may be overwritten by future invocations. Please make changes
|
# and may be overwritten by future invocations. Please make changes
|
||||||
# to /etc/nixos/configuration.nix instead.
|
# to /etc/nixos/configuration.nix instead.
|
||||||
{ config, lib, pkgs, modulesPath, ... }:
|
{ config, lib, modulesPath, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
imports =
|
imports =
|
||||||
[ (modulesPath + "/installer/scan/not-detected.nix")
|
[
|
||||||
|
(modulesPath + "/installer/scan/not-detected.nix")
|
||||||
];
|
];
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "usbhid" "uas" "sd_mod" ];
|
boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "uas" "usbhid" "sd_mod" ];
|
||||||
boot.initrd.kernelModules = [ "amdgpu" ];
|
boot.initrd.kernelModules = [ ];
|
||||||
boot.kernelModules = [ "kvm-intel" ];
|
boot.kernelModules = [ "kvm-intel" ];
|
||||||
boot.extraModulePackages = [ ];
|
boot.extraModulePackages = [ ];
|
||||||
|
|
||||||
fileSystems."/" =
|
fileSystems."/" =
|
||||||
{ device = "/dev/disk/by-uuid/65b2e400-b6f1-4158-9586-1f5bab13f664";
|
{
|
||||||
fsType = "ext4";
|
device = "/dev/disk/by-uuid/1257f6f4-52bf-4c9a-aa00-86080ecd044c";
|
||||||
|
fsType = "btrfs";
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/boot" =
|
fileSystems."/boot" =
|
||||||
{ device = "/dev/disk/by-uuid/685D-B6DB";
|
{
|
||||||
|
device = "/dev/disk/by-uuid/C182-445E";
|
||||||
fsType = "vfat";
|
fsType = "vfat";
|
||||||
|
options = [ "fmask=0077" "dmask=0077" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
swapDevices = [ ];
|
swapDevices =
|
||||||
|
[{ device = "/dev/disk/by-uuid/96a0423d-a4c0-4376-9d34-5a99b764010a"; }];
|
||||||
|
|
||||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
# (the default) this is the recommended approach. When using systemd-networkd it's
|
||||||
|
@ -31,7 +36,6 @@
|
||||||
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
||||||
networking.useDHCP = lib.mkDefault true;
|
networking.useDHCP = lib.mkDefault true;
|
||||||
# networking.interfaces.enp2s0.useDHCP = lib.mkDefault true;
|
# networking.interfaces.enp2s0.useDHCP = lib.mkDefault true;
|
||||||
# networking.interfaces.wlp0s20f0u1.useDHCP = lib.mkDefault true;
|
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
|
@ -1,12 +1,5 @@
|
||||||
# cli programs should be available on servers and desktop
|
# cli programs should be available on servers and desktop
|
||||||
{ config, pkgs, ... }:
|
{ config, pkgs, ... }:
|
||||||
let
|
|
||||||
unstable =
|
|
||||||
import
|
|
||||||
(builtins.fetchTarball "https://github.com/nixos/nixpkgs/tarball/7afa2c97ebb0585d00c64c112344483e89e00545")
|
|
||||||
# reuse the current configuration
|
|
||||||
{ config = config.nixpkgs.config; };
|
|
||||||
in
|
|
||||||
{
|
{
|
||||||
programs.zsh.enable = true;
|
programs.zsh.enable = true;
|
||||||
programs.fzf = {
|
programs.fzf = {
|
||||||
|
@ -17,7 +10,7 @@ in
|
||||||
# programs.neovim = {
|
# programs.neovim = {
|
||||||
# enable = true;
|
# enable = true;
|
||||||
# defaultEditor = true;
|
# defaultEditor = true;
|
||||||
# package = unstable.neovim;
|
# package = pkgs.neovim;
|
||||||
# viAlias = true;
|
# viAlias = true;
|
||||||
# vimAlias = true;
|
# vimAlias = true;
|
||||||
#};
|
#};
|
||||||
|
@ -57,7 +50,8 @@ in
|
||||||
mpd
|
mpd
|
||||||
mpv
|
mpv
|
||||||
neofetch
|
neofetch
|
||||||
unstable.neovim
|
nixd
|
||||||
|
neovim
|
||||||
ollama
|
ollama
|
||||||
pandoc
|
pandoc
|
||||||
pass
|
pass
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
# Window Manager and desktop programs
|
# Window Manager and desktop programs
|
||||||
{ lib, pkgs, ... }:
|
{ lib, pkgs, ... }:
|
||||||
{
|
{
|
||||||
sound.enable = true;
|
|
||||||
hardware.pulseaudio.enable = false;
|
hardware.pulseaudio.enable = false;
|
||||||
security.rtkit.enable = true;
|
security.rtkit.enable = true;
|
||||||
|
|
||||||
|
@ -138,7 +137,7 @@
|
||||||
signal-desktop
|
signal-desktop
|
||||||
thunderbird
|
thunderbird
|
||||||
tigervnc
|
tigervnc
|
||||||
transmission-qt
|
transmission_4-qt
|
||||||
unetbootin
|
unetbootin
|
||||||
vlc
|
vlc
|
||||||
|
|
||||||
|
|
|
@ -240,6 +240,7 @@ in
|
||||||
#tmux = "tmux -f ~/.config/tmux/tmux.conf attach || tmux -f ~/.config/tmux/tmux.conf new";
|
#tmux = "tmux -f ~/.config/tmux/tmux.conf attach || tmux -f ~/.config/tmux/tmux.conf new";
|
||||||
bunx = "bun --bun x";
|
bunx = "bun --bun x";
|
||||||
g = "lazygit";
|
g = "lazygit";
|
||||||
|
t = "/home/mrflos/Code/nixos-config/scripts/tmux-sessionizer";
|
||||||
kdenix = "nix run github:pjones/plasma-manager --extra-experimental-features nix-command --extra-experimental-features flakes > /home/mrflos/Developpements/nixos-config/modules/home-plasma.nix";
|
kdenix = "nix run github:pjones/plasma-manager --extra-experimental-features nix-command --extra-experimental-features flakes > /home/mrflos/Developpements/nixos-config/modules/home-plasma.nix";
|
||||||
icat = "kitty +kitten icat";
|
icat = "kitty +kitten icat";
|
||||||
nixedit = "vi /etc/nixos";
|
nixedit = "vi /etc/nixos";
|
||||||
|
@ -248,7 +249,7 @@ in
|
||||||
socks = "ssh -N -f -C -D 9090 mrflos@yunohost.yeswiki.net -p 6742";
|
socks = "ssh -N -f -C -D 9090 mrflos@yunohost.yeswiki.net -p 6742";
|
||||||
vi = "/run/current-system/sw/bin/nvim";
|
vi = "/run/current-system/sw/bin/nvim";
|
||||||
vim = "/run/current-system/sw/bin/nvim";
|
vim = "/run/current-system/sw/bin/nvim";
|
||||||
yeswiki-updater = "cd /home/mrflos/Developpements/yeswiki-installer/ && sudo php yeswiki-updater.php";
|
yeswiki-updater = "cd /home/mrflos/Code/yeswiki-installer/ && sudo php yeswiki-updater.php";
|
||||||
};
|
};
|
||||||
initExtra = ''
|
initExtra = ''
|
||||||
export BUN_INSTALL="$HOME/.bun"
|
export BUN_INSTALL="$HOME/.bun"
|
||||||
|
|
4
dotfiles/init_yeswiki_repos.sh → scripts/init_yeswiki_repos.sh
Normal file → Executable file
4
dotfiles/init_yeswiki_repos.sh → scripts/init_yeswiki_repos.sh
Normal file → Executable file
|
@ -13,7 +13,7 @@
|
||||||
#printf "================ End install script dependencies ============\n"
|
#printf "================ End install script dependencies ============\n"
|
||||||
|
|
||||||
corebranch="doryphore-dev"
|
corebranch="doryphore-dev"
|
||||||
curdir="$HOME/Developpements" #${PWD}
|
curdir="$HOME/Code" #${PWD}
|
||||||
repos=$(curl --request GET --url "https://api.github.com/orgs/yeswiki/repos?per_page=200" | jq '.[].full_name' | tr -d "\"" | sort)
|
repos=$(curl --request GET --url "https://api.github.com/orgs/yeswiki/repos?per_page=200" | jq '.[].full_name' | tr -d "\"" | sort)
|
||||||
|
|
||||||
# core
|
# core
|
||||||
|
@ -75,4 +75,6 @@ printf "================ End install YesWiki misc from forge.mrflos.pw =========
|
||||||
printf "\n================ Install other projects ================\n"
|
printf "\n================ Install other projects ================\n"
|
||||||
dir="framemo"
|
dir="framemo"
|
||||||
[ ! -d $curdir/$dir ] && git clone ssh://git@framagit.org/colibris/framemo.git
|
[ ! -d $curdir/$dir ] && git clone ssh://git@framagit.org/colibris/framemo.git
|
||||||
|
dir="nixin-web"
|
||||||
|
[ ! -d $curdir/$dir ] && git clone ssh://forgejo@git.distrilab.fr:NixiN/nixin-web.git
|
||||||
printf "================ End install other projects ============\n"
|
printf "================ End install other projects ============\n"
|
27
scripts/tmux-sessionizer
Executable file
27
scripts/tmux-sessionizer
Executable file
|
@ -0,0 +1,27 @@
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
pushd ~/Code
|
||||||
|
if [[ $# -eq 1 ]]; then
|
||||||
|
selected=$1
|
||||||
|
else
|
||||||
|
selected=$(find . -mindepth 1 -maxdepth 1 -type d | fzf)
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ -z $selected ]]; then
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
selected_name=$(basename "$selected" | tr . _)
|
||||||
|
tmux_running=$(pgrep tmux)
|
||||||
|
|
||||||
|
if [[ -z $TMUX ]] && [[ -z $tmux_running ]]; then
|
||||||
|
tmux new-session -s $selected_name -c $selected
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
if ! tmux has-session -t=$selected_name 2> /dev/null; then
|
||||||
|
tmux new-session -ds $selected_name -c $selected
|
||||||
|
fi
|
||||||
|
|
||||||
|
tmux switch-client -t $selected_name
|
||||||
|
popd
|
Loading…
Add table
Reference in a new issue