mirror of
https://github.com/bgrolleman/dotfiles.git
synced 2026-06-24 22:50:44 +02:00
Compare commits
13 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 986c4aaac4 | |||
| 9a6031f44c | |||
| 73aa712074 | |||
| 726ad9df73 | |||
| 09b08492ba | |||
| fb8fda864f | |||
| d93316ac8d | |||
| 69e6d4f1db | |||
| d74daceb09 | |||
| df010c34c1 | |||
| d874988a3e | |||
| c9a260c319 | |||
| 841f5af000 |
@@ -36,9 +36,11 @@
|
||||
become: true
|
||||
apt:
|
||||
name:
|
||||
- flameshot
|
||||
- peek
|
||||
- obs-studio
|
||||
- grim
|
||||
- satty
|
||||
- slurp
|
||||
|
||||
- name: Brave Browser
|
||||
become: true
|
||||
|
||||
@@ -0,0 +1,25 @@
|
||||
{
|
||||
"theme": "dark",
|
||||
"hooks": {
|
||||
"Stop": [
|
||||
{
|
||||
"hooks": [
|
||||
{
|
||||
"type": "command",
|
||||
"command": "notify-send 'Claude' 'Task complete' --icon=dialog-information 2>/dev/null || true"
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"Notification": [
|
||||
{
|
||||
"hooks": [
|
||||
{
|
||||
"type": "command",
|
||||
"command": "msg=$(jq -r '.message // \"Needs your input\"' 2>/dev/null || echo 'Needs your input'); notify-send 'Claude needs input' \"$msg\" --icon=dialog-question 2>/dev/null || true"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,24 @@
|
||||
// TokyoNight Night theme for gitui
|
||||
(
|
||||
selected_tab: Reset,
|
||||
command_fg: Rgb(192, 202, 245),
|
||||
selection_bg: Rgb(41, 46, 66),
|
||||
selection_fg: Rgb(192, 202, 245),
|
||||
cmdbar_bg: Rgb(26, 27, 38),
|
||||
cmdbar_extra_lines_bg: Rgb(26, 27, 38),
|
||||
disabled_fg: Rgb(86, 95, 137),
|
||||
diff_line_add: Rgb(158, 206, 106),
|
||||
diff_line_delete: Rgb(247, 118, 142),
|
||||
diff_file_added: Rgb(115, 218, 202),
|
||||
diff_file_removed: Rgb(247, 118, 142),
|
||||
diff_file_moved: Rgb(187, 154, 247),
|
||||
diff_file_modified: Rgb(224, 175, 104),
|
||||
commit_hash: Rgb(187, 154, 247),
|
||||
commit_time: Rgb(125, 207, 255),
|
||||
commit_author: Rgb(158, 206, 106),
|
||||
danger_fg: Rgb(247, 118, 142),
|
||||
push_gauge_bg: Rgb(65, 72, 104),
|
||||
push_gauge_fg: Rgb(192, 202, 245),
|
||||
tag_fg: Rgb(187, 154, 247),
|
||||
branch_fg: Rgb(224, 175, 104),
|
||||
)
|
||||
@@ -2,7 +2,8 @@
|
||||
# Bas Grolleman
|
||||
|
||||
# Some reason system boots wrong resolution
|
||||
exec --no-startup-id ~/bin/set_display_ultrawide
|
||||
# exec --no-startup-id ~/bin/set_display_ultrawide
|
||||
exec --no-startup-id ~/.screenlayout/dual.sh
|
||||
|
||||
# t
|
||||
set $mod Mod1
|
||||
@@ -53,7 +54,7 @@ bindsym $win+e exec /usr/bin/nautilus /home/bgrolleman
|
||||
bindsym $win+b exec /opt/helium/helium
|
||||
|
||||
# kill focused window
|
||||
bindsym $mod+Shift+q kill
|
||||
bindsym $mod+Shift+y kill
|
||||
|
||||
# start dmenu (a program launcher)
|
||||
#bindsym $mod+d exec --no-startup-id dmenu_run
|
||||
@@ -90,7 +91,7 @@ bindsym $mod+y floating enable; resize set 55ppt 95ppt; move position center
|
||||
# change container layout (stacked, tabbed, toggle split)
|
||||
#bindsym $mod+s layout stacking
|
||||
#bindsym $mod+w layout tabbed
|
||||
#bindsym $mod+e layout toggle split
|
||||
bindsym $mod+e layout toggle split
|
||||
|
||||
# toggle tiling / floating
|
||||
bindsym $mod+space floating toggle
|
||||
@@ -111,6 +112,13 @@ set $ws8 "8"
|
||||
set $ws9 "9"
|
||||
set $ws10 "10"
|
||||
|
||||
workspace $ws1 output primary
|
||||
workspace $ws2 output primary
|
||||
workspace $ws3 output primary
|
||||
workspace $ws4 output primary
|
||||
workspace $ws5 output secondary
|
||||
workspace $ws6 output secondary
|
||||
|
||||
# switch to workspace
|
||||
bindsym $mod+1 workspace number $ws1
|
||||
bindsym $mod+2 workspace number $ws2
|
||||
@@ -168,8 +176,8 @@ mode "resize" {
|
||||
}
|
||||
|
||||
bindsym $mod+r mode "resize"
|
||||
bindsym $mod+Right resize grow width 30px
|
||||
bindsym $mod+Left resize shrink width 30px
|
||||
bindsym $mod+Shift+Right resize grow width 30px
|
||||
bindsym $mod+Shift+Left resize shrink width 30px
|
||||
|
||||
|
||||
exec_always --no-startup-id $HOME/.config/polybar/launch.sh
|
||||
@@ -183,10 +191,10 @@ gaps inner 5px
|
||||
exec --no-startup-id xset dpms 600
|
||||
exec --no-startup-id /usr/bin/blueman-applet
|
||||
exec --no-startup-id nitrogen --restore
|
||||
exec --no-startup-id greenclip deamon
|
||||
exec --no-startup-id flatpak run com.core447.StreamController -b
|
||||
#exec --no-startup-id greenclip deamon
|
||||
#exec --no-startup-id flatpak run com.core447.StreamController -b
|
||||
exec --no-startup-id picom
|
||||
exec --no-startup-id ~/bin/stack-v5.3.1-20240731-x86_64.AppImage
|
||||
#exec --no-startup-id ~/bin/stack-v5.3.1-20240731-x86_64.AppImage
|
||||
|
||||
bindsym $win+period exec flatpak run it.mijorus.smile
|
||||
|
||||
@@ -194,3 +202,8 @@ bindsym $win+period exec flatpak run it.mijorus.smile
|
||||
|
||||
client.focused #ffff00 #ffff00 #000000 #ffff00 #ffff00
|
||||
|
||||
|
||||
# Float Windows
|
||||
for_window [class="Ryujinx"] floating enable
|
||||
for_window [class="steam"] floating enable
|
||||
assign [class="steam"] 4
|
||||
|
||||
@@ -1 +1,3 @@
|
||||
shell bash --login
|
||||
paste_actions replace-dangerous-control-codes
|
||||
|
||||
|
||||
@@ -0,0 +1,32 @@
|
||||
animations {
|
||||
workspace-switch {
|
||||
spring damping-ratio=1.0 stiffness=1000 epsilon=0.0001
|
||||
}
|
||||
window-open {
|
||||
duration-ms 200
|
||||
curve "ease-out-quad"
|
||||
}
|
||||
window-close {
|
||||
duration-ms 200
|
||||
curve "ease-out-cubic"
|
||||
}
|
||||
horizontal-view-movement {
|
||||
spring damping-ratio=1.0 stiffness=900 epsilon=0.0001
|
||||
}
|
||||
window-movement {
|
||||
spring damping-ratio=1.0 stiffness=800 epsilon=0.0001
|
||||
}
|
||||
window-resize {
|
||||
spring damping-ratio=1.0 stiffness=1000 epsilon=0.0001
|
||||
}
|
||||
config-notification-open-close {
|
||||
spring damping-ratio=0.6 stiffness=1200 epsilon=0.001
|
||||
}
|
||||
screenshot-ui-open {
|
||||
duration-ms 300
|
||||
curve "ease-out-quad"
|
||||
}
|
||||
overview-open-close {
|
||||
spring damping-ratio=1.0 stiffness=900 epsilon=0.0001
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
// ────────────── Startup Applications ──────────────
|
||||
// https://github.com/YaLTeR/niri/wiki/Configuration:-Miscellaneous#spawn-sh-at-startup
|
||||
|
||||
spawn-sh-at-startup "qs -c noctalia-shell"
|
||||
|
||||
// Lock screen after 5 min, turn off monitors after 15 min
|
||||
spawn-at-startup "swayidle" "-w"
|
||||
"timeout" "300" "qs -c noctalia-shell ipc call lockScreen lock"
|
||||
"timeout" "900" "niri msg action power-off-monitors"
|
||||
"resume" "niri msg action power-on-monitors"
|
||||
@@ -0,0 +1,9 @@
|
||||
// ────────────── Output Configuration ──────────────
|
||||
// You can run `niri msg outputs` to get the correct name for your displays.
|
||||
// You will have to remove "/-" and edit it before it takes effect.
|
||||
// https://github.com/YaLTeR/niri/wiki/Configuration:-Outputs
|
||||
|
||||
/- output "DP-1" {
|
||||
mode "2560x1440@359.979" // Set resolution and refresh rate
|
||||
scale 1 // No scaling (use 2 for HiDPI)
|
||||
}
|
||||
@@ -0,0 +1,31 @@
|
||||
// ────────────── Input Configuration ──────────────
|
||||
// https://github.com/YaLTeR/niri/wiki/Configuration:-Input
|
||||
|
||||
input {
|
||||
keyboard {
|
||||
xkb {
|
||||
//If you want to overwrite your keyboard layout,
|
||||
// uncomment the line below and change the layout accordingly.
|
||||
//layout "us" // Use the American keyboard layout
|
||||
}
|
||||
numlock // Enable numlock on startup
|
||||
}
|
||||
|
||||
touchpad {
|
||||
//tap // Enable tap-to-click
|
||||
dwt
|
||||
scroll-method "two-finger"
|
||||
tap-button-map "left-right-middle"
|
||||
natural-scroll // Enable natural (macOS-style) scrolling
|
||||
}
|
||||
|
||||
mouse {
|
||||
// If you want to disable Mouse Acceleration,
|
||||
// uncomment the lines below.
|
||||
//accel-profile "flat"
|
||||
//accel-speed 0.0
|
||||
}
|
||||
|
||||
//focus-follows-mouse // Automatically focus windows under the mouse pointer
|
||||
//workspace-auto-back-and-forth // Enable workspace back & forth switching
|
||||
}
|
||||
@@ -0,0 +1,151 @@
|
||||
binds {
|
||||
|
||||
// ────────────── Keybindings ──────────────
|
||||
// https://github.com/YaLTeR/niri/wiki/Configuration:-Key-Bindings
|
||||
|
||||
// ─── noctalia-shell keybinds ───
|
||||
// https://docs.noctalia.dev/getting-started/keybinds/
|
||||
|
||||
//Mod+Shift+ESCAPE { show-hotkey-overlay; }
|
||||
|
||||
Mod+h { show-hotkey-overlay; }
|
||||
Mod+Shift+S { spawn-sh "flameshot gui"; }
|
||||
|
||||
// ─── Applications ───
|
||||
Alt+Return hotkey-overlay-title="Open Terminal: Alacritty" { spawn "alacritty"; }
|
||||
//Mod+CTRL+Return hotkey-overlay-title="Open App Launcher: noctalia launcher" { spawn-sh "qs -c noctalia-shell ipc call launcher toggle"; }
|
||||
Alt+Space hotkey-overlay-title="Open App Launcher: noctalia launcher" { spawn-sh "qs -c noctalia-shell ipc call launcher toggle"; }
|
||||
Mod+B hotkey-overlay-title="Open Browser: helium" { spawn "helium-browser"; }
|
||||
Mod+L hotkey-overlay-title="Lock Screen: noctalia lock" { spawn-sh "qs -c noctalia-shell ipc call lockScreen lock"; }
|
||||
Mod+Shift+Q hotkey-overlay-title="Session Menu: noctalia sessionMenu" { spawn-sh "qs -c noctalia-shell ipc call sessionMenu toggle"; }
|
||||
|
||||
// Please choose your own file manager.
|
||||
Mod+E hotkey-overlay-title="File Manager: Nautilus" { spawn "nautilus"; }
|
||||
|
||||
// ─── Media Controls ───
|
||||
XF86AudioRaiseVolume allow-when-locked=true { spawn-sh "qs -c noctalia-shell ipc call volume increase"; }
|
||||
XF86AudioLowerVolume allow-when-locked=true { spawn-sh "qs -c noctalia-shell ipc call volume decrease"; }
|
||||
XF86AudioMute allow-when-locked=true { spawn-sh "qs -c noctalia-shell ipc call volume muteOutput"; }
|
||||
XF86AudioMicMute allow-when-locked=true { spawn-sh "qs -c noctalia-shell ipc call volume muteInput"; }
|
||||
XF86AudioNext allow-when-locked=true { spawn-sh "qs -c noctalia-shell ipc call media next"; }
|
||||
XF86AudioPrev allow-when-locked=true { spawn-sh "qs -c noctalia-shell ipc call media previous"; }
|
||||
XF86AudioPlay allow-when-locked=true { spawn-sh "qs -c noctalia-shell ipc call media playPause"; }
|
||||
XF86AudioPause allow-when-locked=true { spawn-sh "qs -c noctalia-shell ipc call media playPause"; }
|
||||
|
||||
// ─── Brightness Controls ───
|
||||
XF86MonBrightnessUp allow-when-locked=true { spawn-sh "qs -c noctalia-shell ipc call brightness increase"; }
|
||||
XF86MonBrightnessDown allow-when-locked=true { spawn-sh "qs -c noctalia-shell ipc call brightness decrease"; }
|
||||
|
||||
// ─── Window Movement and Focus ───
|
||||
Alt+H { focus-column-left; }
|
||||
Alt+L { focus-column-right; }
|
||||
Alt+J { focus-workspace-down; }
|
||||
Alt+K { focus-workspace-up; }
|
||||
|
||||
Alt+Shift+H { move-column-left; }
|
||||
Alt+Shift+L { move-column-right; }
|
||||
Alt+Shift+J { move-column-to-workspace-down; }
|
||||
Alt+Shift+K { move-column-to-workspace-up; }
|
||||
|
||||
Mod+Q { close-window; }
|
||||
|
||||
// Mod+Left { focus-column-left; }
|
||||
// Mod+H { focus-column-left; }
|
||||
// Mod+Right { focus-column-right; }
|
||||
// Mod+L { focus-column-right; }
|
||||
// Mod+Up { focus-window-up; }
|
||||
// Mod+K { focus-window-up; }
|
||||
// Mod+Down { focus-window-down; }
|
||||
// Mod+J { focus-window-down; }
|
||||
|
||||
// Mod+CTRL+Left { move-column-left; }
|
||||
// Mod+CTRL+H { move-column-left; }
|
||||
// Mod+CTRL+Right { move-column-right; }
|
||||
// Mod+CTRL+L { move-column-right; }
|
||||
// Mod+CTRL+UP { move-window-up; }
|
||||
// Mod+CTRL+K { move-window-up; }
|
||||
// Mod+CTRL+Down { move-window-down; }
|
||||
// Mod+CTRL+J { move-window-down; }
|
||||
|
||||
Mod+Home { focus-column-first; }
|
||||
Mod+End { focus-column-last; }
|
||||
Mod+CTRL+Home { move-column-to-first; }
|
||||
Mod+CTRL+End { move-column-to-last; }
|
||||
|
||||
Mod+Shift+Left { focus-monitor-left; }
|
||||
Mod+Shift+Right { focus-monitor-right; }
|
||||
Mod+Shift+Up { focus-monitor-up; }
|
||||
Mod+Shift+Down { focus-monitor-down; }
|
||||
|
||||
// Mod+Shift+CTRL+Left { move-column-to-monitor-left; }
|
||||
// Mod+Shift+CTRL+Right { move-column-to-monitor-right; }
|
||||
// Mod+Shift+CTRL+UP { move-column-to-monitor-up; }
|
||||
// Mod+Shift+CTRL+Down { move-column-to-monitor-down; }
|
||||
|
||||
// ─── Workspace Switching ───
|
||||
// Mod+WheelScrollDown cooldown-ms=150 { focus-workspace-down; }
|
||||
// Mod+WheelScrollUp cooldown-ms=150 { focus-workspace-up; }
|
||||
// Mod+CTRL+WheelScrollDown cooldown-ms=150 { move-column-to-workspace-down; }
|
||||
// Mod+CTRL+WheelScrollUp cooldown-ms=150 { move-column-to-workspace-up; }
|
||||
|
||||
// Mod+WheelScrollRight { focus-column-right; }
|
||||
// Mod+WheelScrollLeft { focus-column-left; }
|
||||
// Mod+CTRL+WheelScrollRight { move-column-right; }
|
||||
// Mod+CTRL+WheelScrollLeft { move-column-left; }
|
||||
|
||||
// Mod+Shift+WheelScrollDown { focus-column-right; }
|
||||
// Mod+Shift+WheelScrollUp { focus-column-left; }
|
||||
// Mod+CTRL+Shift+WheelScrollDown { move-column-right; }
|
||||
// Mod+CTRL+Shift+WheelScrollUp { move-column-left; }
|
||||
|
||||
Alt+1 { focus-workspace 1; }
|
||||
Alt+2 { focus-workspace 2; }
|
||||
Alt+3 { focus-workspace 3; }
|
||||
Alt+4 { focus-workspace 4; }
|
||||
Alt+5 { focus-workspace 5; }
|
||||
Alt+6 { focus-workspace 6; }
|
||||
Alt+7 { focus-workspace 7; }
|
||||
Alt+8 { focus-workspace 8; }
|
||||
Alt+9 { focus-workspace 9; }
|
||||
|
||||
Alt+Shift+1 { move-column-to-workspace 1; }
|
||||
Alt+Shift+2 { move-column-to-workspace 2; }
|
||||
Alt+Shift+3 { move-column-to-workspace 3; }
|
||||
Alt+Shift+4 { move-column-to-workspace 4; }
|
||||
Alt+Shift+5 { move-column-to-workspace 5; }
|
||||
Alt+Shift+6 { move-column-to-workspace 6; }
|
||||
Alt+Shift+7 { move-column-to-workspace 7; }
|
||||
Alt+Shift+8 { move-column-to-workspace 8; }
|
||||
Alt+Shift+9 { move-column-to-workspace 9; }
|
||||
|
||||
Mod+TAB { focus-workspace-previous; }
|
||||
|
||||
// ─── Layout Controls ───
|
||||
Mod+CTRL+F { expand-column-to-available-width; }
|
||||
Mod+C { center-column; }
|
||||
Mod+CTRL+C { center-visible-columns; }
|
||||
Mod+Minus { set-column-width "-10%"; }
|
||||
Mod+Equal { set-column-width "+10%"; }
|
||||
Mod+Shift+Minus { set-window-height "-10%"; }
|
||||
Mod+Shift+Equal { set-window-height "+10%"; }
|
||||
|
||||
// ─── Modes ───
|
||||
Mod+T { toggle-window-floating; }
|
||||
Mod+F { fullscreen-window; }
|
||||
Mod+W { toggle-column-tabbed-display; }
|
||||
|
||||
// ─── Screenshots ───
|
||||
CTRL+Shift+1 { screenshot; }
|
||||
CTRL+Shift+2 { screenshot-screen; }
|
||||
CTRL+Shift+3 { screenshot-window; }
|
||||
|
||||
// ─── Emergency Escape Key ───
|
||||
// Use this when a fullscreen app blocks your keybinds.
|
||||
// It disables any active keyboard shortcut inhibitor, restoring control.
|
||||
Mod+ESCAPE allow-inhibiting=false { toggle-keyboard-shortcuts-inhibit; }
|
||||
|
||||
// ─── Exit / Power ───
|
||||
CTRL+ALT+Delete { quit; } // Also quits Niri
|
||||
Mod+Shift+P { power-off-monitors; } // Turn off screens (useful for OLED or privacy)
|
||||
Mod+O repeat=false { toggle-overview; }
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
layout {
|
||||
gaps 16 // Gap between windows
|
||||
center-focused-column "on-overflow" // Don’t auto-center focused column
|
||||
|
||||
background-color "transparent" // <- needed for noctalia-shell to set wallpaper
|
||||
|
||||
//default-column-width { proportion 0.95; }
|
||||
default-column-width { proportion 0.40; }
|
||||
|
||||
preset-column-widths {
|
||||
proportion 0.33333
|
||||
proportion 0.5
|
||||
proportion 0.66667
|
||||
}
|
||||
|
||||
struts {}
|
||||
}
|
||||
@@ -0,0 +1,25 @@
|
||||
prefer-no-csd
|
||||
screenshot-path null
|
||||
|
||||
environment {
|
||||
ELECTRON_OZONE_PLATFORM_HINT "auto"
|
||||
QT_QPA_PLATFORM "wayland"
|
||||
QT_QPA_PLATFORMTHEME "gtk3"
|
||||
QT_WAYLAND_DISABLE_WINDOWDECORATION "1"
|
||||
XDG_CURRENT_DESKTOP "niri"
|
||||
XDG_SESSION_TYPE "wayland"
|
||||
}
|
||||
|
||||
cursor {
|
||||
xcursor-theme "capitaine-cursors"
|
||||
xcursor-size 24
|
||||
}
|
||||
|
||||
debug {
|
||||
// Allows notification actions and window activation from Noctalia.
|
||||
honor-xdg-activation-with-invalid-serial
|
||||
}
|
||||
|
||||
hotkey-overlay {
|
||||
skip-at-startup
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
window-rule {
|
||||
geometry-corner-radius 5 // Set every window radius to 20
|
||||
clip-to-geometry true
|
||||
}
|
||||
|
||||
// if you use steam you will probably like these
|
||||
window-rule {
|
||||
match app-id="steam"
|
||||
exclude title=r#"^[Ss]team$"#
|
||||
open-floating true
|
||||
}
|
||||
|
||||
window-rule {
|
||||
match app-id="steam" title=r#"^notificationtoasts_\d+_desktop$"#
|
||||
default-floating-position x=10 y=10 relative-to="bottom-right"
|
||||
open-focused false
|
||||
}
|
||||
|
||||
layer-rule {
|
||||
match namespace="^noctalia-wallpaper*"
|
||||
place-within-backdrop true
|
||||
}
|
||||
@@ -0,0 +1,2 @@
|
||||
workspace "browser"
|
||||
workspace "chat"
|
||||
@@ -0,0 +1,9 @@
|
||||
include "./cfg/animation.kdl"
|
||||
include "./cfg/autostart.kdl"
|
||||
include "./cfg/keybinds.kdl"
|
||||
include "./cfg/input.kdl"
|
||||
include "./cfg/display.kdl"
|
||||
include "./cfg/layout.kdl"
|
||||
include "./cfg/rules.kdl"
|
||||
include "./cfg/misc.kdl"
|
||||
include "./cfg/workspaces.kdl"
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"mError": "#f38ba8",
|
||||
"mHover": "#94e2d5",
|
||||
"mOnError": "#11111b",
|
||||
"mOnHover": "#11111b",
|
||||
"mOnPrimary": "#11111b",
|
||||
"mOnSecondary": "#11111b",
|
||||
"mOnSurface": "#cdd6f4",
|
||||
"mOnSurfaceVariant": "#a3b4eb",
|
||||
"mOnTertiary": "#11111b",
|
||||
"mOutline": "#4c4f69",
|
||||
"mPrimary": "#cba6f7",
|
||||
"mSecondary": "#fab387",
|
||||
"mShadow": "#11111b",
|
||||
"mSurface": "#1e1e2e",
|
||||
"mSurfaceVariant": "#313244",
|
||||
"mTertiary": "#94e2d5"
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
{
|
||||
"sources": [
|
||||
{
|
||||
"enabled": true,
|
||||
"name": "Noctalia Plugins",
|
||||
"url": "https://github.com/noctalia-dev/noctalia-plugins"
|
||||
}
|
||||
],
|
||||
"states": {
|
||||
"polkit-agent": {
|
||||
"enabled": true,
|
||||
"sourceUrl": "https://github.com/noctalia-dev/noctalia-plugins"
|
||||
}
|
||||
},
|
||||
"version": 2
|
||||
}
|
||||
@@ -0,0 +1,50 @@
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Effects
|
||||
import QtQuick
|
||||
import Quickshell
|
||||
import Quickshell.Services.Polkit
|
||||
import Quickshell.Wayland
|
||||
import qs.Commons
|
||||
import qs.Widgets
|
||||
import qs.Services.UI
|
||||
|
||||
Item {
|
||||
id: root
|
||||
property var pluginApi: null
|
||||
|
||||
PolkitAgent {
|
||||
id: agent
|
||||
|
||||
onIsActiveChanged: {
|
||||
if (isActive) {
|
||||
openWindow()
|
||||
} else {
|
||||
closeWindow()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
property var window: null
|
||||
|
||||
function openWindow() {
|
||||
if (window === null) {
|
||||
window = Qt.createComponent("PolkitWindow.qml").createObject(root, {
|
||||
flow: agent.flow,
|
||||
pluginApi: Qt.binding(function() { return root.pluginApi })
|
||||
});
|
||||
window.visible = true;
|
||||
} else {
|
||||
window.flow = agent.flow
|
||||
window.pluginApi = root.pluginApi
|
||||
window.visible = true
|
||||
}
|
||||
}
|
||||
|
||||
function closeWindow() {
|
||||
if (window !== null) {
|
||||
window.destroy();
|
||||
window = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,211 @@
|
||||
import QtQuick.Layouts
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Effects
|
||||
import QtQuick
|
||||
import Quickshell
|
||||
import Quickshell.Services.Polkit
|
||||
import Quickshell.Wayland
|
||||
import qs.Commons
|
||||
import qs.Widgets
|
||||
import qs.Services.UI
|
||||
|
||||
PanelWindow {
|
||||
id: polkitWindow
|
||||
|
||||
property AuthFlow flow
|
||||
property var pluginApi
|
||||
|
||||
Connections {
|
||||
target: flow
|
||||
function onFailedChanged() {
|
||||
if (flow && flow.failed) {
|
||||
ToastService.showError(
|
||||
pluginApi ? pluginApi.tr("error.failed.title") : "Authentication Failed",
|
||||
pluginApi ? pluginApi.tr("error.failed.message") : "The password you entered was incorrect."
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Layer above everything else (critical system prompt)
|
||||
WlrLayershell.layer: WlrLayer.Overlay
|
||||
WlrLayershell.keyboardFocus: WlrKeyboardFocus.Exclusive
|
||||
|
||||
readonly property real shadowPadding: Style.shadowBlurMax + Style.marginL
|
||||
|
||||
// Explicit size - include shadowPadding so the shadow isn't clipped at window corners
|
||||
implicitWidth: 400 * Style.uiScaleRatio + shadowPadding * 2
|
||||
implicitHeight: contentLayout.implicitHeight + (Style.marginL * 2) + shadowPadding * 2
|
||||
|
||||
color: "transparent"
|
||||
|
||||
Item {
|
||||
id: contentContainer
|
||||
anchors.fill: parent
|
||||
anchors.margins: shadowPadding
|
||||
focus: true
|
||||
|
||||
Keys.onPressed: function(event) {
|
||||
if (!flow) return;
|
||||
|
||||
if (Keybinds.checkKey(event, "escape", Settings)) {
|
||||
flow.cancelAuthenticationRequest();
|
||||
event.accepted = true;
|
||||
} else if (Keybinds.checkKey(event, "enter", Settings)) {
|
||||
if (passwordInput.text !== "") {
|
||||
flow.submit(passwordInput.text);
|
||||
passwordInput.text = "";
|
||||
}
|
||||
event.accepted = true;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
transform: Translate {
|
||||
id: shakeTranslate
|
||||
x: 0
|
||||
}
|
||||
|
||||
// Error animation
|
||||
SequentialAnimation {
|
||||
id: errorShake
|
||||
running: flow && flow.failed
|
||||
loops: 1
|
||||
|
||||
NumberAnimation { target: shakeTranslate; property: "x"; from: 0; to: -10; duration: 50; easing.type: Easing.InOutQuad }
|
||||
NumberAnimation { target: shakeTranslate; property: "x"; from: -10; to: 10; duration: 50; easing.type: Easing.InOutQuad }
|
||||
NumberAnimation { target: shakeTranslate; property: "x"; from: 10; to: -10; duration: 50; easing.type: Easing.InOutQuad }
|
||||
NumberAnimation { target: shakeTranslate; property: "x"; from: -10; to: 10; duration: 50; easing.type: Easing.InOutQuad }
|
||||
NumberAnimation { target: shakeTranslate; property: "x"; from: 10; to: 0; duration: 50; easing.type: Easing.InOutQuad }
|
||||
}
|
||||
|
||||
// Shadow effect (behind background)
|
||||
NDropShadow {
|
||||
anchors.fill: customBackground
|
||||
source: customBackground
|
||||
autoPaddingEnabled: true
|
||||
z: -1
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
id: customBackground
|
||||
anchors.fill: parent
|
||||
radius: Style.radiusL
|
||||
color: Qt.alpha(Color.mSurface, 0.95)
|
||||
border.color: (flow && (flow.failed || flow.supplementaryIsError)) ? Color.mError : Color.mOutline
|
||||
border.width: Style.borderS
|
||||
|
||||
Behavior on border.color {
|
||||
ColorAnimation { duration: Style.animationFast }
|
||||
}
|
||||
}
|
||||
|
||||
ColumnLayout {
|
||||
id: contentLayout
|
||||
anchors.centerIn: parent
|
||||
width: parent.width - (Style.marginL * 2)
|
||||
spacing: Style.marginM
|
||||
|
||||
// Header with Icon
|
||||
RowLayout {
|
||||
Layout.fillWidth: true
|
||||
spacing: Style.marginM
|
||||
|
||||
NImageRounded {
|
||||
Layout.preferredWidth: Style.fontSizeXXL * 2
|
||||
Layout.preferredHeight: Style.fontSizeXXL * 2
|
||||
imagePath: (flow && flow.iconName) ? Quickshell.iconPath(flow.iconName) : ""
|
||||
fallbackIcon: "lock"
|
||||
borderWidth: 0
|
||||
}
|
||||
|
||||
ColumnLayout {
|
||||
Layout.fillWidth: true
|
||||
spacing: Style.marginXS
|
||||
|
||||
NText {
|
||||
text: flow ? flow.message : (pluginApi ? pluginApi.tr("window.title") : "Authentication Required")
|
||||
pointSize: Style.fontSizeL
|
||||
font.weight: Style.fontWeightBold
|
||||
color: Color.mOnSurface
|
||||
wrapMode: Text.Wrap
|
||||
Layout.fillWidth: true
|
||||
}
|
||||
|
||||
NText {
|
||||
text: flow ? flow.actionId : ""
|
||||
pointSize: Style.fontSizeXS
|
||||
color: Color.mOnSurfaceVariant
|
||||
wrapMode: Text.Wrap
|
||||
Layout.fillWidth: true
|
||||
visible: text !== ""
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Supplementary Message (Error or prompt)
|
||||
NText {
|
||||
visible: flow && flow.supplementaryMessage !== ""
|
||||
text: flow ? flow.supplementaryMessage : ""
|
||||
pointSize: Style.fontSizeS
|
||||
color: (flow && flow.supplementaryIsError) ? Color.mError : Color.mOnSurfaceVariant
|
||||
wrapMode: Text.Wrap
|
||||
Layout.fillWidth: true
|
||||
}
|
||||
|
||||
// Input Field
|
||||
NTextInput {
|
||||
id: passwordInput
|
||||
Layout.fillWidth: true
|
||||
placeholderText: flow ? flow.inputPrompt : (pluginApi ? pluginApi.tr("prompt.password") : "Password")
|
||||
label: (flow && flow.isResponseRequired) ? (pluginApi ? pluginApi.tr("prompt.password") : "Password") : ""
|
||||
inputItem.echoMode: (flow && !flow.responseVisible) ? TextInput.Password : TextInput.Normal
|
||||
visible: flow && flow.isResponseRequired
|
||||
|
||||
onAccepted: {
|
||||
if (flow) {
|
||||
flow.submit(passwordInput.text)
|
||||
passwordInput.text = ""
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Actions
|
||||
RowLayout {
|
||||
Layout.fillWidth: true
|
||||
Layout.topMargin: Style.marginS
|
||||
spacing: Style.marginM
|
||||
|
||||
Item { Layout.fillWidth: true } // Spacer
|
||||
|
||||
NButton {
|
||||
text: pluginApi ? pluginApi.tr("action.cancel") : "Cancel"
|
||||
backgroundColor: Color.mSurfaceVariant
|
||||
textColor: Color.mOnSurfaceVariant
|
||||
outlined: false
|
||||
onClicked: {
|
||||
if (flow) flow.cancelAuthenticationRequest()
|
||||
}
|
||||
}
|
||||
|
||||
NButton {
|
||||
text: pluginApi ? pluginApi.tr("action.authenticate") : "Authenticate"
|
||||
backgroundColor: Color.mPrimary
|
||||
textColor: Color.mOnPrimary
|
||||
enabled: flow && flow.isResponseRequired
|
||||
onClicked: {
|
||||
if (flow) {
|
||||
flow.submit(passwordInput.text)
|
||||
passwordInput.text = ""
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Focus handling
|
||||
Component.onCompleted: {
|
||||
passwordInput.inputItem.forceActiveFocus()
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
# Polkit Agent
|
||||
|
||||
This plugin provides a Polkit authentication agent for Noctalia. It allows you to authenticate actions that require elevated privileges directly within the shell.
|
||||
|
||||

|
||||
|
||||
## Important
|
||||
|
||||
To use this plugin, you **must disable or uninstall your existing polkit authentication agent** (e.g., `polkit-gnome`, `polkit-kde-agent`, `lxpolkit`, etc).
|
||||
|
||||
Having multiple polkit agents running simultaneously will cause conflicts and prevent this plugin from working correctly.
|
||||
|
||||
> You may need to **restart your session or computer** after enabling this plugin for the changes to take effect and for the new agent to be registered properly.
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"window": {
|
||||
"title": "Authentifizierung erforderlich"
|
||||
},
|
||||
"prompt": {
|
||||
"password": "Passwort"
|
||||
},
|
||||
"action": {
|
||||
"cancel": "Abbrechen",
|
||||
"authenticate": "Authentifizieren"
|
||||
},
|
||||
"error": {
|
||||
"failed": {
|
||||
"title": "Authentifizierung fehlgeschlagen",
|
||||
"message": "Das eingegebene Passwort war falsch."
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"window": {
|
||||
"title": "Authentication Required"
|
||||
},
|
||||
"prompt": {
|
||||
"password": "Password"
|
||||
},
|
||||
"action": {
|
||||
"cancel": "Cancel",
|
||||
"authenticate": "Authenticate"
|
||||
},
|
||||
"error": {
|
||||
"failed": {
|
||||
"title": "Authentication Failed",
|
||||
"message": "The password you entered was incorrect."
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"window": {
|
||||
"title": "Autenticación requerida"
|
||||
},
|
||||
"prompt": {
|
||||
"password": "Contraseña"
|
||||
},
|
||||
"action": {
|
||||
"cancel": "Cancelar",
|
||||
"authenticate": "Autenticar"
|
||||
},
|
||||
"error": {
|
||||
"failed": {
|
||||
"title": "Autenticación fallida",
|
||||
"message": "La contraseña introducida es incorrecta."
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"window": {
|
||||
"title": "Authentification requise"
|
||||
},
|
||||
"prompt": {
|
||||
"password": "Mot de passe"
|
||||
},
|
||||
"action": {
|
||||
"cancel": "Annuler",
|
||||
"authenticate": "S'authentifier"
|
||||
},
|
||||
"error": {
|
||||
"failed": {
|
||||
"title": "Authentification échouée",
|
||||
"message": "Le mot de passe saisi est incorrect."
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"window": {
|
||||
"title": "Hitelesítés szükséges"
|
||||
},
|
||||
"prompt": {
|
||||
"password": "Jelszó"
|
||||
},
|
||||
"action": {
|
||||
"cancel": "Mégse",
|
||||
"authenticate": "Hitelesítés"
|
||||
},
|
||||
"error": {
|
||||
"failed": {
|
||||
"title": "Hitelesítés sikertelen",
|
||||
"message": "A megadott jelszó helytelen volt."
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"window": {
|
||||
"title": "認証が必要です"
|
||||
},
|
||||
"prompt": {
|
||||
"password": "パスワード"
|
||||
},
|
||||
"action": {
|
||||
"cancel": "キャンセル",
|
||||
"authenticate": "認証"
|
||||
},
|
||||
"error": {
|
||||
"failed": {
|
||||
"title": "認証に失敗しました",
|
||||
"message": "入力されたパスワードが正しくありません。"
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"window": {
|
||||
"title": "인증 필요"
|
||||
},
|
||||
"prompt": {
|
||||
"password": "비밀번호"
|
||||
},
|
||||
"action": {
|
||||
"cancel": "취소",
|
||||
"authenticate": "인증"
|
||||
},
|
||||
"error": {
|
||||
"failed": {
|
||||
"title": "인증 실패",
|
||||
"message": "입력한 비밀번호가 올바르지 않습니다."
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"window": {
|
||||
"title": "Nasname pêwîst e"
|
||||
},
|
||||
"prompt": {
|
||||
"password": "Şîfre"
|
||||
},
|
||||
"action": {
|
||||
"cancel": "Betal bike",
|
||||
"authenticate": "Nasnameyê bipesend bike"
|
||||
},
|
||||
"error": {
|
||||
"failed": {
|
||||
"title": "Nasname têk çû",
|
||||
"message": "Şîfreya ku hûn nivîsandin şaş e."
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"window": {
|
||||
"title": "Authenticatie vereist"
|
||||
},
|
||||
"prompt": {
|
||||
"password": "Wachtwoord"
|
||||
},
|
||||
"action": {
|
||||
"cancel": "Annuleren",
|
||||
"authenticate": "Authenticeren"
|
||||
},
|
||||
"error": {
|
||||
"failed": {
|
||||
"title": "Authenticatie mislukt",
|
||||
"message": "Het ingevoerde wachtwoord was onjuist."
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"window": {
|
||||
"title": "Autentisering kreves"
|
||||
},
|
||||
"prompt": {
|
||||
"password": "Passord"
|
||||
},
|
||||
"action": {
|
||||
"cancel": "Avbryt",
|
||||
"authenticate": "Autentiser"
|
||||
},
|
||||
"error": {
|
||||
"failed": {
|
||||
"title": "Autentisering mislyktes",
|
||||
"message": "Passordet du skrev inn var feil."
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"window": {
|
||||
"title": "Autentisering krevst"
|
||||
},
|
||||
"prompt": {
|
||||
"password": "Passord"
|
||||
},
|
||||
"action": {
|
||||
"cancel": "Avbryt",
|
||||
"authenticate": "Autentiser"
|
||||
},
|
||||
"error": {
|
||||
"failed": {
|
||||
"title": "Autentisering mislukkast",
|
||||
"message": "Passordet du skreiv inn var feil."
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"window": {
|
||||
"title": "Wymagane uwierzytelnienie"
|
||||
},
|
||||
"prompt": {
|
||||
"password": "Hasło"
|
||||
},
|
||||
"action": {
|
||||
"cancel": "Anuluj",
|
||||
"authenticate": "Uwierzytelnij"
|
||||
},
|
||||
"error": {
|
||||
"failed": {
|
||||
"title": "Uwierzytelnienie nie powiodło się",
|
||||
"message": "Wprowadzone hasło jest nieprawidłowe."
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"window": {
|
||||
"title": "Autenticação Necessária"
|
||||
},
|
||||
"prompt": {
|
||||
"password": "Senha"
|
||||
},
|
||||
"action": {
|
||||
"cancel": "Cancelar",
|
||||
"authenticate": "Autenticar"
|
||||
},
|
||||
"error": {
|
||||
"failed": {
|
||||
"title": "Autenticação Falhou",
|
||||
"message": "A senha introduzida está incorreta."
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"window": {
|
||||
"title": "Требуется аутентификация"
|
||||
},
|
||||
"prompt": {
|
||||
"password": "Пароль"
|
||||
},
|
||||
"action": {
|
||||
"cancel": "Отмена",
|
||||
"authenticate": "Аутентифицировать"
|
||||
},
|
||||
"error": {
|
||||
"failed": {
|
||||
"title": "Ошибка аутентификации",
|
||||
"message": "Введен неверный пароль."
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"window": {
|
||||
"title": "Autentisering krävs"
|
||||
},
|
||||
"prompt": {
|
||||
"password": "Lösenord"
|
||||
},
|
||||
"action": {
|
||||
"cancel": "Avbryt",
|
||||
"authenticate": "Autentisera"
|
||||
},
|
||||
"error": {
|
||||
"failed": {
|
||||
"title": "Autentisering misslyckades",
|
||||
"message": "Det angivna lösenordet var felaktigt."
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"window": {
|
||||
"title": "Kimlik Doğrulaması Gerekli"
|
||||
},
|
||||
"prompt": {
|
||||
"password": "Parola"
|
||||
},
|
||||
"action": {
|
||||
"cancel": "İptal",
|
||||
"authenticate": "Doğrula"
|
||||
},
|
||||
"error": {
|
||||
"failed": {
|
||||
"title": "Kimlik Doğrulama Başarısız",
|
||||
"message": "Girdiğiniz parola yanlış."
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"window": {
|
||||
"title": "Потрібна аутентифікація"
|
||||
},
|
||||
"prompt": {
|
||||
"password": "Пароль"
|
||||
},
|
||||
"action": {
|
||||
"cancel": "Скасувати",
|
||||
"authenticate": "Аутентифікувати"
|
||||
},
|
||||
"error": {
|
||||
"failed": {
|
||||
"title": "Помилка аутентифікації",
|
||||
"message": "Введений пароль неправильний."
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"window": {
|
||||
"title": "Yêu cầu xác thực"
|
||||
},
|
||||
"prompt": {
|
||||
"password": "Mật khẩu"
|
||||
},
|
||||
"action": {
|
||||
"cancel": "Hủy",
|
||||
"authenticate": "Xác thực"
|
||||
},
|
||||
"error": {
|
||||
"failed": {
|
||||
"title": "Xác thực thất bại",
|
||||
"message": "Mật khẩu bạn nhập không đúng."
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"window": {
|
||||
"title": "需要身份验证"
|
||||
},
|
||||
"prompt": {
|
||||
"password": "密码"
|
||||
},
|
||||
"action": {
|
||||
"cancel": "取消",
|
||||
"authenticate": "验证"
|
||||
},
|
||||
"error": {
|
||||
"failed": {
|
||||
"title": "身份验证失败",
|
||||
"message": "您输入的密码不正确。"
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"window": {
|
||||
"title": "需要身份驗證"
|
||||
},
|
||||
"prompt": {
|
||||
"password": "密碼"
|
||||
},
|
||||
"action": {
|
||||
"cancel": "取消",
|
||||
"authenticate": "驗證"
|
||||
},
|
||||
"error": {
|
||||
"failed": {
|
||||
"title": "身份驗證失敗",
|
||||
"message": "您輸入的密碼不正確。"
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,24 @@
|
||||
{
|
||||
"id": "polkit-agent",
|
||||
"name": "Polkit Agent",
|
||||
"version": "1.0.6",
|
||||
"minNoctaliaVersion": "4.4.3",
|
||||
"author": "Noctalia Team <team@noctalia.dev>",
|
||||
"official": true,
|
||||
"license": "MIT",
|
||||
"repository": "https://github.com/noctalia-dev/noctalia-plugins",
|
||||
"description": "Provides a Polkit authentication agent.",
|
||||
"tags": [
|
||||
"System",
|
||||
"Security"
|
||||
],
|
||||
"entryPoints": {
|
||||
"main": "Main.qml"
|
||||
},
|
||||
"dependencies": {
|
||||
"plugins": []
|
||||
},
|
||||
"metadata": {
|
||||
"defaultSettings": {}
|
||||
}
|
||||
}
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 69 KiB |
@@ -0,0 +1,703 @@
|
||||
{
|
||||
"appLauncher": {
|
||||
"autoPasteClipboard": false,
|
||||
"clipboardWatchImageCommand": "wl-paste --type image --watch cliphist store",
|
||||
"clipboardWatchTextCommand": "wl-paste --type text --watch cliphist store",
|
||||
"clipboardWrapText": true,
|
||||
"customLaunchPrefix": "",
|
||||
"customLaunchPrefixEnabled": false,
|
||||
"density": "default",
|
||||
"enableClipPreview": true,
|
||||
"enableClipboardChips": true,
|
||||
"enableClipboardHistory": true,
|
||||
"enableClipboardSmartIcons": true,
|
||||
"enableSessionSearch": true,
|
||||
"enableSettingsSearch": true,
|
||||
"enableWindowsSearch": true,
|
||||
"iconMode": "tabler",
|
||||
"ignoreMouseInput": false,
|
||||
"overviewLayer": false,
|
||||
"pinnedApps": [
|
||||
],
|
||||
"position": "center",
|
||||
"screenshotAnnotationTool": "",
|
||||
"showCategories": true,
|
||||
"showIconBackground": false,
|
||||
"sortByMostUsed": true,
|
||||
"terminalCommand": "alacritty -e",
|
||||
"viewMode": "grid"
|
||||
},
|
||||
"audio": {
|
||||
"mprisBlacklist": [
|
||||
],
|
||||
"preferredPlayer": "",
|
||||
"spectrumFrameRate": 30,
|
||||
"spectrumMirrored": true,
|
||||
"visualizerType": "linear",
|
||||
"volumeFeedback": false,
|
||||
"volumeFeedbackSoundFile": "",
|
||||
"volumeOverdrive": false,
|
||||
"volumeStep": 5
|
||||
},
|
||||
"bar": {
|
||||
"autoHideDelay": 500,
|
||||
"autoShowDelay": 150,
|
||||
"backgroundOpacity": 0.93,
|
||||
"barType": "simple",
|
||||
"capsuleColorKey": "none",
|
||||
"capsuleOpacity": 1,
|
||||
"contentPadding": 2,
|
||||
"density": "comfortable",
|
||||
"displayMode": "always_visible",
|
||||
"enableExclusionZoneInset": true,
|
||||
"fontScale": 1,
|
||||
"frameRadius": 12,
|
||||
"frameThickness": 8,
|
||||
"hideOnOverview": false,
|
||||
"marginHorizontal": 4,
|
||||
"marginVertical": 4,
|
||||
"middleClickAction": "none",
|
||||
"middleClickCommand": "",
|
||||
"middleClickFollowMouse": false,
|
||||
"monitors": [
|
||||
],
|
||||
"mouseWheelAction": "none",
|
||||
"mouseWheelWrap": true,
|
||||
"outerCorners": false,
|
||||
"position": "top",
|
||||
"reverseScroll": false,
|
||||
"rightClickAction": "controlCenter",
|
||||
"rightClickCommand": "",
|
||||
"rightClickFollowMouse": true,
|
||||
"screenOverrides": [
|
||||
],
|
||||
"showCapsule": true,
|
||||
"showOnWorkspaceSwitch": true,
|
||||
"showOutline": false,
|
||||
"useSeparateOpacity": false,
|
||||
"widgetSpacing": 6,
|
||||
"widgets": {
|
||||
"center": [
|
||||
{
|
||||
"clockColor": "none",
|
||||
"customFont": "",
|
||||
"formatHorizontal": "HH:mm ddd, MMM dd",
|
||||
"formatVertical": "HH mm - dd MM",
|
||||
"id": "Clock",
|
||||
"tooltipFormat": "HH:mm ddd, MMM dd",
|
||||
"useCustomFont": false
|
||||
}
|
||||
],
|
||||
"left": [
|
||||
{
|
||||
"colorizeSystemIcon": "none",
|
||||
"colorizeSystemText": "none",
|
||||
"customIconPath": "",
|
||||
"enableColorization": false,
|
||||
"icon": "rocket",
|
||||
"iconColor": "none",
|
||||
"id": "Launcher",
|
||||
"useDistroLogo": false
|
||||
},
|
||||
{
|
||||
"compactMode": true,
|
||||
"diskPath": "/",
|
||||
"iconColor": "none",
|
||||
"id": "SystemMonitor",
|
||||
"showCpuCores": false,
|
||||
"showCpuFreq": false,
|
||||
"showCpuTemp": true,
|
||||
"showCpuUsage": true,
|
||||
"showDiskAvailable": false,
|
||||
"showDiskUsage": false,
|
||||
"showDiskUsageAsPercent": false,
|
||||
"showGpuTemp": false,
|
||||
"showLoadAverage": false,
|
||||
"showMemoryAsPercent": false,
|
||||
"showMemoryUsage": true,
|
||||
"showNetworkStats": false,
|
||||
"showSwapUsage": false,
|
||||
"textColor": "none",
|
||||
"useMonospaceFont": true,
|
||||
"usePadding": false
|
||||
},
|
||||
{
|
||||
"compactMode": false,
|
||||
"hideMode": "hidden",
|
||||
"hideWhenIdle": false,
|
||||
"id": "MediaMini",
|
||||
"maxWidth": 145,
|
||||
"panelShowAlbumArt": true,
|
||||
"scrollingMode": "hover",
|
||||
"showAlbumArt": true,
|
||||
"showArtistFirst": true,
|
||||
"showProgressRing": true,
|
||||
"showVisualizer": false,
|
||||
"textColor": "none",
|
||||
"useFixedWidth": false,
|
||||
"visualizerType": "linear"
|
||||
},
|
||||
{
|
||||
"characterCount": 2,
|
||||
"colorizeIcons": false,
|
||||
"emptyColor": "secondary",
|
||||
"enableScrollWheel": true,
|
||||
"focusedColor": "primary",
|
||||
"followFocusedScreen": false,
|
||||
"fontWeight": "bold",
|
||||
"groupedBorderOpacity": 1,
|
||||
"hideUnoccupied": false,
|
||||
"iconScale": 0.8,
|
||||
"id": "Workspace",
|
||||
"labelMode": "index",
|
||||
"occupiedColor": "secondary",
|
||||
"pillSize": 0.6,
|
||||
"showApplications": false,
|
||||
"showApplicationsHover": false,
|
||||
"showBadge": true,
|
||||
"showLabelsOnlyWhenOccupied": true,
|
||||
"unfocusedIconsOpacity": 1
|
||||
},
|
||||
{
|
||||
"colorizeIcons": false,
|
||||
"hideMode": "visible",
|
||||
"id": "ActiveWindow",
|
||||
"maxWidth": 350,
|
||||
"scrollingMode": "hover",
|
||||
"showIcon": true,
|
||||
"showText": true,
|
||||
"textColor": "none",
|
||||
"useFixedWidth": true
|
||||
}
|
||||
],
|
||||
"right": [
|
||||
{
|
||||
"blacklist": [
|
||||
],
|
||||
"chevronColor": "none",
|
||||
"colorizeIcons": false,
|
||||
"drawerEnabled": false,
|
||||
"hidePassive": false,
|
||||
"id": "Tray",
|
||||
"pinned": [
|
||||
]
|
||||
},
|
||||
{
|
||||
"hideWhenZero": false,
|
||||
"hideWhenZeroUnread": false,
|
||||
"iconColor": "none",
|
||||
"id": "NotificationHistory",
|
||||
"showUnreadBadge": true,
|
||||
"unreadBadgeColor": "primary"
|
||||
},
|
||||
{
|
||||
"deviceNativePath": "__default__",
|
||||
"displayMode": "graphic-clean",
|
||||
"hideIfIdle": false,
|
||||
"hideIfNotDetected": true,
|
||||
"id": "Battery",
|
||||
"showNoctaliaPerformance": false,
|
||||
"showPowerProfiles": false
|
||||
},
|
||||
{
|
||||
"displayMode": "onhover",
|
||||
"iconColor": "none",
|
||||
"id": "Volume",
|
||||
"middleClickCommand": "pwvucontrol || pavucontrol",
|
||||
"textColor": "none"
|
||||
},
|
||||
{
|
||||
"applyToAllMonitors": false,
|
||||
"displayMode": "onhover",
|
||||
"iconColor": "none",
|
||||
"id": "Brightness",
|
||||
"textColor": "none"
|
||||
},
|
||||
{
|
||||
"colorizeDistroLogo": false,
|
||||
"colorizeSystemIcon": "none",
|
||||
"colorizeSystemText": "none",
|
||||
"customIconPath": "",
|
||||
"enableColorization": false,
|
||||
"icon": "noctalia",
|
||||
"id": "ControlCenter",
|
||||
"useDistroLogo": false
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"brightness": {
|
||||
"backlightDeviceMappings": [
|
||||
],
|
||||
"brightnessStep": 5,
|
||||
"enableDdcSupport": false,
|
||||
"enforceMinimum": true
|
||||
},
|
||||
"calendar": {
|
||||
"cards": [
|
||||
{
|
||||
"enabled": true,
|
||||
"id": "calendar-header-card"
|
||||
},
|
||||
{
|
||||
"enabled": true,
|
||||
"id": "calendar-month-card"
|
||||
},
|
||||
{
|
||||
"enabled": true,
|
||||
"id": "weather-card"
|
||||
}
|
||||
]
|
||||
},
|
||||
"colorSchemes": {
|
||||
"darkMode": true,
|
||||
"generationMethod": "tonal-spot",
|
||||
"manualSunrise": "06:30",
|
||||
"manualSunset": "18:30",
|
||||
"monitorForColors": "",
|
||||
"predefinedScheme": "Catppuccin",
|
||||
"schedulingMode": "off",
|
||||
"syncGsettings": true,
|
||||
"useWallpaperColors": false
|
||||
},
|
||||
"controlCenter": {
|
||||
"cards": [
|
||||
{
|
||||
"enabled": true,
|
||||
"id": "profile-card"
|
||||
},
|
||||
{
|
||||
"enabled": true,
|
||||
"id": "shortcuts-card"
|
||||
},
|
||||
{
|
||||
"enabled": true,
|
||||
"id": "audio-card"
|
||||
},
|
||||
{
|
||||
"enabled": false,
|
||||
"id": "brightness-card"
|
||||
},
|
||||
{
|
||||
"enabled": true,
|
||||
"id": "weather-card"
|
||||
},
|
||||
{
|
||||
"enabled": true,
|
||||
"id": "media-sysmon-card"
|
||||
}
|
||||
],
|
||||
"diskPath": "/",
|
||||
"position": "close_to_bar_button",
|
||||
"shortcuts": {
|
||||
"left": [
|
||||
{
|
||||
"id": "Network"
|
||||
},
|
||||
{
|
||||
"id": "Bluetooth"
|
||||
},
|
||||
{
|
||||
"id": "WallpaperSelector"
|
||||
},
|
||||
{
|
||||
"id": "NoctaliaPerformance"
|
||||
}
|
||||
],
|
||||
"right": [
|
||||
{
|
||||
"id": "Notifications"
|
||||
},
|
||||
{
|
||||
"id": "PowerProfile"
|
||||
},
|
||||
{
|
||||
"id": "KeepAwake"
|
||||
},
|
||||
{
|
||||
"id": "NightLight"
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"desktopWidgets": {
|
||||
"enabled": false,
|
||||
"gridSnap": false,
|
||||
"gridSnapScale": false,
|
||||
"monitorWidgets": [
|
||||
],
|
||||
"overviewEnabled": true
|
||||
},
|
||||
"dock": {
|
||||
"animationSpeed": 1,
|
||||
"backgroundOpacity": 1,
|
||||
"colorizeIcons": false,
|
||||
"deadOpacity": 0.6,
|
||||
"displayMode": "auto_hide",
|
||||
"dockType": "attached",
|
||||
"enabled": true,
|
||||
"floatingRatio": 1,
|
||||
"groupApps": false,
|
||||
"groupClickAction": "cycle",
|
||||
"groupContextMenuMode": "extended",
|
||||
"groupIndicatorStyle": "dots",
|
||||
"inactiveIndicators": false,
|
||||
"indicatorColor": "primary",
|
||||
"indicatorOpacity": 0.6,
|
||||
"indicatorThickness": 3,
|
||||
"launcherIcon": "",
|
||||
"launcherIconColor": "none",
|
||||
"launcherPosition": "end",
|
||||
"launcherUseDistroLogo": false,
|
||||
"monitors": [
|
||||
],
|
||||
"onlySameOutput": true,
|
||||
"pinnedApps": [
|
||||
],
|
||||
"pinnedStatic": false,
|
||||
"position": "bottom",
|
||||
"showDockIndicator": true,
|
||||
"showLauncherIcon": false,
|
||||
"sitOnFrame": false,
|
||||
"size": 1
|
||||
},
|
||||
"general": {
|
||||
"allowPanelsOnScreenWithoutBar": true,
|
||||
"allowPasswordWithFprintd": false,
|
||||
"animationDisabled": false,
|
||||
"animationSpeed": 1,
|
||||
"autoStartAuth": false,
|
||||
"avatarImage": "/home/bgrolleman/.face",
|
||||
"boxRadiusRatio": 1,
|
||||
"clockFormat": "hh\\nmm",
|
||||
"clockStyle": "custom",
|
||||
"compactLockScreen": false,
|
||||
"dimmerOpacity": 0.2,
|
||||
"enableBlurBehind": true,
|
||||
"enableLockScreenCountdown": true,
|
||||
"enableLockScreenMediaControls": false,
|
||||
"enableShadows": true,
|
||||
"forceBlackScreenCorners": false,
|
||||
"iRadiusRatio": 1,
|
||||
"keybinds": {
|
||||
"keyDown": [
|
||||
"Down"
|
||||
],
|
||||
"keyEnter": [
|
||||
"Return",
|
||||
"Enter"
|
||||
],
|
||||
"keyEscape": [
|
||||
"Esc"
|
||||
],
|
||||
"keyLeft": [
|
||||
"Left"
|
||||
],
|
||||
"keyRemove": [
|
||||
"Del"
|
||||
],
|
||||
"keyRight": [
|
||||
"Right"
|
||||
],
|
||||
"keyUp": [
|
||||
"Up"
|
||||
]
|
||||
},
|
||||
"language": "",
|
||||
"lockOnSuspend": true,
|
||||
"lockScreenAnimations": false,
|
||||
"lockScreenBlur": 0,
|
||||
"lockScreenCountdownDuration": 10000,
|
||||
"lockScreenMonitors": [
|
||||
],
|
||||
"lockScreenTint": 0,
|
||||
"passwordChars": false,
|
||||
"radiusRatio": 1,
|
||||
"reverseScroll": false,
|
||||
"scaleRatio": 1,
|
||||
"screenRadiusRatio": 1,
|
||||
"shadowDirection": "bottom_right",
|
||||
"shadowOffsetX": 2,
|
||||
"shadowOffsetY": 3,
|
||||
"showChangelogOnStartup": true,
|
||||
"showHibernateOnLockScreen": false,
|
||||
"showScreenCorners": false,
|
||||
"showSessionButtonsOnLockScreen": true,
|
||||
"smoothScrollEnabled": true,
|
||||
"telemetryEnabled": true
|
||||
},
|
||||
"hooks": {
|
||||
"colorGeneration": "",
|
||||
"darkModeChange": "",
|
||||
"enabled": false,
|
||||
"performanceModeDisabled": "",
|
||||
"performanceModeEnabled": "",
|
||||
"screenLock": "",
|
||||
"screenUnlock": "",
|
||||
"session": "",
|
||||
"startup": "",
|
||||
"wallpaperChange": ""
|
||||
},
|
||||
"idle": {
|
||||
"customCommands": "[]",
|
||||
"enabled": false,
|
||||
"fadeDuration": 5,
|
||||
"lockCommand": "",
|
||||
"lockTimeout": 660,
|
||||
"resumeLockCommand": "",
|
||||
"resumeScreenOffCommand": "",
|
||||
"resumeSuspendCommand": "",
|
||||
"screenOffCommand": "",
|
||||
"screenOffTimeout": 600,
|
||||
"suspendCommand": "",
|
||||
"suspendTimeout": 1800
|
||||
},
|
||||
"location": {
|
||||
"analogClockInCalendar": false,
|
||||
"autoLocate": false,
|
||||
"firstDayOfWeek": 1,
|
||||
"hideWeatherCityName": false,
|
||||
"hideWeatherTimezone": false,
|
||||
"name": "Amersfoort, The Netherlandsk",
|
||||
"showCalendarEvents": true,
|
||||
"showCalendarWeather": true,
|
||||
"showWeekNumberInCalendar": false,
|
||||
"use12hourFormat": false,
|
||||
"useFahrenheit": false,
|
||||
"weatherEnabled": true,
|
||||
"weatherShowEffects": true,
|
||||
"weatherTaliaMascotAlways": false
|
||||
},
|
||||
"network": {
|
||||
"bluetoothAutoConnect": true,
|
||||
"bluetoothDetailsViewMode": "grid",
|
||||
"bluetoothHideUnnamedDevices": false,
|
||||
"bluetoothRssiPollIntervalMs": 60000,
|
||||
"bluetoothRssiPollingEnabled": false,
|
||||
"disableDiscoverability": false,
|
||||
"networkPanelView": "wifi",
|
||||
"wifiDetailsViewMode": "grid"
|
||||
},
|
||||
"nightLight": {
|
||||
"autoSchedule": true,
|
||||
"dayTemp": "6500",
|
||||
"enabled": false,
|
||||
"forced": false,
|
||||
"manualSunrise": "06:30",
|
||||
"manualSunset": "18:30",
|
||||
"nightTemp": "4000"
|
||||
},
|
||||
"noctaliaPerformance": {
|
||||
"disableDesktopWidgets": true,
|
||||
"disableWallpaper": true
|
||||
},
|
||||
"notifications": {
|
||||
"backgroundOpacity": 1,
|
||||
"clearDismissed": true,
|
||||
"criticalUrgencyDuration": 15,
|
||||
"density": "default",
|
||||
"enableBatteryToast": true,
|
||||
"enableKeyboardLayoutToast": true,
|
||||
"enableMarkdown": false,
|
||||
"enableMediaToast": false,
|
||||
"enabled": true,
|
||||
"location": "top_right",
|
||||
"lowUrgencyDuration": 3,
|
||||
"monitors": [
|
||||
],
|
||||
"normalUrgencyDuration": 8,
|
||||
"overlayLayer": true,
|
||||
"respectExpireTimeout": false,
|
||||
"saveToHistory": {
|
||||
"critical": true,
|
||||
"low": false,
|
||||
"normal": true
|
||||
},
|
||||
"sounds": {
|
||||
"criticalSoundFile": "",
|
||||
"enabled": false,
|
||||
"excludedApps": "discord,firefox,chrome,chromium,edge",
|
||||
"lowSoundFile": "",
|
||||
"normalSoundFile": "",
|
||||
"separateSounds": false,
|
||||
"volume": 0.5
|
||||
}
|
||||
},
|
||||
"osd": {
|
||||
"autoHideMs": 2000,
|
||||
"backgroundOpacity": 1,
|
||||
"enabled": true,
|
||||
"enabledTypes": [
|
||||
0,
|
||||
1,
|
||||
2
|
||||
],
|
||||
"location": "top_right",
|
||||
"monitors": [
|
||||
],
|
||||
"overlayLayer": true
|
||||
},
|
||||
"plugins": {
|
||||
"autoUpdate": false,
|
||||
"notifyUpdates": true
|
||||
},
|
||||
"sessionMenu": {
|
||||
"countdownDuration": 10000,
|
||||
"enableCountdown": true,
|
||||
"largeButtonsLayout": "single-row",
|
||||
"largeButtonsStyle": true,
|
||||
"position": "center",
|
||||
"powerOptions": [
|
||||
{
|
||||
"action": "lock",
|
||||
"command": "",
|
||||
"countdownEnabled": true,
|
||||
"enabled": true,
|
||||
"keybind": "1"
|
||||
},
|
||||
{
|
||||
"action": "suspend",
|
||||
"command": "",
|
||||
"countdownEnabled": true,
|
||||
"enabled": true,
|
||||
"keybind": "2"
|
||||
},
|
||||
{
|
||||
"action": "hibernate",
|
||||
"command": "",
|
||||
"countdownEnabled": true,
|
||||
"enabled": true,
|
||||
"keybind": "3"
|
||||
},
|
||||
{
|
||||
"action": "reboot",
|
||||
"command": "",
|
||||
"countdownEnabled": true,
|
||||
"enabled": true,
|
||||
"keybind": "4"
|
||||
},
|
||||
{
|
||||
"action": "logout",
|
||||
"command": "",
|
||||
"countdownEnabled": true,
|
||||
"enabled": true,
|
||||
"keybind": "5"
|
||||
},
|
||||
{
|
||||
"action": "shutdown",
|
||||
"command": "",
|
||||
"countdownEnabled": true,
|
||||
"enabled": true,
|
||||
"keybind": "6"
|
||||
},
|
||||
{
|
||||
"action": "rebootToUefi",
|
||||
"command": "",
|
||||
"countdownEnabled": true,
|
||||
"enabled": true,
|
||||
"keybind": "7"
|
||||
},
|
||||
{
|
||||
"action": "userspaceReboot",
|
||||
"command": "",
|
||||
"countdownEnabled": true,
|
||||
"enabled": false,
|
||||
"keybind": ""
|
||||
}
|
||||
],
|
||||
"showHeader": true,
|
||||
"showKeybinds": true
|
||||
},
|
||||
"settingsVersion": 59,
|
||||
"systemMonitor": {
|
||||
"batteryCriticalThreshold": 5,
|
||||
"batteryWarningThreshold": 20,
|
||||
"cpuCriticalThreshold": 90,
|
||||
"cpuWarningThreshold": 80,
|
||||
"criticalColor": "",
|
||||
"diskAvailCriticalThreshold": 10,
|
||||
"diskAvailWarningThreshold": 20,
|
||||
"diskCriticalThreshold": 90,
|
||||
"diskWarningThreshold": 80,
|
||||
"enableDgpuMonitoring": false,
|
||||
"externalMonitor": "resources || missioncenter || jdsystemmonitor || corestats || system-monitoring-center || gnome-system-monitor || plasma-systemmonitor || mate-system-monitor || ukui-system-monitor || deepin-system-monitor || pantheon-system-monitor",
|
||||
"gpuCriticalThreshold": 90,
|
||||
"gpuWarningThreshold": 80,
|
||||
"memCriticalThreshold": 90,
|
||||
"memWarningThreshold": 80,
|
||||
"swapCriticalThreshold": 90,
|
||||
"swapWarningThreshold": 80,
|
||||
"tempCriticalThreshold": 90,
|
||||
"tempWarningThreshold": 80,
|
||||
"useCustomColors": false,
|
||||
"warningColor": ""
|
||||
},
|
||||
"templates": {
|
||||
"activeTemplates": [
|
||||
],
|
||||
"enableUserTheming": false
|
||||
},
|
||||
"ui": {
|
||||
"boxBorderEnabled": false,
|
||||
"fontDefault": "Adwaita Sans",
|
||||
"fontDefaultScale": 1,
|
||||
"fontFixed": "monospace",
|
||||
"fontFixedScale": 1,
|
||||
"panelBackgroundOpacity": 0.93,
|
||||
"panelsAttachedToBar": true,
|
||||
"scrollbarAlwaysVisible": true,
|
||||
"settingsPanelMode": "attached",
|
||||
"settingsPanelSideBarCardStyle": false,
|
||||
"tooltipsEnabled": true,
|
||||
"translucentWidgets": false
|
||||
},
|
||||
"wallpaper": {
|
||||
"automationEnabled": false,
|
||||
"directory": "/home/bgrolleman/Documents/Resources/Backgrounds",
|
||||
"enableMultiMonitorDirectories": false,
|
||||
"enabled": true,
|
||||
"favorites": [
|
||||
],
|
||||
"fillColor": "#000000",
|
||||
"fillMode": "crop",
|
||||
"hideWallpaperFilenames": false,
|
||||
"linkLightAndDarkWallpapers": true,
|
||||
"monitorDirectories": [
|
||||
],
|
||||
"overviewBlur": 0.4,
|
||||
"overviewEnabled": false,
|
||||
"overviewTint": 0.6,
|
||||
"panelPosition": "follow_bar",
|
||||
"randomIntervalSec": 300,
|
||||
"setWallpaperOnAllMonitors": true,
|
||||
"showHiddenFiles": false,
|
||||
"skipStartupTransition": false,
|
||||
"solidColor": "#1a1a2e",
|
||||
"sortOrder": "name",
|
||||
"transitionDuration": 1500,
|
||||
"transitionEdgeSmoothness": 0.05,
|
||||
"transitionType": [
|
||||
"fade",
|
||||
"disc",
|
||||
"stripes",
|
||||
"wipe",
|
||||
"pixelate",
|
||||
"honeycomb"
|
||||
],
|
||||
"useOriginalImages": false,
|
||||
"useSolidColor": false,
|
||||
"useWallhaven": false,
|
||||
"viewMode": "single",
|
||||
"wallhavenApiKey": "",
|
||||
"wallhavenCategories": "111",
|
||||
"wallhavenOrder": "desc",
|
||||
"wallhavenPurity": "100",
|
||||
"wallhavenQuery": "",
|
||||
"wallhavenRatios": "",
|
||||
"wallhavenResolutionHeight": "",
|
||||
"wallhavenResolutionMode": "atleast",
|
||||
"wallhavenResolutionWidth": "",
|
||||
"wallhavenSorting": "relevance",
|
||||
"wallpaperChangeMode": "random"
|
||||
}
|
||||
}
|
||||
@@ -1,24 +0,0 @@
|
||||
local rocks_config = {
|
||||
rocks_path = vim.env.HOME .. "/.local/share/nvim/rocks",
|
||||
}
|
||||
|
||||
vim.g.rocks_nvim = rocks_config
|
||||
|
||||
local luarocks_path = {
|
||||
vim.fs.joinpath(rocks_config.rocks_path, "share", "lua", "5.1", "?.lua"),
|
||||
vim.fs.joinpath(rocks_config.rocks_path, "share", "lua", "5.1", "?", "init.lua"),
|
||||
}
|
||||
package.path = package.path .. ";" .. table.concat(luarocks_path, ";")
|
||||
|
||||
local luarocks_cpath = {
|
||||
vim.fs.joinpath(rocks_config.rocks_path, "lib", "lua", "5.1", "?.so"),
|
||||
vim.fs.joinpath(rocks_config.rocks_path, "lib64", "lua", "5.1", "?.so"),
|
||||
-- Remove the dylib and dll paths if you do not need macos or windows support
|
||||
vim.fs.joinpath(rocks_config.rocks_path, "lib", "lua", "5.1", "?.dylib"),
|
||||
vim.fs.joinpath(rocks_config.rocks_path, "lib64", "lua", "5.1", "?.dylib"),
|
||||
vim.fs.joinpath(rocks_config.rocks_path, "lib", "lua", "5.1", "?.dll"),
|
||||
vim.fs.joinpath(rocks_config.rocks_path, "lib64", "lua", "5.1", "?.dll"),
|
||||
}
|
||||
package.cpath = package.cpath .. ";" .. table.concat(luarocks_cpath, ";")
|
||||
|
||||
vim.opt.runtimepath:append(vim.fs.joinpath(rocks_config.rocks_path, "lib", "luarocks", "rocks-5.1", "rocks.nvim", "*"))
|
||||
@@ -1,355 +0,0 @@
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" => General
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
set mouse=a
|
||||
" Sets how many lines of history VIM has to remember
|
||||
set history=500
|
||||
|
||||
" Enable filetype plugins
|
||||
filetype plugin on
|
||||
filetype indent on
|
||||
|
||||
" Set to auto read when a file is changed from the outside
|
||||
set autoread
|
||||
au FocusGained,BufEnter * checktime
|
||||
|
||||
" With a map leader it's possible to do extra key combinations
|
||||
" like <leader>w saves the current file
|
||||
let mapleader = ","
|
||||
|
||||
" Fast saving
|
||||
nmap <leader>s :w!<cr>
|
||||
|
||||
" :W sudo saves the file
|
||||
" (useful for handling the permission-denied error)
|
||||
command! W execute 'w !sudo tee % > /dev/null' <bar> edit!
|
||||
|
||||
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" => VIM user interface
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" Set 7 lines to the cursor - when moving vertically using j/k
|
||||
set so=7
|
||||
|
||||
" Avoid garbled characters in Chinese language windows OS
|
||||
let $LANG='en'
|
||||
set langmenu=en
|
||||
source $VIMRUNTIME/delmenu.vim
|
||||
source $VIMRUNTIME/menu.vim
|
||||
|
||||
" Turn on the Wild menu
|
||||
set wildmenu
|
||||
|
||||
" Ignore compiled files
|
||||
set wildignore=*.o,*~,*.pyc
|
||||
if has("win16") || has("win32")
|
||||
set wildignore+=.git\*,.hg\*,.svn\*
|
||||
else
|
||||
set wildignore+=*/.git/*,*/.hg/*,*/.svn/*,*/.DS_Store
|
||||
endif
|
||||
|
||||
"Always show current position
|
||||
set ruler
|
||||
|
||||
" Height of the command bar
|
||||
set cmdheight=1
|
||||
|
||||
" A buffer becomes hidden when it is abandoned
|
||||
set hid
|
||||
|
||||
" Configure backspace so it acts as it should act
|
||||
set backspace=eol,start,indent
|
||||
set whichwrap+=<,>,h,l
|
||||
|
||||
" Ignore case when searching
|
||||
set ignorecase
|
||||
|
||||
" When searching try to be smart about cases
|
||||
set smartcase
|
||||
|
||||
" Highlight search results
|
||||
set hlsearch
|
||||
|
||||
" Makes search act like search in modern browsers
|
||||
set incsearch
|
||||
|
||||
" Don't redraw while executing macros (good performance config)
|
||||
set lazyredraw
|
||||
|
||||
" For regular expressions turn magic on
|
||||
set magic
|
||||
|
||||
" Show matching brackets when text indicator is over them
|
||||
set showmatch
|
||||
" How many tenths of a second to blink when matching brackets
|
||||
set mat=2
|
||||
|
||||
" No annoying sound on errors
|
||||
set noerrorbells
|
||||
set novisualbell
|
||||
set t_vb=
|
||||
set tm=500
|
||||
|
||||
" Properly disable sound on errors on MacVim
|
||||
if has("gui_macvim")
|
||||
autocmd GUIEnter * set vb t_vb=
|
||||
endif
|
||||
|
||||
|
||||
" Add a bit extra margin to the left
|
||||
set foldcolumn=1
|
||||
|
||||
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" => Colors and Fonts
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" Enable syntax highlighting
|
||||
syntax enable
|
||||
|
||||
" Enable 256 colors palette in Gnome Terminal
|
||||
if $COLORTERM == 'gnome-terminal'
|
||||
set t_Co=256
|
||||
endif
|
||||
|
||||
try
|
||||
colorscheme darkelf
|
||||
catch
|
||||
endtry
|
||||
|
||||
set background=dark
|
||||
|
||||
" Set extra options when running in GUI mode
|
||||
if has("gui_running")
|
||||
set guioptions-=T
|
||||
set guioptions-=e
|
||||
set t_Co=256
|
||||
set guitablabel=%M\ %t
|
||||
endif
|
||||
|
||||
" Set utf8 as standard encoding and en_US as the standard language
|
||||
set encoding=utf8
|
||||
|
||||
" Use Unix as the standard file type
|
||||
set ffs=unix,dos,mac
|
||||
|
||||
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" => Files, backups and undo
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" Turn backup off, since most stuff is in SVN, git etc. anyway...
|
||||
set nobackup
|
||||
set nowb
|
||||
set noswapfile
|
||||
|
||||
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" => Text, tab and indent related
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" Use spaces instead of tabs
|
||||
set expandtab
|
||||
|
||||
" Be smart when using tabs ;)
|
||||
set smarttab
|
||||
|
||||
" 1 tab == 4 spaces
|
||||
set shiftwidth=4
|
||||
set tabstop=4
|
||||
|
||||
" Linebreak on 500 characters
|
||||
set lbr
|
||||
set tw=500
|
||||
|
||||
set ai "Auto indent
|
||||
set si "Smart indent
|
||||
set wrap "Wrap lines
|
||||
|
||||
|
||||
""""""""""""""""""""""""""""""
|
||||
" => Visual mode related
|
||||
""""""""""""""""""""""""""""""
|
||||
" Visual mode pressing * or # searches for the current selection
|
||||
" Super useful! From an idea by Michael Naumann
|
||||
vnoremap <silent> * :<C-u>call VisualSelection('', '')<CR>/<C-R>=@/<CR><CR>
|
||||
vnoremap <silent> # :<C-u>call VisualSelection('', '')<CR>?<C-R>=@/<CR><CR>
|
||||
|
||||
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" => Moving around, tabs, windows and buffers
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" Map <Space> to / (search) and Ctrl-<Space> to ? (backwards search)
|
||||
"map <space> /
|
||||
"map <C-space> ?
|
||||
|
||||
" Disable highlight when <leader><cr> is pressed
|
||||
map <silent> <leader><cr> :noh<cr>
|
||||
|
||||
" Smart way to move between windows
|
||||
map <C-j> <C-W>j
|
||||
map <C-k> <C-W>k
|
||||
map <C-h> <C-W>h
|
||||
map <C-l> <C-W>l
|
||||
|
||||
" Close the current buffer
|
||||
map <leader>bd :Bclose<cr>:tabclose<cr>gT
|
||||
|
||||
" Close all the buffers
|
||||
map <leader>ba :bufdo bd<cr>
|
||||
|
||||
map <leader>bl :bnext<cr>
|
||||
map <leader>bh :bprevious<cr>
|
||||
|
||||
" Useful mappings for managing tabs
|
||||
map <leader>tn :tabnew<cr>
|
||||
map <leader>to :tabonly<cr>
|
||||
map <leader>tc :tabclose<cr>
|
||||
map <leader>tm :tabmove
|
||||
map <leader>t<leader> :tabnext
|
||||
|
||||
" Let 'tl' toggle between this and the last accessed tab
|
||||
let g:lasttab = 1
|
||||
nmap <Leader>tl :exe "tabn ".g:lasttab<CR>
|
||||
au TabLeave * let g:lasttab = tabpagenr()
|
||||
|
||||
|
||||
" Opens a new tab with the current buffer's path
|
||||
" Super useful when editing files in the same directory
|
||||
map <leader>te :tabedit <C-r>=expand("%:p:h")<cr>/
|
||||
|
||||
" Switch CWD to the directory of the open buffer
|
||||
map <leader>cd :cd %:p:h<cr>:pwd<cr>
|
||||
|
||||
" Specify the behavior when switching between buffers
|
||||
try
|
||||
set switchbuf=useopen,usetab,newtab
|
||||
set stal=2
|
||||
catch
|
||||
endtry
|
||||
|
||||
" Return to last edit position when opening files (You want this!)
|
||||
au BufReadPost * if line("'\"") > 1 && line("'\"") <= line("$") | exe "normal! g'\"" | endif
|
||||
|
||||
|
||||
""""""""""""""""""""""""""""""
|
||||
" => Status line
|
||||
""""""""""""""""""""""""""""""
|
||||
" Always show the status line
|
||||
set laststatus=2
|
||||
|
||||
" Format the status line
|
||||
set statusline=\ %{HasPaste()}%F%m%r%h\ %w\ \ CWD:\ %r%{getcwd()}%h\ \ \ Line:\ %l\ \ Column:\ %c
|
||||
|
||||
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" => Editing mappings
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" Remap VIM 0 to first non-blank character
|
||||
map 0 ^
|
||||
|
||||
" Move a line of text using ALT+[jk] or Command+[jk] on mac
|
||||
nmap <M-j> mz:m+<cr>`z
|
||||
nmap <M-k> mz:m-2<cr>`z
|
||||
vmap <M-j> :m'>+<cr>`<my`>mzgv`yo`z
|
||||
vmap <M-k> :m'<-2<cr>`>my`<mzgv`yo`z
|
||||
|
||||
if has("mac") || has("macunix")
|
||||
nmap <D-j> <M-j>
|
||||
nmap <D-k> <M-k>
|
||||
vmap <D-j> <M-j>
|
||||
vmap <D-k> <M-k>
|
||||
endif
|
||||
|
||||
" Delete trailing white space on save, useful for some filetypes ;)
|
||||
fun! CleanExtraSpaces()
|
||||
let save_cursor = getpos(".")
|
||||
let old_query = getreg('/')
|
||||
silent! %s/\s\+$//e
|
||||
call setpos('.', save_cursor)
|
||||
call setreg('/', old_query)
|
||||
endfun
|
||||
|
||||
if has("autocmd")
|
||||
autocmd BufWritePre *.txt,*.js,*.py,*.wiki,*.sh,*.coffee :call CleanExtraSpaces()
|
||||
endif
|
||||
|
||||
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" => Spell checking
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" Pressing ,ss will toggle and untoggle spell checking
|
||||
map <leader>ss :setlocal spell!<cr>
|
||||
|
||||
" Shortcuts using <leader>
|
||||
map <leader>sn ]s
|
||||
map <leader>sp [s
|
||||
map <leader>sa zg
|
||||
map <leader>s? z=
|
||||
|
||||
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" => Misc
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" Remove the Windows ^M - when the encodings gets messed up
|
||||
noremap <Leader>m mmHmt:%s/<C-V><cr>//ge<cr>'tzt'm
|
||||
|
||||
" Quickly open a buffer for scribble
|
||||
map <leader>q :e ~/buffer<cr>
|
||||
|
||||
" Quickly open a markdown buffer for scribble
|
||||
map <leader>x :e ~/buffer.md<cr>
|
||||
|
||||
" Toggle paste mode on and off
|
||||
map <leader>pp :setlocal paste!<cr>
|
||||
|
||||
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" => Helper functions
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" Returns true if paste mode is enabled
|
||||
function! HasPaste()
|
||||
if &paste
|
||||
return 'PASTE MODE '
|
||||
endif
|
||||
return ''
|
||||
endfunction
|
||||
|
||||
" Don't close window, when deleting a buffer
|
||||
command! Bclose call <SID>BufcloseCloseIt()
|
||||
function! <SID>BufcloseCloseIt()
|
||||
let l:currentBufNum = bufnr("%")
|
||||
let l:alternateBufNum = bufnr("#")
|
||||
|
||||
if buflisted(l:alternateBufNum)
|
||||
buffer #
|
||||
else
|
||||
bnext
|
||||
endif
|
||||
|
||||
if bufnr("%") == l:currentBufNum
|
||||
new
|
||||
endif
|
||||
|
||||
if buflisted(l:currentBufNum)
|
||||
execute("bdelete! ".l:currentBufNum)
|
||||
endif
|
||||
endfunction
|
||||
|
||||
function! CmdLine(str)
|
||||
call feedkeys(":" . a:str)
|
||||
endfunction
|
||||
|
||||
function! VisualSelection(direction, extra_filter) range
|
||||
let l:saved_reg = @"
|
||||
execute "normal! vgvy"
|
||||
|
||||
let l:pattern = escape(@", "\\/.*'$^~[]")
|
||||
let l:pattern = substitute(l:pattern, "\n$", "", "")
|
||||
|
||||
if a:direction == 'gv'
|
||||
call CmdLine("Ack '" . l:pattern . "' " )
|
||||
elseif a:direction == 'replace'
|
||||
call CmdLine("%s" . '/'. l:pattern . '/')
|
||||
endif
|
||||
|
||||
let @/ = l:pattern
|
||||
let @" = l:saved_reg
|
||||
endfunction
|
||||
@@ -1,357 +0,0 @@
|
||||
lua require('config.lazy')
|
||||
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" => General
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
set mouse=a
|
||||
" Sets how many lines of history VIM has to remember
|
||||
set history=500
|
||||
|
||||
" Enable filetype plugins
|
||||
filetype plugin on
|
||||
filetype indent on
|
||||
|
||||
" Set to auto read when a file is changed from the outside
|
||||
set autoread
|
||||
au FocusGained,BufEnter * checktime
|
||||
|
||||
" With a map leader it's possible to do extra key combinations
|
||||
" like <leader>w saves the current file
|
||||
let mapleader = ","
|
||||
|
||||
" Fast saving
|
||||
nmap <leader>s :w!<cr>
|
||||
|
||||
" :W sudo saves the file
|
||||
" (useful for handling the permission-denied error)
|
||||
command! W execute 'w !sudo tee % > /dev/null' <bar> edit!
|
||||
|
||||
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" => VIM user interface
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" Set 7 lines to the cursor - when moving vertically using j/k
|
||||
set so=7
|
||||
|
||||
" Avoid garbled characters in Chinese language windows OS
|
||||
let $LANG='en'
|
||||
set langmenu=en
|
||||
source $VIMRUNTIME/delmenu.vim
|
||||
source $VIMRUNTIME/menu.vim
|
||||
|
||||
" Turn on the Wild menu
|
||||
set wildmenu
|
||||
|
||||
" Ignore compiled files
|
||||
set wildignore=*.o,*~,*.pyc
|
||||
if has("win16") || has("win32")
|
||||
set wildignore+=.git\*,.hg\*,.svn\*
|
||||
else
|
||||
set wildignore+=*/.git/*,*/.hg/*,*/.svn/*,*/.DS_Store
|
||||
endif
|
||||
|
||||
"Always show current position
|
||||
set ruler
|
||||
|
||||
" Height of the command bar
|
||||
set cmdheight=1
|
||||
|
||||
" A buffer becomes hidden when it is abandoned
|
||||
set hid
|
||||
|
||||
" Configure backspace so it acts as it should act
|
||||
set backspace=eol,start,indent
|
||||
set whichwrap+=<,>,h,l
|
||||
|
||||
" Ignore case when searching
|
||||
set ignorecase
|
||||
|
||||
" When searching try to be smart about cases
|
||||
set smartcase
|
||||
|
||||
" Highlight search results
|
||||
set hlsearch
|
||||
|
||||
" Makes search act like search in modern browsers
|
||||
set incsearch
|
||||
|
||||
" Don't redraw while executing macros (good performance config)
|
||||
set lazyredraw
|
||||
|
||||
" For regular expressions turn magic on
|
||||
set magic
|
||||
|
||||
" Show matching brackets when text indicator is over them
|
||||
set showmatch
|
||||
" How many tenths of a second to blink when matching brackets
|
||||
set mat=2
|
||||
|
||||
" No annoying sound on errors
|
||||
set noerrorbells
|
||||
set novisualbell
|
||||
set t_vb=
|
||||
set tm=500
|
||||
|
||||
" Properly disable sound on errors on MacVim
|
||||
if has("gui_macvim")
|
||||
autocmd GUIEnter * set vb t_vb=
|
||||
endif
|
||||
|
||||
|
||||
" Add a bit extra margin to the left
|
||||
set foldcolumn=1
|
||||
|
||||
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" => Colors and Fonts
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" Enable syntax highlighting
|
||||
syntax enable
|
||||
|
||||
" Enable 256 colors palette in Gnome Terminal
|
||||
if $COLORTERM == 'gnome-terminal'
|
||||
set t_Co=256
|
||||
endif
|
||||
|
||||
try
|
||||
colorscheme darkelf
|
||||
catch
|
||||
endtry
|
||||
|
||||
set background=dark
|
||||
|
||||
" Set extra options when running in GUI mode
|
||||
if has("gui_running")
|
||||
set guioptions-=T
|
||||
set guioptions-=e
|
||||
set t_Co=256
|
||||
set guitablabel=%M\ %t
|
||||
endif
|
||||
|
||||
" Set utf8 as standard encoding and en_US as the standard language
|
||||
set encoding=utf8
|
||||
|
||||
" Use Unix as the standard file type
|
||||
set ffs=unix,dos,mac
|
||||
|
||||
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" => Files, backups and undo
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" Turn backup off, since most stuff is in SVN, git etc. anyway...
|
||||
set nobackup
|
||||
set nowb
|
||||
set noswapfile
|
||||
|
||||
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" => Text, tab and indent related
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" Use spaces instead of tabs
|
||||
set expandtab
|
||||
|
||||
" Be smart when using tabs ;)
|
||||
set smarttab
|
||||
|
||||
" 1 tab == 4 spaces
|
||||
set shiftwidth=4
|
||||
set tabstop=4
|
||||
|
||||
" Linebreak on 500 characters
|
||||
set lbr
|
||||
set tw=500
|
||||
|
||||
set ai "Auto indent
|
||||
set si "Smart indent
|
||||
set wrap "Wrap lines
|
||||
|
||||
|
||||
""""""""""""""""""""""""""""""
|
||||
" => Visual mode related
|
||||
""""""""""""""""""""""""""""""
|
||||
" Visual mode pressing * or # searches for the current selection
|
||||
" Super useful! From an idea by Michael Naumann
|
||||
vnoremap <silent> * :<C-u>call VisualSelection('', '')<CR>/<C-R>=@/<CR><CR>
|
||||
vnoremap <silent> # :<C-u>call VisualSelection('', '')<CR>?<C-R>=@/<CR><CR>
|
||||
|
||||
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" => Moving around, tabs, windows and buffers
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" Map <Space> to / (search) and Ctrl-<Space> to ? (backwards search)
|
||||
map <space> /
|
||||
map <C-space> ?
|
||||
|
||||
" Disable highlight when <leader><cr> is pressed
|
||||
map <silent> <leader><cr> :noh<cr>
|
||||
|
||||
" Smart way to move between windows
|
||||
map <C-j> <C-W>j
|
||||
map <C-k> <C-W>k
|
||||
map <C-h> <C-W>h
|
||||
map <C-l> <C-W>l
|
||||
|
||||
" Close the current buffer
|
||||
map <leader>bd :Bclose<cr>:tabclose<cr>gT
|
||||
|
||||
" Close all the buffers
|
||||
map <leader>ba :bufdo bd<cr>
|
||||
|
||||
map <leader>bl :bnext<cr>
|
||||
map <leader>bh :bprevious<cr>
|
||||
|
||||
" Useful mappings for managing tabs
|
||||
map <leader>tn :tabnew<cr>
|
||||
map <leader>to :tabonly<cr>
|
||||
map <leader>tc :tabclose<cr>
|
||||
map <leader>tm :tabmove
|
||||
map <leader>t<leader> :tabnext
|
||||
|
||||
" Let 'tl' toggle between this and the last accessed tab
|
||||
let g:lasttab = 1
|
||||
nmap <Leader>tl :exe "tabn ".g:lasttab<CR>
|
||||
au TabLeave * let g:lasttab = tabpagenr()
|
||||
|
||||
|
||||
" Opens a new tab with the current buffer's path
|
||||
" Super useful when editing files in the same directory
|
||||
map <leader>te :tabedit <C-r>=expand("%:p:h")<cr>/
|
||||
|
||||
" Switch CWD to the directory of the open buffer
|
||||
map <leader>cd :cd %:p:h<cr>:pwd<cr>
|
||||
|
||||
" Specify the behavior when switching between buffers
|
||||
try
|
||||
set switchbuf=useopen,usetab,newtab
|
||||
set stal=2
|
||||
catch
|
||||
endtry
|
||||
|
||||
" Return to last edit position when opening files (You want this!)
|
||||
au BufReadPost * if line("'\"") > 1 && line("'\"") <= line("$") | exe "normal! g'\"" | endif
|
||||
|
||||
|
||||
""""""""""""""""""""""""""""""
|
||||
" => Status line
|
||||
""""""""""""""""""""""""""""""
|
||||
" Always show the status line
|
||||
set laststatus=2
|
||||
|
||||
" Format the status line
|
||||
set statusline=\ %{HasPaste()}%F%m%r%h\ %w\ \ CWD:\ %r%{getcwd()}%h\ \ \ Line:\ %l\ \ Column:\ %c
|
||||
|
||||
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" => Editing mappings
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" Remap VIM 0 to first non-blank character
|
||||
map 0 ^
|
||||
|
||||
" Move a line of text using ALT+[jk] or Command+[jk] on mac
|
||||
nmap <M-j> mz:m+<cr>`z
|
||||
nmap <M-k> mz:m-2<cr>`z
|
||||
vmap <M-j> :m'>+<cr>`<my`>mzgv`yo`z
|
||||
vmap <M-k> :m'<-2<cr>`>my`<mzgv`yo`z
|
||||
|
||||
if has("mac") || has("macunix")
|
||||
nmap <D-j> <M-j>
|
||||
nmap <D-k> <M-k>
|
||||
vmap <D-j> <M-j>
|
||||
vmap <D-k> <M-k>
|
||||
endif
|
||||
|
||||
" Delete trailing white space on save, useful for some filetypes ;)
|
||||
fun! CleanExtraSpaces()
|
||||
let save_cursor = getpos(".")
|
||||
let old_query = getreg('/')
|
||||
silent! %s/\s\+$//e
|
||||
call setpos('.', save_cursor)
|
||||
call setreg('/', old_query)
|
||||
endfun
|
||||
|
||||
if has("autocmd")
|
||||
autocmd BufWritePre *.txt,*.js,*.py,*.wiki,*.sh,*.coffee :call CleanExtraSpaces()
|
||||
endif
|
||||
|
||||
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" => Spell checking
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" Pressing ,ss will toggle and untoggle spell checking
|
||||
map <leader>ss :setlocal spell!<cr>
|
||||
|
||||
" Shortcuts using <leader>
|
||||
map <leader>sn ]s
|
||||
map <leader>sp [s
|
||||
map <leader>sa zg
|
||||
map <leader>s? z=
|
||||
|
||||
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" => Misc
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" Remove the Windows ^M - when the encodings gets messed up
|
||||
noremap <Leader>m mmHmt:%s/<C-V><cr>//ge<cr>'tzt'm
|
||||
|
||||
" Quickly open a buffer for scribble
|
||||
map <leader>q :e ~/buffer<cr>
|
||||
|
||||
" Quickly open a markdown buffer for scribble
|
||||
map <leader>x :e ~/buffer.md<cr>
|
||||
|
||||
" Toggle paste mode on and off
|
||||
map <leader>pp :setlocal paste!<cr>
|
||||
|
||||
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" => Helper functions
|
||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||
" Returns true if paste mode is enabled
|
||||
function! HasPaste()
|
||||
if &paste
|
||||
return 'PASTE MODE '
|
||||
endif
|
||||
return ''
|
||||
endfunction
|
||||
|
||||
" Don't close window, when deleting a buffer
|
||||
command! Bclose call <SID>BufcloseCloseIt()
|
||||
function! <SID>BufcloseCloseIt()
|
||||
let l:currentBufNum = bufnr("%")
|
||||
let l:alternateBufNum = bufnr("#")
|
||||
|
||||
if buflisted(l:alternateBufNum)
|
||||
buffer #
|
||||
else
|
||||
bnext
|
||||
endif
|
||||
|
||||
if bufnr("%") == l:currentBufNum
|
||||
new
|
||||
endif
|
||||
|
||||
if buflisted(l:currentBufNum)
|
||||
execute("bdelete! ".l:currentBufNum)
|
||||
endif
|
||||
endfunction
|
||||
|
||||
function! CmdLine(str)
|
||||
call feedkeys(":" . a:str)
|
||||
endfunction
|
||||
|
||||
function! VisualSelection(direction, extra_filter) range
|
||||
let l:saved_reg = @"
|
||||
execute "normal! vgvy"
|
||||
|
||||
let l:pattern = escape(@", "\\/.*'$^~[]")
|
||||
let l:pattern = substitute(l:pattern, "\n$", "", "")
|
||||
|
||||
if a:direction == 'gv'
|
||||
call CmdLine("Ack '" . l:pattern . "' " )
|
||||
elseif a:direction == 'replace'
|
||||
call CmdLine("%s" . '/'. l:pattern . '/')
|
||||
endif
|
||||
|
||||
let @/ = l:pattern
|
||||
let @" = l:saved_reg
|
||||
endfunction
|
||||
@@ -1,21 +0,0 @@
|
||||
# This is your rocks.nvim plugins declaration file.
|
||||
# Here is a small yet pretty detailed example on how to use it:
|
||||
#
|
||||
# [plugins]
|
||||
# nvim-treesitter = "semver_version" # e.g. "1.0.0"
|
||||
|
||||
# List of non-Neovim rocks.
|
||||
# This includes things like `toml` or other lua packages.
|
||||
[rocks]
|
||||
|
||||
# List of Neovim plugins to install alongside their versions.
|
||||
# If the plugin name contains a dot then you must add quotes to the key name!
|
||||
[plugins]
|
||||
"rocks.nvim" = "2.43.1" # rocks.nvim can also manage itself :D
|
||||
"rocks-config.nvim" = "3.1.0"
|
||||
neorg = "9.3.0"
|
||||
"rocks-git.nvim" = "2.5.3"
|
||||
|
||||
[plugins.nvim-treesitter]
|
||||
git = "nvim-treesitter/nvim-treesitter"
|
||||
rev = "v0.9.3"
|
||||
+4
-18
@@ -1,20 +1,5 @@
|
||||
print("advent of neovim")
|
||||
|
||||
require("config.lazy")
|
||||
--
|
||||
-- local o = vim.opt
|
||||
-- o.compatible = false
|
||||
-- o.number = true
|
||||
-- o.cmdheight = 2
|
||||
-- o.expandtab = true
|
||||
-- o.smarttab = true
|
||||
-- o.shiftwidth = 4
|
||||
-- o.tabstop = 4
|
||||
-- o.ai = true
|
||||
-- o.si = true
|
||||
--
|
||||
-- nvim_create_user_command("InsertTodayHeader", ':pu=strftime("# %a %d %b %Y")', {})
|
||||
--
|
||||
|
||||
vim.opt.compatible = false
|
||||
vim.opt.foldmethod = "expr"
|
||||
vim.opt.foldexpr = "v:lua.MyCustomFoldExpr()"
|
||||
@@ -23,7 +8,8 @@ vim.diagnostic.config({ virtual_text = true })
|
||||
function _G.MyCustomFoldExpr()
|
||||
local line = vim.fn.getline(vim.v.lnum)
|
||||
if line:match("::$") then
|
||||
return "=" -- keep the same fold level as the previous line
|
||||
return "="
|
||||
end
|
||||
return vim.treesitter.foldexpr()
|
||||
local ok, result = pcall(vim.treesitter.foldexpr)
|
||||
return ok and result or "0"
|
||||
end
|
||||
|
||||
+2
-8
@@ -3,27 +3,21 @@
|
||||
"lazyvim.plugins.extras.coding.luasnip",
|
||||
"lazyvim.plugins.extras.coding.mini-comment",
|
||||
"lazyvim.plugins.extras.coding.mini-snippets",
|
||||
"lazyvim.plugins.extras.coding.mini-surround",
|
||||
"lazyvim.plugins.extras.coding.yanky",
|
||||
"lazyvim.plugins.extras.editor.dial",
|
||||
"lazyvim.plugins.extras.editor.inc-rename",
|
||||
"lazyvim.plugins.extras.editor.mini-diff",
|
||||
"lazyvim.plugins.extras.editor.mini-files",
|
||||
"lazyvim.plugins.extras.editor.mini-move",
|
||||
"lazyvim.plugins.extras.editor.neo-tree",
|
||||
"lazyvim.plugins.extras.editor.outline",
|
||||
"lazyvim.plugins.extras.editor.snacks_explorer",
|
||||
"lazyvim.plugins.extras.editor.telescope",
|
||||
"lazyvim.plugins.extras.lang.ansible",
|
||||
"lazyvim.plugins.extras.lang.clojure",
|
||||
"lazyvim.plugins.extras.lang.docker",
|
||||
"lazyvim.plugins.extras.lang.git",
|
||||
"lazyvim.plugins.extras.lang.helm",
|
||||
"lazyvim.plugins.extras.lang.json",
|
||||
"lazyvim.plugins.extras.lang.markdown",
|
||||
"lazyvim.plugins.extras.lang.php",
|
||||
"lazyvim.plugins.extras.lang.python",
|
||||
"lazyvim.plugins.extras.lang.sql",
|
||||
"lazyvim.plugins.extras.lang.toml",
|
||||
"lazyvim.plugins.extras.lang.yaml",
|
||||
"lazyvim.plugins.extras.util.dot",
|
||||
"lazyvim.plugins.extras.util.gitui",
|
||||
@@ -31,7 +25,7 @@
|
||||
],
|
||||
"install_version": 8,
|
||||
"news": {
|
||||
"NEWS.md": "10960"
|
||||
"NEWS.md": "11866"
|
||||
},
|
||||
"version": 8
|
||||
}
|
||||
|
||||
@@ -1,7 +1,21 @@
|
||||
-- Autocmds are automatically loaded on the VeryLazy event
|
||||
-- Default autocmds that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/autocmds.lua
|
||||
--
|
||||
-- Add any additional autocmds here
|
||||
-- with `vim.api.nvim_create_autocmd`
|
||||
--
|
||||
-- Or remove existing autocmds by their group name (which is prefixed with `lazyvim_` for the defaults)
|
||||
-- By this point noice.nvim has already replaced vim.notify
|
||||
|
||||
-- Log warnings and errors to file for debugging
|
||||
local log_path = vim.fn.stdpath("log") .. "/nvim_errors.log"
|
||||
local _notify = vim.notify
|
||||
vim.notify = function(msg, level, opts)
|
||||
if level and level >= vim.log.levels.WARN then
|
||||
local f = io.open(log_path, "a")
|
||||
if f then
|
||||
f:write(string.format(
|
||||
"[%s] %s: %s\n",
|
||||
os.date("%Y-%m-%d %H:%M:%S"),
|
||||
level == vim.log.levels.ERROR and "ERROR" or "WARN",
|
||||
tostring(msg)
|
||||
))
|
||||
f:close()
|
||||
end
|
||||
end
|
||||
return _notify(msg, level, opts)
|
||||
end
|
||||
|
||||
@@ -1,12 +1,2 @@
|
||||
-- Keymaps are automatically loaded on the VeryLazy event
|
||||
-- Default keymaps that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/keymaps.lua
|
||||
-- Add any additional keymaps here
|
||||
--
|
||||
-- vim.api.nvim_set_keymap("i", "jj", "<Esc>", { noremap = false })
|
||||
|
||||
local wk = require("which-key")
|
||||
|
||||
wk.add({
|
||||
{ "<leader>N", group = "Notes" },
|
||||
{ "<leader>Nt", ":Journal<CR>", desc = "Today" },
|
||||
})
|
||||
-- Use legendary.nvim to add named commands to the command palette
|
||||
|
||||
@@ -18,8 +18,8 @@ vim.opt.rtp:prepend(lazypath)
|
||||
-- Make sure to setup `mapleader` and `maplocalleader` before
|
||||
-- loading lazy.nvim so that mappings are correct.
|
||||
-- This is also a good place to setup other settings (vim.opt)
|
||||
vim.g.mapleader = ","
|
||||
vim.g.maplocalleader = ","
|
||||
vim.g.mapleader = " "
|
||||
vim.g.maplocalleader = "\\"
|
||||
|
||||
-- Setup lazy.nvim
|
||||
require("lazy").setup({
|
||||
@@ -62,5 +62,5 @@ require("lazy").setup({
|
||||
-- colorscheme that will be used when installing plugins.
|
||||
install = { colorscheme = { "habamax" } },
|
||||
-- automatically check for plugin updates
|
||||
checker = { enabled = true },
|
||||
-- checker = { enabled = true },
|
||||
})
|
||||
|
||||
@@ -1,53 +0,0 @@
|
||||
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
|
||||
if not (vim.uv or vim.loop).fs_stat(lazypath) then
|
||||
local lazyrepo = "https://github.com/folke/lazy.nvim.git"
|
||||
local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath })
|
||||
if vim.v.shell_error ~= 0 then
|
||||
vim.api.nvim_echo({
|
||||
{ "Failed to clone lazy.nvim:\n", "ErrorMsg" },
|
||||
{ out, "WarningMsg" },
|
||||
{ "\nPress any key to exit..." },
|
||||
}, true, {})
|
||||
vim.fn.getchar()
|
||||
os.exit(1)
|
||||
end
|
||||
end
|
||||
vim.opt.rtp:prepend(lazypath)
|
||||
|
||||
require("lazy").setup({
|
||||
spec = {
|
||||
-- add LazyVim and import its plugins
|
||||
{ "LazyVim/LazyVim", import = "lazyvim.plugins" },
|
||||
-- import/override with your plugins
|
||||
{ import = "plugins" },
|
||||
},
|
||||
defaults = {
|
||||
-- By default, only LazyVim plugins will be lazy-loaded. Your custom plugins will load during startup.
|
||||
-- If you know what you're doing, you can set this to `true` to have all your custom plugins lazy-loaded by default.
|
||||
lazy = false,
|
||||
-- It's recommended to leave version=false for now, since a lot the plugin that support versioning,
|
||||
-- have outdated releases, which may break your Neovim install.
|
||||
version = false, -- always use the latest git commit
|
||||
-- version = "*", -- try installing the latest stable version for plugins that support semver
|
||||
},
|
||||
install = { colorscheme = { "tokyonight", "habamax" } },
|
||||
checker = {
|
||||
enabled = true, -- check for plugin updates periodically
|
||||
notify = false, -- notify on update
|
||||
}, -- automatically check for plugin updates
|
||||
performance = {
|
||||
rtp = {
|
||||
-- disable some rtp plugins
|
||||
disabled_plugins = {
|
||||
"gzip",
|
||||
-- "matchit",
|
||||
-- "matchparen",
|
||||
-- "netrwPlugin",
|
||||
"tarPlugin",
|
||||
"tohtml",
|
||||
"tutor",
|
||||
"zipPlugin",
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
@@ -1,3 +1,6 @@
|
||||
-- Options are automatically loaded before lazy.nvim startup
|
||||
-- Default options that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/options.lua
|
||||
-- Add any additional options here
|
||||
vim.opt.relativenumber = true
|
||||
vim.opt.scrolloff = 8
|
||||
vim.opt.wrap = false
|
||||
vim.opt.undofile = true
|
||||
|
||||
@@ -1,17 +0,0 @@
|
||||
return {
|
||||
"jackMort/ChatGPT.nvim",
|
||||
event = "VeryLazy",
|
||||
config = function()
|
||||
require("chatgpt").setup({
|
||||
openai_params = {
|
||||
model = "gpt-4.1"
|
||||
}
|
||||
})
|
||||
end,
|
||||
dependencies = {
|
||||
"MunifTanjim/nui.nvim",
|
||||
"nvim-lua/plenary.nvim",
|
||||
"folke/trouble.nvim", -- optional
|
||||
"nvim-telescope/telescope.nvim"
|
||||
}
|
||||
}
|
||||
@@ -1,3 +0,0 @@
|
||||
return {
|
||||
{ "zbirenbaum/copilot.lua", opts = { suggestion = { enabled = false } } },
|
||||
}
|
||||
@@ -1,197 +0,0 @@
|
||||
-- since this is just an example spec, don't actually load anything here and return an empty spec
|
||||
-- stylua: ignore
|
||||
if true then return {} end
|
||||
|
||||
-- every spec file under the "plugins" directory will be loaded automatically by lazy.nvim
|
||||
--
|
||||
-- In your plugin files, you can:
|
||||
-- * add extra plugins
|
||||
-- * disable/enabled LazyVim plugins
|
||||
-- * override the configuration of LazyVim plugins
|
||||
return {
|
||||
-- add gruvbox
|
||||
{ "ellisonleao/gruvbox.nvim" },
|
||||
|
||||
-- Configure LazyVim to load gruvbox
|
||||
{
|
||||
"LazyVim/LazyVim",
|
||||
opts = {
|
||||
colorscheme = "gruvbox",
|
||||
},
|
||||
},
|
||||
|
||||
-- change trouble config
|
||||
{
|
||||
"folke/trouble.nvim",
|
||||
-- opts will be merged with the parent spec
|
||||
opts = { use_diagnostic_signs = true },
|
||||
},
|
||||
|
||||
-- disable trouble
|
||||
{ "folke/trouble.nvim", enabled = false },
|
||||
|
||||
-- override nvim-cmp and add cmp-emoji
|
||||
{
|
||||
"hrsh7th/nvim-cmp",
|
||||
dependencies = { "hrsh7th/cmp-emoji" },
|
||||
---@param opts cmp.ConfigSchema
|
||||
opts = function(_, opts)
|
||||
table.insert(opts.sources, { name = "emoji" })
|
||||
end,
|
||||
},
|
||||
|
||||
-- change some telescope options and a keymap to browse plugin files
|
||||
{
|
||||
"nvim-telescope/telescope.nvim",
|
||||
keys = {
|
||||
-- add a keymap to browse plugin files
|
||||
-- stylua: ignore
|
||||
{
|
||||
"<leader>fp",
|
||||
function() require("telescope.builtin").find_files({ cwd = require("lazy.core.config").options.root }) end,
|
||||
desc = "Find Plugin File",
|
||||
},
|
||||
},
|
||||
-- change some options
|
||||
opts = {
|
||||
defaults = {
|
||||
layout_strategy = "horizontal",
|
||||
layout_config = { prompt_position = "top" },
|
||||
sorting_strategy = "ascending",
|
||||
winblend = 0,
|
||||
},
|
||||
},
|
||||
},
|
||||
|
||||
-- add pyright to lspconfig
|
||||
{
|
||||
"neovim/nvim-lspconfig",
|
||||
---@class PluginLspOpts
|
||||
opts = {
|
||||
---@type lspconfig.options
|
||||
servers = {
|
||||
-- pyright will be automatically installed with mason and loaded with lspconfig
|
||||
pyright = {},
|
||||
},
|
||||
},
|
||||
},
|
||||
|
||||
-- add tsserver and setup with typescript.nvim instead of lspconfig
|
||||
{
|
||||
"neovim/nvim-lspconfig",
|
||||
dependencies = {
|
||||
"jose-elias-alvarez/typescript.nvim",
|
||||
init = function()
|
||||
require("lazyvim.util").lsp.on_attach(function(_, buffer)
|
||||
-- stylua: ignore
|
||||
vim.keymap.set( "n", "<leader>co", "TypescriptOrganizeImports", { buffer = buffer, desc = "Organize Imports" })
|
||||
vim.keymap.set("n", "<leader>cR", "TypescriptRenameFile", { desc = "Rename File", buffer = buffer })
|
||||
end)
|
||||
end,
|
||||
},
|
||||
---@class PluginLspOpts
|
||||
opts = {
|
||||
---@type lspconfig.options
|
||||
servers = {
|
||||
-- tsserver will be automatically installed with mason and loaded with lspconfig
|
||||
tsserver = {},
|
||||
},
|
||||
-- you can do any additional lsp server setup here
|
||||
-- return true if you don't want this server to be setup with lspconfig
|
||||
---@type table<string, fun(server:string, opts:_.lspconfig.options):boolean?>
|
||||
setup = {
|
||||
-- example to setup with typescript.nvim
|
||||
tsserver = function(_, opts)
|
||||
require("typescript").setup({ server = opts })
|
||||
return true
|
||||
end,
|
||||
-- Specify * to use this function as a fallback for any server
|
||||
-- ["*"] = function(server, opts) end,
|
||||
},
|
||||
},
|
||||
},
|
||||
|
||||
-- for typescript, LazyVim also includes extra specs to properly setup lspconfig,
|
||||
-- treesitter, mason and typescript.nvim. So instead of the above, you can use:
|
||||
{ import = "lazyvim.plugins.extras.lang.typescript" },
|
||||
|
||||
-- add more treesitter parsers
|
||||
{
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
opts = {
|
||||
ensure_installed = {
|
||||
"bash",
|
||||
"html",
|
||||
"javascript",
|
||||
"json",
|
||||
"lua",
|
||||
"markdown",
|
||||
"markdown_inline",
|
||||
"python",
|
||||
"query",
|
||||
"regex",
|
||||
"tsx",
|
||||
"typescript",
|
||||
"vim",
|
||||
"yaml",
|
||||
},
|
||||
},
|
||||
},
|
||||
|
||||
-- since `vim.tbl_deep_extend`, can only merge tables and not lists, the code above
|
||||
-- would overwrite `ensure_installed` with the new value.
|
||||
-- If you'd rather extend the default config, use the code below instead:
|
||||
{
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
opts = function(_, opts)
|
||||
-- add tsx and treesitter
|
||||
vim.list_extend(opts.ensure_installed, {
|
||||
"tsx",
|
||||
"typescript",
|
||||
})
|
||||
end,
|
||||
},
|
||||
|
||||
-- the opts function can also be used to change the default opts:
|
||||
{
|
||||
"nvim-lualine/lualine.nvim",
|
||||
event = "VeryLazy",
|
||||
opts = function(_, opts)
|
||||
table.insert(opts.sections.lualine_x, {
|
||||
function()
|
||||
return "😄"
|
||||
end,
|
||||
})
|
||||
end,
|
||||
},
|
||||
|
||||
-- or you can return new options to override all the defaults
|
||||
{
|
||||
"nvim-lualine/lualine.nvim",
|
||||
event = "VeryLazy",
|
||||
opts = function()
|
||||
return {
|
||||
--[[add your custom lualine config here]]
|
||||
}
|
||||
end,
|
||||
},
|
||||
|
||||
-- use mini.starter instead of alpha
|
||||
{ import = "lazyvim.plugins.extras.ui.mini-starter" },
|
||||
|
||||
-- add jsonls and schemastore packages, and setup treesitter for json, json5 and jsonc
|
||||
{ import = "lazyvim.plugins.extras.lang.json" },
|
||||
|
||||
-- add any tools you want to have installed below
|
||||
{
|
||||
"williamboman/mason.nvim",
|
||||
opts = {
|
||||
ensure_installed = {
|
||||
"stylua",
|
||||
"shellcheck",
|
||||
"shfmt",
|
||||
"flake8",
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
@@ -1,3 +0,0 @@
|
||||
return {
|
||||
"jghauser/follow-md-links.nvim",
|
||||
}
|
||||
@@ -1,4 +0,0 @@
|
||||
return {
|
||||
'nvim-lualine/lualine.nvim',
|
||||
dependencies = { 'nvim-tree/nvim-web-devicons' }
|
||||
}
|
||||
@@ -1,16 +0,0 @@
|
||||
return {
|
||||
"nvim-neo-tree/neo-tree.nvim",
|
||||
branch = "v3.x",
|
||||
dependencies = {
|
||||
"nvim-lua/plenary.nvim",
|
||||
"nvim-tree/nvim-web-devicons", -- not strictly required, but recommended
|
||||
"MunifTanjim/nui.nvim",
|
||||
-- {"3rd/image.nvim", opts = {}}, -- Optional image support in preview window: See `# Preview Mode` for more information
|
||||
},
|
||||
lazy = false, -- neo-tree will lazily load itself
|
||||
---@module "neo-tree"
|
||||
---@type neotree.Config?
|
||||
opts = {
|
||||
-- fill any relevant options here
|
||||
},
|
||||
}
|
||||
@@ -1,66 +0,0 @@
|
||||
return {
|
||||
"nvim-neorg/neorg",
|
||||
lazy = false, -- Disable lazy loading as some `lazy.nvim` distributions set `lazy = true` by default
|
||||
version = "*", -- Pin Neorg to the latest stable release
|
||||
config = function()
|
||||
require("neorg").setup({
|
||||
load = {
|
||||
["core.defaults"] = {}, -- Loads default behaviour
|
||||
["core.concealer"] = {}, -- Adds pretty icons to your documents
|
||||
["core.ui.calendar"] = {},
|
||||
["core.completion"] = { config = { engine = { module_name = "external.lsp-completion" }, name = "[Norg]" } },
|
||||
["core.esupports.metagen"] = { config = { type = "auto", update_date = true } },
|
||||
["core.qol.toc"] = {},
|
||||
["core.qol.todo_items"] = {},
|
||||
["core.looking-glass"] = {},
|
||||
["core.presenter"] = { config = { zen_mode = "zen-mode" } },
|
||||
["core.export"] = {},
|
||||
["core.export.markdown"] = { config = { extensions = "all" } },
|
||||
["core.summary"] = {},
|
||||
["core.tangle"] = { config = { report_on_empty = false } },
|
||||
["core.dirman"] = { -- Manages Neorg workspaces
|
||||
config = {
|
||||
workspaces = {
|
||||
notes = "~/Notes.neorg",
|
||||
},
|
||||
default_workspace = "notes",
|
||||
},
|
||||
},
|
||||
["external.interim-ls"] = {
|
||||
config = {
|
||||
-- default config shown
|
||||
completion_provider = {
|
||||
-- Enable or disable the completion provider
|
||||
enable = true,
|
||||
|
||||
-- Show file contents as documentation when you complete a file name
|
||||
documentation = true,
|
||||
|
||||
-- Try to complete categories provided by Neorg Query. Requires `benlubas/neorg-query`
|
||||
categories = false,
|
||||
|
||||
-- suggest heading completions from the given file for `{@x|}` where `|` is your cursor
|
||||
-- and `x` is an alphanumeric character. `{@name}` expands to `[name]{:$/people:# name}`
|
||||
people = {
|
||||
enable = false,
|
||||
|
||||
-- path to the file you're like to use with the `{@x` syntax, relative to the
|
||||
-- workspace root, without the `.norg` at the end.
|
||||
-- ie. `folder/people` results in searching `$/folder/people.norg` for headings.
|
||||
-- Note that this will change with your workspace, so it fails silently if the file
|
||||
-- doesn't exist
|
||||
path = "people",
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
["core.keybinds"] = {
|
||||
config = {
|
||||
default_keybinds = true,
|
||||
neorg_leader = "<Leader>n", -- Change this to whatever you want
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
end,
|
||||
}
|
||||
@@ -1,7 +0,0 @@
|
||||
return {
|
||||
"akinsho/toggleterm.nvim",
|
||||
tag = "*",
|
||||
keys = {
|
||||
{ "<leader>td", "<cmd>ToggleTerm size=40 dir=~ direction=horizontal<cr>", "Open Horizontal terminal in home directory"}
|
||||
}
|
||||
}
|
||||
@@ -1,3 +0,0 @@
|
||||
return {
|
||||
"nvim-treesitter/nvim-treesitter"
|
||||
}
|
||||
@@ -1,8 +0,0 @@
|
||||
return {
|
||||
"folke/twilight.nvim",
|
||||
opts = {
|
||||
-- your configuration comes here
|
||||
-- or leave it empty to use the default settings
|
||||
-- refer to the configuration section below
|
||||
},
|
||||
}
|
||||
@@ -1,18 +0,0 @@
|
||||
return {
|
||||
"folke/which-key.nvim",
|
||||
event = "VeryLazy",
|
||||
opts = {
|
||||
-- your configuration comes here
|
||||
-- or leave it empty to use the default settings
|
||||
-- refer to the configuration section below
|
||||
},
|
||||
keys = {
|
||||
{
|
||||
{ "<leader>N", group = "Neorg" },
|
||||
{ "<leader>Nt", ":Neorg journal today<CR>", desc = "Today" },
|
||||
},
|
||||
},
|
||||
}
|
||||
--{ "<leader>c", group = "ChatGPT" },
|
||||
--{ "<leader>cc", ":ChatGPT<CR>", desc = "ChatGPT" },
|
||||
--{ "<leader>ce", ":ChatGPTEditWithInstructions<CR>", desc = "ChatGPT Edit Selection with Instructions" },
|
||||
@@ -1,7 +0,0 @@
|
||||
return {
|
||||
"rmagatti/auto-session",
|
||||
lazy = false,
|
||||
opts = {
|
||||
suppressed_dirs = { "~/", "~/Projects", "~/Downloads", "/" },
|
||||
},
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
return {
|
||||
"greggh/claude-code.nvim",
|
||||
dependencies = { "nvim-lua/plenary.nvim" },
|
||||
config = function()
|
||||
require("claude-code").setup({
|
||||
window = {
|
||||
position = "vertical",
|
||||
split_ratio = 0.4,
|
||||
},
|
||||
})
|
||||
end,
|
||||
keys = {
|
||||
{ "<leader>cc", "<cmd>ClaudeCode<CR>", desc = "Claude Code: Toggle" },
|
||||
{ "<leader>cf", "<cmd>ClaudeCodeFocus<CR>", desc = "Claude Code: Focus" },
|
||||
},
|
||||
}
|
||||
@@ -1,3 +0,0 @@
|
||||
return {
|
||||
"benlubas/neorg-interim-ls",
|
||||
}
|
||||
@@ -1,28 +0,0 @@
|
||||
return {
|
||||
"jakobkhansen/journal.nvim",
|
||||
config = function()
|
||||
require("journal").setup({
|
||||
filetype = "md", -- Filetype to use for new journal entries
|
||||
root = "~/Notes/Personal/journals", -- Root directory for journal entries
|
||||
date_format = "%Y-%m-%d", -- Date format for `:Journal <date-modifier>`
|
||||
autocomplete_date_modifier = "end", -- "always"|"never"|"end". Enable date modifier autocompletion
|
||||
|
||||
-- Configuration for journal entries
|
||||
journal = {
|
||||
-- Default configuration for `:Journal <date-modifier>`
|
||||
format = "%Y_%m_%d",
|
||||
template = "# %A %B %d %Y\n",
|
||||
frequency = { day = 1 },
|
||||
|
||||
-- Nested configurations for `:Journal <type> <type> ... <date-modifier>`
|
||||
entries = {
|
||||
day = {
|
||||
format = "%Y_%m_%d", -- Format of the journal entry in the filesystem.
|
||||
template = "# %A %B %d %Y\n", -- Optional. Template used when creating a new journal entry
|
||||
frequency = { day = 1 }, -- Optional. The frequency of the journal entry. Used for `:Journal next`, `:Journal -2` etc
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
end,
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
return {
|
||||
"mrjones2014/legendary.nvim",
|
||||
priority = 10000,
|
||||
lazy = false,
|
||||
dependencies = { "nvim-telescope/telescope.nvim" },
|
||||
opts = {
|
||||
telescope = { auto_register_which_key = false },
|
||||
keymaps = {
|
||||
{ "<leader>cc", description = "Claude Code: Toggle terminal" },
|
||||
{ "<leader>cf", description = "Claude Code: Focus terminal" },
|
||||
},
|
||||
},
|
||||
keys = {
|
||||
{ "<leader><leader>", "<cmd>Legendary<CR>", desc = "Command Palette" },
|
||||
{ "<C-p>", "<cmd>Legendary<CR>", desc = "Command Palette", mode = { "n", "i" } },
|
||||
},
|
||||
}
|
||||
@@ -1,38 +0,0 @@
|
||||
-- Configuration Documentation https://github.com/jakewvincent/mkdnflow.nvim?tab=readme-ov-file#%EF%B8%8F-configuration
|
||||
return {
|
||||
"jakewvincent/mkdnflow.nvim",
|
||||
config = function()
|
||||
require("mkdnflow").setup({
|
||||
-- Config goes here; leave blank for defaults
|
||||
perspective = {
|
||||
priority = "first",
|
||||
root_tell = false,
|
||||
},
|
||||
new_file_template = {
|
||||
use_template = true,
|
||||
placeholders = {
|
||||
before = {
|
||||
title = "link_title",
|
||||
date = "os_date",
|
||||
},
|
||||
after = {},
|
||||
},
|
||||
template = "# {{ title }}",
|
||||
},
|
||||
links = {
|
||||
style = "markdown",
|
||||
name_is_source = false,
|
||||
conceal = false,
|
||||
context = 0,
|
||||
implicit_extension = nil,
|
||||
transform_implicit = false,
|
||||
transform_explicit = function(text)
|
||||
text = text:gsub(" ", "-")
|
||||
text = text:lower()
|
||||
return text
|
||||
end,
|
||||
create_on_follow_failure = true,
|
||||
},
|
||||
})
|
||||
end,
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
return {
|
||||
"stevearc/oil.nvim",
|
||||
dependencies = { "nvim-tree/nvim-web-devicons" },
|
||||
lazy = false,
|
||||
opts = {
|
||||
default_file_explorer = true,
|
||||
columns = { "icon" },
|
||||
view_options = {
|
||||
show_hidden = true,
|
||||
},
|
||||
},
|
||||
keys = {
|
||||
{ "-", "<cmd>Oil<CR>", desc = "Open parent directory" },
|
||||
},
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
return {
|
||||
"MeanderingProgrammer/render-markdown.nvim",
|
||||
dependencies = { "nvim-treesitter/nvim-treesitter", "echasnovski/mini.nvim" }, -- if you use the mini.nvim suite
|
||||
dependencies = { "nvim-treesitter/nvim-treesitter", "nvim-mini/mini.nvim" }, -- if you use the mini.nvim suite
|
||||
---@module 'render-markdown'
|
||||
---@type render.md.UserConfig
|
||||
opts = {},
|
||||
|
||||
+3
-1
@@ -6,7 +6,7 @@ shadow-exclude = [ "name = 'Notification'", "class_g = 'Conky'", "class_g ?= 'No
|
||||
fading = true;
|
||||
fade-in-step = 0.03;
|
||||
fade-out-step = 0.03;
|
||||
inactive-opacity = 0.9;
|
||||
inactive-opacity = 0.95;
|
||||
frame-opacity = 0.7;
|
||||
inactive-opacity-override = false;
|
||||
focus-exclude = [ "class_g = 'Cairo-clock'" ];
|
||||
@@ -61,3 +61,5 @@ wintypes :
|
||||
blur-background = true;
|
||||
shadow-opacity = 0.1;
|
||||
blur-background-frame = false;
|
||||
inactive-dim = 0.2;
|
||||
|
||||
|
||||
@@ -15,16 +15,20 @@ link() {
|
||||
fi
|
||||
}
|
||||
configlink() {
|
||||
link ~/.config/$1 ~/dotfiles/$1
|
||||
link ~/.config/$1 ~/.dotfiles/$1
|
||||
}
|
||||
|
||||
checkdir ~/.config
|
||||
link ~/.dotfiles ~/dotfiles
|
||||
link ~/.profile ~/dotfiles/profile
|
||||
link ~/.config/i3 ~/dotfiles/i3
|
||||
link ~/.profile ~/.dotfiles/profile
|
||||
|
||||
configlink i3
|
||||
configlink tmux
|
||||
configlink nvim
|
||||
configlink kitty
|
||||
configlink polybar
|
||||
configlink picom.conf
|
||||
configlink niri
|
||||
configlink noctalia
|
||||
|
||||
checkdir ~/.claude
|
||||
link ~/.claude/settings.json ~/.dotfiles/claude/settings.json
|
||||
|
||||
+151
@@ -0,0 +1,151 @@
|
||||
# shellcheck shell=bash
|
||||
|
||||
# =============================================================================
|
||||
#
|
||||
# Utility functions for zoxide.
|
||||
#
|
||||
|
||||
# pwd based on the value of _ZO_RESOLVE_SYMLINKS.
|
||||
function __zoxide_pwd() {
|
||||
\builtin pwd -L
|
||||
}
|
||||
|
||||
# cd + custom logic based on the value of _ZO_ECHO.
|
||||
function __zoxide_cd() {
|
||||
# shellcheck disable=SC2164
|
||||
\builtin cd -- "$@"
|
||||
}
|
||||
|
||||
# =============================================================================
|
||||
#
|
||||
# Hook configuration for zoxide.
|
||||
#
|
||||
|
||||
# Hook to add new entries to the database.
|
||||
__zoxide_oldpwd="$(__zoxide_pwd)"
|
||||
|
||||
function __zoxide_hook() {
|
||||
\builtin local -r retval="$?"
|
||||
\builtin local pwd_tmp
|
||||
pwd_tmp="$(__zoxide_pwd)"
|
||||
if [[ ${__zoxide_oldpwd} != "${pwd_tmp}" ]]; then
|
||||
__zoxide_oldpwd="${pwd_tmp}"
|
||||
\command zoxide add -- "${__zoxide_oldpwd}"
|
||||
fi
|
||||
return "${retval}"
|
||||
}
|
||||
|
||||
# Initialize hook.
|
||||
if [[ ${PROMPT_COMMAND:=} != *'__zoxide_hook'* ]]; then
|
||||
PROMPT_COMMAND="__zoxide_hook;${PROMPT_COMMAND#;}"
|
||||
fi
|
||||
|
||||
# Report common issues.
|
||||
function __zoxide_doctor() {
|
||||
[[ ${_ZO_DOCTOR:-1} -ne 0 ]] || return 0
|
||||
[[ ${PROMPT_COMMAND:=} != *'__zoxide_hook'* ]] || return 0
|
||||
|
||||
_ZO_DOCTOR=0
|
||||
\builtin printf '%s\n' \
|
||||
'zoxide: detected a possible configuration issue.' \
|
||||
'Please ensure that zoxide is initialized right at the end of your shell configuration file (usually ~/.bashrc).' \
|
||||
'' \
|
||||
'If the issue persists, consider filing an issue at:' \
|
||||
'https://github.com/ajeetdsouza/zoxide/issues' \
|
||||
'' \
|
||||
'Disable this message by setting _ZO_DOCTOR=0.' \
|
||||
'' >&2
|
||||
}
|
||||
|
||||
# =============================================================================
|
||||
#
|
||||
# When using zoxide with --no-cmd, alias these internal functions as desired.
|
||||
#
|
||||
|
||||
__zoxide_z_prefix='z#'
|
||||
|
||||
# Jump to a directory using only keywords.
|
||||
function __zoxide_z() {
|
||||
__zoxide_doctor
|
||||
|
||||
# shellcheck disable=SC2199
|
||||
if [[ $# -eq 0 ]]; then
|
||||
__zoxide_cd ~
|
||||
elif [[ $# -eq 1 && $1 == '-' ]]; then
|
||||
__zoxide_cd "${OLDPWD}"
|
||||
elif [[ $# -eq 1 && -d $1 ]]; then
|
||||
__zoxide_cd "$1"
|
||||
elif [[ $# -eq 2 && $1 == '--' ]]; then
|
||||
__zoxide_cd "$2"
|
||||
elif [[ ${@: -1} == "${__zoxide_z_prefix}"?* ]]; then
|
||||
# shellcheck disable=SC2124
|
||||
\builtin local result="${@: -1}"
|
||||
__zoxide_cd "${result:${#__zoxide_z_prefix}}"
|
||||
else
|
||||
\builtin local result
|
||||
# shellcheck disable=SC2312
|
||||
result="$(\command zoxide query --exclude "$(__zoxide_pwd)" -- "$@")" &&
|
||||
__zoxide_cd "${result}"
|
||||
fi
|
||||
}
|
||||
|
||||
# Jump to a directory using interactive search.
|
||||
function __zoxide_zi() {
|
||||
__zoxide_doctor
|
||||
\builtin local result
|
||||
result="$(\command zoxide query --interactive -- "$@")" && __zoxide_cd "${result}"
|
||||
}
|
||||
|
||||
# =============================================================================
|
||||
#
|
||||
# Commands for zoxide. Disable these using --no-cmd.
|
||||
#
|
||||
|
||||
\builtin unalias z &>/dev/null || \builtin true
|
||||
function z() {
|
||||
__zoxide_z "$@"
|
||||
}
|
||||
|
||||
\builtin unalias zi &>/dev/null || \builtin true
|
||||
function zi() {
|
||||
__zoxide_zi "$@"
|
||||
}
|
||||
|
||||
# Load completions.
|
||||
# - Bash 4.4+ is required to use `@Q`.
|
||||
# - Completions require line editing. Since Bash supports only two modes of
|
||||
# line editing (`vim` and `emacs`), we check if either them is enabled.
|
||||
# - Completions don't work on `dumb` terminals.
|
||||
if [[ ${BASH_VERSINFO[0]:-0} -eq 4 && ${BASH_VERSINFO[1]:-0} -ge 4 || ${BASH_VERSINFO[0]:-0} -ge 5 ]] &&
|
||||
[[ :"${SHELLOPTS}": =~ :(vi|emacs): && ${TERM} != 'dumb' ]]; then
|
||||
# Use `printf '\e[5n'` to redraw line after fzf closes.
|
||||
\builtin bind '"\e[0n": redraw-current-line' &>/dev/null
|
||||
|
||||
function __zoxide_z_complete() {
|
||||
# Only show completions when the cursor is at the end of the line.
|
||||
[[ ${#COMP_WORDS[@]} -eq $((COMP_CWORD + 1)) ]] || return
|
||||
|
||||
# If there is only one argument, use `cd` completions.
|
||||
if [[ ${#COMP_WORDS[@]} -eq 2 ]]; then
|
||||
\builtin mapfile -t COMPREPLY < <(
|
||||
\builtin compgen -A directory -- "${COMP_WORDS[-1]}" || \builtin true
|
||||
)
|
||||
# If there is a space after the last word, use interactive selection.
|
||||
elif [[ -z ${COMP_WORDS[-1]} ]] && [[ ${COMP_WORDS[-2]} != "${__zoxide_z_prefix}"?* ]]; then
|
||||
\builtin local result
|
||||
# shellcheck disable=SC2312
|
||||
result="$(\command zoxide query --exclude "$(__zoxide_pwd)" --interactive -- "${COMP_WORDS[@]:1:${#COMP_WORDS[@]}-2}")" &&
|
||||
COMPREPLY=("${__zoxide_z_prefix}${result}/")
|
||||
\builtin printf '\e[5n'
|
||||
fi
|
||||
}
|
||||
|
||||
\builtin complete -F __zoxide_z_complete -o filenames -- z
|
||||
\builtin complete -r zi &>/dev/null || \builtin true
|
||||
fi
|
||||
|
||||
# =============================================================================
|
||||
#
|
||||
# To initialize zoxide, add this to your shell configuration file (usually ~/.bashrc):
|
||||
#
|
||||
# eval "$(zoxide init bash)"
|
||||
Reference in New Issue
Block a user