Compare commits
No commits in common. "main" and "arch" have entirely different histories.
119 changed files with 2473 additions and 3190 deletions
20
README.md
20
README.md
|
@ -1,5 +1,19 @@
|
||||||
# Kalle's NixOS Dotfiles
|
# Dot Files
|
||||||
|
This repository contains the configuration files for some of the programs I use. There is also a handy setup script that should configure everything for you.
|
||||||
|
|
||||||
## TODO:
|
## Usage
|
||||||
Improve Hyprland module to be less verbose
|
This is quite outdated and might not be completely accurate anymore.
|
||||||
|
To use these configuration files you first have to make sure you have the following programs installed:
|
||||||
|
- fish
|
||||||
|
- neovim
|
||||||
|
|
||||||
|
Once you have these programs installed you can clone the repository into a place you like and run the setup script. The setup script will detect existing configuration files and leave them alone. This means that if you are replacing an old configuration you need to delete it first.
|
||||||
|
```bash
|
||||||
|
# Clone the repository into the folder .dots in your home directory.
|
||||||
|
git clone https://git.kallestruik.nl/kalle/dotfiles.git ~/.dots
|
||||||
|
|
||||||
|
# Execute the install script.
|
||||||
|
cd ~/.dots
|
||||||
|
bash setup.sh
|
||||||
|
```
|
||||||
|
|
||||||
|
|
6
Templates/Latex document.desktop
Normal file
6
Templates/Latex document.desktop
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
[Desktop Entry]
|
||||||
|
Name=Latex document
|
||||||
|
Comment=A blank latex document
|
||||||
|
Type=Link
|
||||||
|
URL=src/Latex document.tex
|
||||||
|
Icon=text-x-bibtex
|
6
Templates/Shell script.desktop
Normal file
6
Templates/Shell script.desktop
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
[Desktop Entry]
|
||||||
|
Name=Shell script
|
||||||
|
Comment=A blank shell script
|
||||||
|
Type=Link
|
||||||
|
URL=src/Shell script.sh
|
||||||
|
Icon=text-x-script
|
9
Templates/src/Latex document.tex
Normal file
9
Templates/src/Latex document.tex
Normal file
|
@ -0,0 +1,9 @@
|
||||||
|
\documentclass{article} % This command is used to set the type of document you are working on such as an article, book, or presenation
|
||||||
|
|
||||||
|
\usepackage{geometry} % This package allows the editing of the page layout
|
||||||
|
\usepackage{amsmath} % This package allows the use of a large range of mathematical formula, commands, and symbols
|
||||||
|
\usepackage{graphicx} % This package allows the importing of images
|
||||||
|
|
||||||
|
\begin{document}
|
||||||
|
|
||||||
|
\end{document}
|
1
Templates/src/Shell script.sh
Executable file
1
Templates/src/Shell script.sh
Executable file
|
@ -0,0 +1 @@
|
||||||
|
#!/usr/bin/env bash
|
Binary file not shown.
Before Width: | Height: | Size: 392 KiB |
143
bash/.bashrc
Normal file
143
bash/.bashrc
Normal file
|
@ -0,0 +1,143 @@
|
||||||
|
|
||||||
|
# If not running interactively, don't do anything
|
||||||
|
[[ $- != *i* ]] && return
|
||||||
|
|
||||||
|
# Ansible defaults
|
||||||
|
export ANSIBLE_BECOME_ASK_PASS=yes
|
||||||
|
|
||||||
|
# Add ~/bin and ~/bin/scripts to my path
|
||||||
|
export PATH=$PATH:$HOME/bin/:$HOME/bin/scripts/:$HOME/.cargo/bin
|
||||||
|
|
||||||
|
# Set editor to neovim.
|
||||||
|
alias edit=nvim
|
||||||
|
export EDITOR="nvim"
|
||||||
|
|
||||||
|
# Prompt stuff
|
||||||
|
#
|
||||||
|
# LINEAGE:
|
||||||
|
#
|
||||||
|
# Based on work by woods and sundeepgupta
|
||||||
|
#
|
||||||
|
# https://gist.github.com/31967
|
||||||
|
# https://gist.github.com/sundeepgupta/b099c31ee2cc1eb31b6d
|
||||||
|
|
||||||
|
# The various escape codes that we can use to color our prompt.
|
||||||
|
RED="\[\033[0;31m\]"
|
||||||
|
YELLOW="\[\033[0;33m\]"
|
||||||
|
GREEN="\[\033[0;32m\]"
|
||||||
|
BLUE="\[\033[1;34m\]"
|
||||||
|
LIGHT_RED="\[\033[1;31m\]"
|
||||||
|
LIGHT_GREEN="\[\033[1;32m\]"
|
||||||
|
WHITE="\[\033[1;37m\]"
|
||||||
|
LIGHT_GRAY="\[\033[0;37m\]"
|
||||||
|
CYAN="\[\033[0;36m\]"
|
||||||
|
PURPLE="\[\033[0;35m\]"
|
||||||
|
|
||||||
|
COLOR_NONE="\[\e[0m\]"
|
||||||
|
|
||||||
|
|
||||||
|
# Detect whether the current directory is a git repository.
|
||||||
|
function is_git_repository {
|
||||||
|
git branch > /dev/null 2>&1
|
||||||
|
}
|
||||||
|
|
||||||
|
# Determine the branch/state information for this git repository.
|
||||||
|
function set_git_branch {
|
||||||
|
# Capture the output of the "git status" command.
|
||||||
|
git_status="$(git status 2> /dev/null)"
|
||||||
|
|
||||||
|
|
||||||
|
# Set color based on clean/staged/dirty.
|
||||||
|
if [[ ${git_status} =~ "working tree clean" ]]; then
|
||||||
|
state="${GREEN}"
|
||||||
|
elif [[ ${git_status} =~ "Changes to be committed" ]]; then
|
||||||
|
state="${YELLOW}"
|
||||||
|
else
|
||||||
|
state="${RED}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Set arrow icon based on status against remote.
|
||||||
|
remote_pattern="Your branch is (.*) of"
|
||||||
|
if [[ ${git_status} =~ ${remote_pattern} ]]; then
|
||||||
|
if [[ ${BASH_REMATCH[1]} == "ahead" ]]; then
|
||||||
|
remote="↑"
|
||||||
|
else
|
||||||
|
remote="↓"
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
remote=""
|
||||||
|
fi
|
||||||
|
diverge_pattern="Your branch and (.*) have diverged"
|
||||||
|
if [[ ${git_status} =~ ${diverge_pattern} ]]; then
|
||||||
|
remote="↕"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Get the name of the branch.
|
||||||
|
branch_pattern="^(# )?On branch ([^${IFS}]*)"
|
||||||
|
if [[ ${git_status} =~ ${branch_pattern} ]]; then
|
||||||
|
branch=${BASH_REMATCH[2]}
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Set the final branch string.
|
||||||
|
BRANCH="${state}(${branch})${remote}${COLOR_NONE} "
|
||||||
|
}
|
||||||
|
|
||||||
|
# Return the prompt symbol to use, colorized based on the return value of the
|
||||||
|
# previous command.
|
||||||
|
function set_prompt_symbol () {
|
||||||
|
if test $1 -eq 0 ; then
|
||||||
|
PROMPT_SYMBOL="\$"
|
||||||
|
else
|
||||||
|
PROMPT_SYMBOL="${LIGHT_RED}\$${COLOR_NONE}"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
# Set the full bash prompt.
|
||||||
|
function set_bash_prompt () {
|
||||||
|
# Set the PROMPT_SYMBOL variable. We do this first so we don't lose the
|
||||||
|
# return value of the last command.
|
||||||
|
set_prompt_symbol $?
|
||||||
|
|
||||||
|
# Set the BRANCH variable.
|
||||||
|
if is_git_repository ; then
|
||||||
|
set_git_branch
|
||||||
|
else
|
||||||
|
BRANCH=''
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Set the bash prompt variable.
|
||||||
|
PS1="
|
||||||
|
${BLUE}[\t] ${CYAN}\w ${COLOR_NONE}${BRANCH}
|
||||||
|
${PROMPT_SYMBOL} "
|
||||||
|
}
|
||||||
|
|
||||||
|
# Tell bash to execute this function just before displaying its prompt.
|
||||||
|
PROMPT_COMMAND=set_bash_prompt
|
||||||
|
|
||||||
|
# fzf is love, fzf is life.
|
||||||
|
source /usr/share/fzf/key-bindings.bash
|
||||||
|
|
||||||
|
function cdl() {
|
||||||
|
cd $@
|
||||||
|
ls
|
||||||
|
}
|
||||||
|
|
||||||
|
# Functions
|
||||||
|
function cd-projects {
|
||||||
|
project_name=`project list | fzf --preview="proj_preview {}"`
|
||||||
|
cd "`project path "$project_name"`"
|
||||||
|
}
|
||||||
|
|
||||||
|
# Aliases
|
||||||
|
alias gg="git log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold green)(%ar)%C(reset)%C(bold yellow)%d%C(reset)%n'' %C(white)%s%C(reset) %C(dim white)- %an (%ae)%C(reset)' --all"
|
||||||
|
alias gca="git add -A; git commit -a --amend --no-edit"
|
||||||
|
alias gs="git status"
|
||||||
|
alias proj="cd-projects"
|
||||||
|
# Use the kitty kitten for ssh so sessions can be cached and remote editing/session cloning is possible.
|
||||||
|
alias ssh="kitty +kitten ssh"
|
||||||
|
|
||||||
|
alias paru="paru --bottomup"
|
||||||
|
|
||||||
|
#THIS MUST BE AT THE END OF THE FILE FOR SDKMAN TO WORK!!!
|
||||||
|
export SDKMAN_DIR="$HOME/.sdkman"
|
||||||
|
[[ -s "$HOME/.sdkman/bin/sdkman-init.sh" ]] && source "$HOME/.sdkman/bin/sdkman-init.sh"
|
459
dunst/dunstrc
Normal file
459
dunst/dunstrc
Normal file
|
@ -0,0 +1,459 @@
|
||||||
|
# See dunst(5) for all configuration options
|
||||||
|
|
||||||
|
[global]
|
||||||
|
### Display ###
|
||||||
|
|
||||||
|
# Which monitor should the notifications be displayed on.
|
||||||
|
monitor = 0
|
||||||
|
|
||||||
|
# Display notification on focused monitor. Possible modes are:
|
||||||
|
# mouse: follow mouse pointer
|
||||||
|
# keyboard: follow window with keyboard focus
|
||||||
|
# none: don't follow anything
|
||||||
|
#
|
||||||
|
# "keyboard" needs a window manager that exports the
|
||||||
|
# _NET_ACTIVE_WINDOW property.
|
||||||
|
# This should be the case for almost all modern window managers.
|
||||||
|
#
|
||||||
|
# If this option is set to mouse or keyboard, the monitor option
|
||||||
|
# will be ignored.
|
||||||
|
follow = none
|
||||||
|
|
||||||
|
### Geometry ###
|
||||||
|
|
||||||
|
# dynamic width from 0 to 300
|
||||||
|
# width = (0, 300)
|
||||||
|
# constant width of 300
|
||||||
|
width = 300
|
||||||
|
|
||||||
|
# The maximum height of a single notification, excluding the frame.
|
||||||
|
height = 300
|
||||||
|
|
||||||
|
# Position the notification in the top right corner
|
||||||
|
origin = top-left
|
||||||
|
|
||||||
|
# Offset from the origin
|
||||||
|
offset = 10x10
|
||||||
|
|
||||||
|
# Scale factor. It is auto-detected if value is 0.
|
||||||
|
scale = 0
|
||||||
|
|
||||||
|
# Maximum number of notification (0 means no limit)
|
||||||
|
notification_limit = 20
|
||||||
|
|
||||||
|
### Progress bar ###
|
||||||
|
|
||||||
|
# Turn on the progess bar. It appears when a progress hint is passed with
|
||||||
|
# for example dunstify -h int:value:12
|
||||||
|
progress_bar = true
|
||||||
|
|
||||||
|
# Set the progress bar height. This includes the frame, so make sure
|
||||||
|
# it's at least twice as big as the frame width.
|
||||||
|
progress_bar_height = 10
|
||||||
|
|
||||||
|
# Set the frame width of the progress bar
|
||||||
|
progress_bar_frame_width = 0
|
||||||
|
|
||||||
|
# Set the minimum width for the progress bar
|
||||||
|
progress_bar_min_width = 150
|
||||||
|
|
||||||
|
# Set the maximum width for the progress bar
|
||||||
|
progress_bar_max_width = 300
|
||||||
|
|
||||||
|
# Corner radius for the progress bar. 0 disables rounded corners.
|
||||||
|
progress_bar_corner_radius = 0
|
||||||
|
|
||||||
|
# Corner radius for the icon image.
|
||||||
|
icon_corner_radius = 0
|
||||||
|
|
||||||
|
# Show how many messages are currently hidden (because of
|
||||||
|
# notification_limit).
|
||||||
|
indicate_hidden = yes
|
||||||
|
|
||||||
|
# The transparency of the window. Range: [0; 100].
|
||||||
|
# This option will only work if a compositing window manager is
|
||||||
|
# present (e.g. xcompmgr, compiz, etc.). (X11 only)
|
||||||
|
transparency = 0.3
|
||||||
|
|
||||||
|
# Draw a line of "separator_height" pixel height between two
|
||||||
|
# notifications.
|
||||||
|
# Set to 0 to disable.
|
||||||
|
# If gap_size is greater than 0, this setting will be ignored.
|
||||||
|
separator_height = 2
|
||||||
|
|
||||||
|
# Padding between text and separator.
|
||||||
|
padding = 8
|
||||||
|
|
||||||
|
# Horizontal padding.
|
||||||
|
horizontal_padding = 8
|
||||||
|
|
||||||
|
# Padding between text and icon.
|
||||||
|
text_icon_padding = 0
|
||||||
|
|
||||||
|
# Defines width in pixels of frame around the notification window.
|
||||||
|
# Set to 0 to disable.
|
||||||
|
frame_width = 0
|
||||||
|
|
||||||
|
# Defines color of the frame around the notification window.
|
||||||
|
frame_color = "#aaaaaa"
|
||||||
|
|
||||||
|
# Size of gap to display between notifications - requires a compositor.
|
||||||
|
# If value is greater than 0, separator_height will be ignored and a border
|
||||||
|
# of size frame_width will be drawn around each notification instead.
|
||||||
|
# Click events on gaps do not currently propagate to applications below.
|
||||||
|
gap_size = 10
|
||||||
|
|
||||||
|
# Define a color for the separator.
|
||||||
|
# possible values are:
|
||||||
|
# * auto: dunst tries to find a color fitting to the background;
|
||||||
|
# * foreground: use the same color as the foreground;
|
||||||
|
# * frame: use the same color as the frame;
|
||||||
|
# * anything else will be interpreted as a X color.
|
||||||
|
separator_color = frame
|
||||||
|
|
||||||
|
# Sort messages by urgency.
|
||||||
|
sort = yes
|
||||||
|
|
||||||
|
# Don't remove messages, if the user is idle (no mouse or keyboard input)
|
||||||
|
# for longer than idle_threshold seconds.
|
||||||
|
# Set to 0 to disable.
|
||||||
|
# A client can set the 'transient' hint to bypass this. See the rules
|
||||||
|
# section for how to disable this if necessary
|
||||||
|
# idle_threshold = 120
|
||||||
|
|
||||||
|
### Text ###
|
||||||
|
|
||||||
|
font = Monospace 8
|
||||||
|
|
||||||
|
# The spacing between lines. If the height is smaller than the
|
||||||
|
# font height, it will get raised to the font height.
|
||||||
|
line_height = 0
|
||||||
|
|
||||||
|
# Possible values are:
|
||||||
|
# full: Allow a small subset of html markup in notifications:
|
||||||
|
# <b>bold</b>
|
||||||
|
# <i>italic</i>
|
||||||
|
# <s>strikethrough</s>
|
||||||
|
# <u>underline</u>
|
||||||
|
#
|
||||||
|
# For a complete reference see
|
||||||
|
# <https://docs.gtk.org/Pango/pango_markup.html>.
|
||||||
|
#
|
||||||
|
# strip: This setting is provided for compatibility with some broken
|
||||||
|
# clients that send markup even though it's not enabled on the
|
||||||
|
# server. Dunst will try to strip the markup but the parsing is
|
||||||
|
# simplistic so using this option outside of matching rules for
|
||||||
|
# specific applications *IS GREATLY DISCOURAGED*.
|
||||||
|
#
|
||||||
|
# no: Disable markup parsing, incoming notifications will be treated as
|
||||||
|
# plain text. Dunst will not advertise that it has the body-markup
|
||||||
|
# capability if this is set as a global setting.
|
||||||
|
#
|
||||||
|
# It's important to note that markup inside the format option will be parsed
|
||||||
|
# regardless of what this is set to.
|
||||||
|
markup = full
|
||||||
|
|
||||||
|
# The format of the message. Possible variables are:
|
||||||
|
# %a appname
|
||||||
|
# %s summary
|
||||||
|
# %b body
|
||||||
|
# %i iconname (including its path)
|
||||||
|
# %I iconname (without its path)
|
||||||
|
# %p progress value if set ([ 0%] to [100%]) or nothing
|
||||||
|
# %n progress value if set without any extra characters
|
||||||
|
# %% Literal %
|
||||||
|
# Markup is allowed
|
||||||
|
format = "<b>%s</b>\n%b"
|
||||||
|
|
||||||
|
# Alignment of message text.
|
||||||
|
# Possible values are "left", "center" and "right".
|
||||||
|
alignment = left
|
||||||
|
|
||||||
|
# Vertical alignment of message text and icon.
|
||||||
|
# Possible values are "top", "center" and "bottom".
|
||||||
|
vertical_alignment = center
|
||||||
|
|
||||||
|
# Show age of message if message is older than show_age_threshold
|
||||||
|
# seconds.
|
||||||
|
# Set to -1 to disable.
|
||||||
|
show_age_threshold = 60
|
||||||
|
|
||||||
|
# Specify where to make an ellipsis in long lines.
|
||||||
|
# Possible values are "start", "middle" and "end".
|
||||||
|
ellipsize = middle
|
||||||
|
|
||||||
|
# Ignore newlines '\n' in notifications.
|
||||||
|
ignore_newline = no
|
||||||
|
|
||||||
|
# Stack together notifications with the same content
|
||||||
|
stack_duplicates = true
|
||||||
|
|
||||||
|
# Hide the count of stacked notifications with the same content
|
||||||
|
hide_duplicate_count = false
|
||||||
|
|
||||||
|
# Display indicators for URLs (U) and actions (A).
|
||||||
|
show_indicators = yes
|
||||||
|
|
||||||
|
### Icons ###
|
||||||
|
|
||||||
|
# Recursive icon lookup. You can set a single theme, instead of having to
|
||||||
|
# define all lookup paths.
|
||||||
|
enable_recursive_icon_lookup = true
|
||||||
|
|
||||||
|
# Set icon theme (only used for recursive icon lookup)
|
||||||
|
icon_theme = Adwaita
|
||||||
|
# You can also set multiple icon themes, with the leftmost one being used first.
|
||||||
|
# icon_theme = "Adwaita, breeze"
|
||||||
|
|
||||||
|
# Align icons left/right/top/off
|
||||||
|
icon_position = left
|
||||||
|
|
||||||
|
# Scale small icons up to this size, set to 0 to disable. Helpful
|
||||||
|
# for e.g. small files or high-dpi screens. In case of conflict,
|
||||||
|
# max_icon_size takes precedence over this.
|
||||||
|
min_icon_size = 32
|
||||||
|
|
||||||
|
# Scale larger icons down to this size, set to 0 to disable
|
||||||
|
max_icon_size = 128
|
||||||
|
|
||||||
|
# Paths to default icons (only neccesary when not using recursive icon lookup)
|
||||||
|
icon_path = /usr/share/icons/gnome/16x16/status/:/usr/share/icons/gnome/16x16/devices/
|
||||||
|
|
||||||
|
### History ###
|
||||||
|
|
||||||
|
# Should a notification popped up from history be sticky or timeout
|
||||||
|
# as if it would normally do.
|
||||||
|
sticky_history = yes
|
||||||
|
|
||||||
|
# Maximum amount of notifications kept in history
|
||||||
|
history_length = 20
|
||||||
|
|
||||||
|
### Misc/Advanced ###
|
||||||
|
|
||||||
|
# dmenu path.
|
||||||
|
dmenu = /usr/bin/dmenu -p dunst:
|
||||||
|
|
||||||
|
# Browser for opening urls in context menu.
|
||||||
|
browser = /usr/bin/xdg-open
|
||||||
|
|
||||||
|
# Always run rule-defined scripts, even if the notification is suppressed
|
||||||
|
always_run_script = true
|
||||||
|
|
||||||
|
# Define the title of the windows spawned by dunst
|
||||||
|
title = Dunst
|
||||||
|
|
||||||
|
# Define the class of the windows spawned by dunst
|
||||||
|
class = Dunst
|
||||||
|
|
||||||
|
# Define the corner radius of the notification window
|
||||||
|
# in pixel size. If the radius is 0, you have no rounded
|
||||||
|
# corners.
|
||||||
|
# The radius will be automatically lowered if it exceeds half of the
|
||||||
|
# notification height to avoid clipping text and/or icons.
|
||||||
|
corner_radius = 0
|
||||||
|
|
||||||
|
# Ignore the dbus closeNotification message.
|
||||||
|
# Useful to enforce the timeout set by dunst configuration. Without this
|
||||||
|
# parameter, an application may close the notification sent before the
|
||||||
|
# user defined timeout.
|
||||||
|
ignore_dbusclose = false
|
||||||
|
|
||||||
|
### Wayland ###
|
||||||
|
# These settings are Wayland-specific. They have no effect when using X11
|
||||||
|
|
||||||
|
# Uncomment this if you want to let notications appear under fullscreen
|
||||||
|
# applications (default: overlay)
|
||||||
|
# layer = top
|
||||||
|
|
||||||
|
# Set this to true to use X11 output on Wayland.
|
||||||
|
force_xwayland = false
|
||||||
|
|
||||||
|
### Legacy
|
||||||
|
|
||||||
|
# Use the Xinerama extension instead of RandR for multi-monitor support.
|
||||||
|
# This setting is provided for compatibility with older nVidia drivers that
|
||||||
|
# do not support RandR and using it on systems that support RandR is highly
|
||||||
|
# discouraged.
|
||||||
|
#
|
||||||
|
# By enabling this setting dunst will not be able to detect when a monitor
|
||||||
|
# is connected or disconnected which might break follow mode if the screen
|
||||||
|
# layout changes.
|
||||||
|
force_xinerama = false
|
||||||
|
|
||||||
|
### mouse
|
||||||
|
|
||||||
|
# Defines list of actions for each mouse event
|
||||||
|
# Possible values are:
|
||||||
|
# * none: Don't do anything.
|
||||||
|
# * do_action: Invoke the action determined by the action_name rule. If there is no
|
||||||
|
# such action, open the context menu.
|
||||||
|
# * open_url: If the notification has exactly one url, open it. If there are multiple
|
||||||
|
# ones, open the context menu.
|
||||||
|
# * close_current: Close current notification.
|
||||||
|
# * close_all: Close all notifications.
|
||||||
|
# * context: Open context menu for the notification.
|
||||||
|
# * context_all: Open context menu for all notifications.
|
||||||
|
# These values can be strung together for each mouse event, and
|
||||||
|
# will be executed in sequence.
|
||||||
|
mouse_left_click = close_current
|
||||||
|
mouse_middle_click = do_action, close_current
|
||||||
|
mouse_right_click = close_all
|
||||||
|
|
||||||
|
# Experimental features that may or may not work correctly. Do not expect them
|
||||||
|
# to have a consistent behaviour across releases.
|
||||||
|
[experimental]
|
||||||
|
# Calculate the dpi to use on a per-monitor basis.
|
||||||
|
# If this setting is enabled the Xft.dpi value will be ignored and instead
|
||||||
|
# dunst will attempt to calculate an appropriate dpi value for each monitor
|
||||||
|
# using the resolution and physical size. This might be useful in setups
|
||||||
|
# where there are multiple screens with very different dpi values.
|
||||||
|
per_monitor_dpi = false
|
||||||
|
|
||||||
|
|
||||||
|
[urgency_low]
|
||||||
|
# IMPORTANT: colors have to be defined in quotation marks.
|
||||||
|
# Otherwise the "#" and following would be interpreted as a comment.
|
||||||
|
background = "#222222"
|
||||||
|
foreground = "#888888"
|
||||||
|
timeout = 10
|
||||||
|
# Icon for notifications with low urgency, uncomment to enable
|
||||||
|
#default_icon = /path/to/icon
|
||||||
|
|
||||||
|
[urgency_normal]
|
||||||
|
background = "#285577"
|
||||||
|
foreground = "#ffffff"
|
||||||
|
timeout = 10
|
||||||
|
# Icon for notifications with normal urgency, uncomment to enable
|
||||||
|
#default_icon = /path/to/icon
|
||||||
|
|
||||||
|
[urgency_critical]
|
||||||
|
background = "#900000"
|
||||||
|
foreground = "#ffffff"
|
||||||
|
frame_color = "#ff0000"
|
||||||
|
timeout = 0
|
||||||
|
# Icon for notifications with critical urgency, uncomment to enable
|
||||||
|
#default_icon = /path/to/icon
|
||||||
|
|
||||||
|
# Every section that isn't one of the above is interpreted as a rules to
|
||||||
|
# override settings for certain messages.
|
||||||
|
#
|
||||||
|
# Messages can be matched by
|
||||||
|
# appname (discouraged, see desktop_entry)
|
||||||
|
# body
|
||||||
|
# category
|
||||||
|
# desktop_entry
|
||||||
|
# icon
|
||||||
|
# match_transient
|
||||||
|
# msg_urgency
|
||||||
|
# stack_tag
|
||||||
|
# summary
|
||||||
|
#
|
||||||
|
# and you can override the
|
||||||
|
# background
|
||||||
|
# foreground
|
||||||
|
# format
|
||||||
|
# frame_color
|
||||||
|
# fullscreen
|
||||||
|
# new_icon
|
||||||
|
# set_stack_tag
|
||||||
|
# set_transient
|
||||||
|
# set_category
|
||||||
|
# timeout
|
||||||
|
# urgency
|
||||||
|
# icon_position
|
||||||
|
# skip_display
|
||||||
|
# history_ignore
|
||||||
|
# action_name
|
||||||
|
# word_wrap
|
||||||
|
# ellipsize
|
||||||
|
# alignment
|
||||||
|
# hide_text
|
||||||
|
#
|
||||||
|
# Shell-like globbing will get expanded.
|
||||||
|
#
|
||||||
|
# Instead of the appname filter, it's recommended to use the desktop_entry filter.
|
||||||
|
# GLib based applications export their desktop-entry name. In comparison to the appname,
|
||||||
|
# the desktop-entry won't get localized.
|
||||||
|
#
|
||||||
|
# SCRIPTING
|
||||||
|
# You can specify a script that gets run when the rule matches by
|
||||||
|
# setting the "script" option.
|
||||||
|
# The script will be called as follows:
|
||||||
|
# script appname summary body icon urgency
|
||||||
|
# where urgency can be "LOW", "NORMAL" or "CRITICAL".
|
||||||
|
#
|
||||||
|
# NOTE: It might be helpful to run dunst -print in a terminal in order
|
||||||
|
# to find fitting options for rules.
|
||||||
|
|
||||||
|
# Disable the transient hint so that idle_threshold cannot be bypassed from the
|
||||||
|
# client
|
||||||
|
#[transient_disable]
|
||||||
|
# match_transient = yes
|
||||||
|
# set_transient = no
|
||||||
|
#
|
||||||
|
# Make the handling of transient notifications more strict by making them not
|
||||||
|
# be placed in history.
|
||||||
|
#[transient_history_ignore]
|
||||||
|
# match_transient = yes
|
||||||
|
# history_ignore = yes
|
||||||
|
|
||||||
|
# fullscreen values
|
||||||
|
# show: show the notifications, regardless if there is a fullscreen window opened
|
||||||
|
# delay: displays the new notification, if there is no fullscreen window active
|
||||||
|
# If the notification is already drawn, it won't get undrawn.
|
||||||
|
# pushback: same as delay, but when switching into fullscreen, the notification will get
|
||||||
|
# withdrawn from screen again and will get delayed like a new notification
|
||||||
|
#[fullscreen_delay_everything]
|
||||||
|
# fullscreen = delay
|
||||||
|
#[fullscreen_show_critical]
|
||||||
|
# msg_urgency = critical
|
||||||
|
# fullscreen = show
|
||||||
|
|
||||||
|
#[espeak]
|
||||||
|
# summary = "*"
|
||||||
|
# script = dunst_espeak.sh
|
||||||
|
|
||||||
|
#[script-test]
|
||||||
|
# summary = "*script*"
|
||||||
|
# script = dunst_test.sh
|
||||||
|
|
||||||
|
#[ignore]
|
||||||
|
# # This notification will not be displayed
|
||||||
|
# summary = "foobar"
|
||||||
|
# skip_display = true
|
||||||
|
|
||||||
|
#[history-ignore]
|
||||||
|
# # This notification will not be saved in history
|
||||||
|
# summary = "foobar"
|
||||||
|
# history_ignore = yes
|
||||||
|
|
||||||
|
#[skip-display]
|
||||||
|
# # This notification will not be displayed, but will be included in the history
|
||||||
|
# summary = "foobar"
|
||||||
|
# skip_display = yes
|
||||||
|
|
||||||
|
#[signed_on]
|
||||||
|
# appname = Pidgin
|
||||||
|
# summary = "*signed on*"
|
||||||
|
# urgency = low
|
||||||
|
#
|
||||||
|
#[signed_off]
|
||||||
|
# appname = Pidgin
|
||||||
|
# summary = *signed off*
|
||||||
|
# urgency = low
|
||||||
|
#
|
||||||
|
#[says]
|
||||||
|
# appname = Pidgin
|
||||||
|
# summary = *says*
|
||||||
|
# urgency = critical
|
||||||
|
#
|
||||||
|
#[twitter]
|
||||||
|
# appname = Pidgin
|
||||||
|
# summary = *twitter.com*
|
||||||
|
# urgency = normal
|
||||||
|
#
|
||||||
|
#[stack-volumes]
|
||||||
|
# appname = "some_volume_notifiers"
|
||||||
|
# set_stack_tag = "volume"
|
||||||
|
#
|
||||||
|
# vim: ft=cfg
|
33
eww/_variables.yuck
Normal file
33
eww/_variables.yuck
Normal file
|
@ -0,0 +1,33 @@
|
||||||
|
(defpoll time :interval "10s" "date '+%H:%M'")
|
||||||
|
(defpoll year :interval "10h" "date '+%Y'")
|
||||||
|
(defpoll date :interval "30m" "date '+%m-%d'")
|
||||||
|
|
||||||
|
(defpoll audio_sink_default
|
||||||
|
:interval "10s"
|
||||||
|
`pactl get-default-sink`)
|
||||||
|
|
||||||
|
(defpoll audio_source_default
|
||||||
|
:interval "10s"
|
||||||
|
`pactl get-default-source`)
|
||||||
|
|
||||||
|
(deflisten media-player_status
|
||||||
|
:initial "paused"
|
||||||
|
"playerctl --player plasma-browser-integration --follow status")
|
||||||
|
|
||||||
|
(deflisten media-player_metadata
|
||||||
|
:initial "{\"title\": \"Nothing playing\", \"album\": \"\", \"artist\": \"\", \"art_url\": \"\"}"
|
||||||
|
"playerctl --player plasma-browser-integration --follow metadata --format '{\"title\": \"{{title}}\", \"album\": \"{{album}}\", \"artist\": \"{{artist}}\", \"art_url\": \"{{mpris:artUrl}}\"}'")
|
||||||
|
|
||||||
|
(deflisten media-player_metadata_image
|
||||||
|
:initial "/tmp/mpris-thumb"
|
||||||
|
"playerctl --follow --player plasma-browser-integration --follow metadata --format {{mpris:artUrl}} | /home/kalle/bin/scripts/eww-playerctl-download-image")
|
||||||
|
|
||||||
|
(defpoll audio-sinks
|
||||||
|
:initial "[]"
|
||||||
|
:interval "10s"
|
||||||
|
"pactl -f json list sinks | jq '[.[]|{\"id\": .name, \"name\":.description, \"volume\": .volume.\"front-left\".value_percent | rtrimstr(\"%\"), \"muted\": .mute}]'")
|
||||||
|
|
||||||
|
(defpoll audio-sources
|
||||||
|
:initial "[]"
|
||||||
|
:interval "10s"
|
||||||
|
"pactl -f json list sources | jq '[.[] | select(.monitor_source == \"\") | {\"id\": .name, \"name\":.description, \"volume\": .volume.\"front-left\".value_percent | rtrimstr(\"%\"), \"muted\": .mute}]'")
|
43
eww/audio.yuck
Normal file
43
eww/audio.yuck
Normal file
|
@ -0,0 +1,43 @@
|
||||||
|
(defwidget audio-sink [sink]
|
||||||
|
(box
|
||||||
|
:orientation "v"
|
||||||
|
(box :space-evenly false :spacing 15
|
||||||
|
(box "${sink.id == audio_sink_default ? "x " : ""}${sink.name}")
|
||||||
|
(box :hexpand true)
|
||||||
|
(button :onclick "pactl set-sink-mute \"${sink.id}\" toggle"
|
||||||
|
"M")
|
||||||
|
(button :onclick "pactl set-default-sink ${sink.id}"
|
||||||
|
"D")
|
||||||
|
)
|
||||||
|
(box :space-evenly false
|
||||||
|
(box :width 50
|
||||||
|
{sink.muted ? "Muted" : "${sink.volume}%"})
|
||||||
|
(scale :hexpand true
|
||||||
|
:value {sink.volume}
|
||||||
|
:onchange "pactl set-sink-volume ${sink.id} {}%"
|
||||||
|
)
|
||||||
|
)
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
(defwidget audio-source [source]
|
||||||
|
(box
|
||||||
|
:orientation "v"
|
||||||
|
(box :space-evenly false :spacing 15
|
||||||
|
(box "${source.id == audio_source_default ? "x " : ""}${source.name}")
|
||||||
|
(box :hexpand true)
|
||||||
|
(button :onclick "pactl set-source-mute \"${source.id}\" toggle"
|
||||||
|
"M")
|
||||||
|
(button :onclick "pactl set-default-source ${source.id}"
|
||||||
|
"D")
|
||||||
|
)
|
||||||
|
(box :space-evenly false
|
||||||
|
(box :width 50
|
||||||
|
{source.muted ? "Muted" : "${source.volume}%"})
|
||||||
|
(scale :hexpand true
|
||||||
|
:value {source.volume}
|
||||||
|
:onchange "pactl set-source-volume ${source.id} {}%"
|
||||||
|
)
|
||||||
|
)
|
||||||
|
)
|
||||||
|
)
|
89
eww/bar.yuck
Normal file
89
eww/bar.yuck
Normal file
|
@ -0,0 +1,89 @@
|
||||||
|
(defwidget notifications []
|
||||||
|
(eventbox :class "notifications"
|
||||||
|
""
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
(defwidget audio []
|
||||||
|
(eventbox :class "audio"
|
||||||
|
:onclick "eww open --toggle audio"
|
||||||
|
""
|
||||||
|
))
|
||||||
|
|
||||||
|
(defwidget clipboard []
|
||||||
|
(eventbox :class "clipboard"
|
||||||
|
""
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
(defwidget color-picker []
|
||||||
|
(eventbox :class "color-picker"
|
||||||
|
:onclick "hyprctl dispatch exec \"hyprpicker --no-fancy | wl-copy\""
|
||||||
|
""
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
(defwidget left []
|
||||||
|
(box :class "left"
|
||||||
|
:halign "start"
|
||||||
|
:orientation "h"
|
||||||
|
(notifications) ; TODO: notifications - Opens notification menu
|
||||||
|
(audio)
|
||||||
|
(clipboard); TODO: Clipboard - Opens clipboard menu (clipboard history click to make current)
|
||||||
|
;; TODO: Bluetooth something
|
||||||
|
(color-picker)
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
(defwidget center []
|
||||||
|
(box :class "center"
|
||||||
|
:space-evenly "false"
|
||||||
|
:valign "center"
|
||||||
|
:orientation "h"
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
(defwidget time []
|
||||||
|
(eventbox :class "time"
|
||||||
|
time
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
(defwidget date []
|
||||||
|
(eventbox :class "date"
|
||||||
|
"${year}-${date}"
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
(defwidget right []
|
||||||
|
(box :class "right"
|
||||||
|
:space-evenly "false"
|
||||||
|
:halign "end"
|
||||||
|
:valign "center"
|
||||||
|
:orientation "v"
|
||||||
|
; TODO: Redo this thing and make it open calendar view
|
||||||
|
(time) ; TODO: Time - Open timer/stopwatch menu?
|
||||||
|
(date) ; TODO: Year month day - Open calendar/upcoming events list (source these from some daemon?)
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
(defwidget bar []
|
||||||
|
(box :class "bar"
|
||||||
|
:orientation "h"
|
||||||
|
(left)
|
||||||
|
(center)
|
||||||
|
(right)
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
(defwindow bar
|
||||||
|
:monitor 2
|
||||||
|
:geometry (geometry :x "0px"
|
||||||
|
:y "10px"
|
||||||
|
:width "1060px"
|
||||||
|
:height "50px"
|
||||||
|
:anchor "center top")
|
||||||
|
:stacking "fg"
|
||||||
|
:exclusive true
|
||||||
|
(bar)
|
||||||
|
)
|
74
eww/eww.scss
Normal file
74
eww/eww.scss
Normal file
|
@ -0,0 +1,74 @@
|
||||||
|
$clr-primary: #883333;
|
||||||
|
$clr-background: rgba(0, 0, 0, 0.5);
|
||||||
|
|
||||||
|
.bar {
|
||||||
|
background-color: $clr-background;
|
||||||
|
border-radius: 10px;
|
||||||
|
|
||||||
|
.notifications, .audio, .clipboard, .color-picker {
|
||||||
|
label {
|
||||||
|
font-size: 30px;
|
||||||
|
margin: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&:hover {
|
||||||
|
color: $clr-primary;
|
||||||
|
// background-color: rgba(#888888, 0.2);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.left {
|
||||||
|
margin-left: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.right {
|
||||||
|
margin-right: 10px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.audio {
|
||||||
|
background-color: $clr-background;
|
||||||
|
border-radius: 5px;
|
||||||
|
|
||||||
|
.audio-sinks {
|
||||||
|
margin-left: 50px;
|
||||||
|
margin-right: 20px;
|
||||||
|
}
|
||||||
|
.audio-sources {
|
||||||
|
margin-left: 20px;
|
||||||
|
margin-right: 50px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.media-player {
|
||||||
|
background-size: cover;
|
||||||
|
margin: 10px;
|
||||||
|
border-radius: 15px;
|
||||||
|
border: 2px solid black;
|
||||||
|
padding: 10px 20px 10px 20px;
|
||||||
|
|
||||||
|
.title {
|
||||||
|
font-size: 25px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.artist {
|
||||||
|
font-size: 14px;
|
||||||
|
color: #aaaaaa;
|
||||||
|
}
|
||||||
|
|
||||||
|
.buttons {
|
||||||
|
.previous, .pause, .next {
|
||||||
|
background-color: rgba(0, 0, 0, 0.5);
|
||||||
|
border-radius: 25px;
|
||||||
|
label {
|
||||||
|
margin: 10px;
|
||||||
|
font-size: 20px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
.title {
|
||||||
|
font-size: 24px;
|
||||||
|
}
|
6
eww/eww.yuck
Normal file
6
eww/eww.yuck
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
(include "_variables.yuck")
|
||||||
|
(include "util.yuck")
|
||||||
|
(include "audio.yuck")
|
||||||
|
(include "bar.yuck")
|
||||||
|
(include "volume.yuck")
|
||||||
|
|
5
eww/util.yuck
Normal file
5
eww/util.yuck
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
(defwidget title [content]
|
||||||
|
(box :class "title"
|
||||||
|
content
|
||||||
|
)
|
||||||
|
)
|
101
eww/volume.yuck
Normal file
101
eww/volume.yuck
Normal file
|
@ -0,0 +1,101 @@
|
||||||
|
(defwidget media-player []
|
||||||
|
(box :class "media-player"
|
||||||
|
:orientation "v"
|
||||||
|
:height 200
|
||||||
|
:style "background-image: radial-gradient(
|
||||||
|
circle farthest-side at left,
|
||||||
|
rgba(0, 0, 0, 0.9) 40%,
|
||||||
|
rgba(0, 0, 0, 0.2) 70%),
|
||||||
|
url('${media-player_metadata_image}');"
|
||||||
|
(box :orientation "v"
|
||||||
|
(box :class "title"
|
||||||
|
:halign "start"
|
||||||
|
{media-player_metadata.title}
|
||||||
|
)
|
||||||
|
|
||||||
|
(box :class "artist"
|
||||||
|
:halign "start"
|
||||||
|
{media-player_metadata.artist}
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
(box :class "buttons"
|
||||||
|
:valign "end"
|
||||||
|
:orientation "h"
|
||||||
|
:space-evenly true
|
||||||
|
:spacing 50
|
||||||
|
(eventbox :class "previous"
|
||||||
|
:width 40
|
||||||
|
:onclick "playerctl previous"
|
||||||
|
""
|
||||||
|
)
|
||||||
|
(eventbox :class "pause"
|
||||||
|
:width 40
|
||||||
|
:onclick "playerctl play-pause"
|
||||||
|
{media-player_status == "Playing" ? "" : ""}
|
||||||
|
)
|
||||||
|
(eventbox :class "next"
|
||||||
|
:width 40
|
||||||
|
:onclick "playerctl next"
|
||||||
|
""
|
||||||
|
)
|
||||||
|
)
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
(defwidget audio-title []
|
||||||
|
(box :class "audio-title"
|
||||||
|
:valign "start"
|
||||||
|
"Audio"
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
(defwidget audio-sinks []
|
||||||
|
(box :orientation "v" :class "audio-sinks" :space-evenly false
|
||||||
|
(title :content "Sinks")
|
||||||
|
{audio_sink_default ? "" : ""} ;; This is dumb, but fixes this variable not updating
|
||||||
|
(for sink in audio-sinks
|
||||||
|
(audio-sink :sink {sink})
|
||||||
|
)
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
(defwidget audio-sources []
|
||||||
|
(box :orientation "v" :class "audio-sources" :space-evenly false
|
||||||
|
(title :content "Sources")
|
||||||
|
{audio_source_default ? "" : ""} ;; This is dumb, but fixes this variable not updating
|
||||||
|
(for source in audio-sources
|
||||||
|
(audio-source :source {source})
|
||||||
|
)
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
(defwidget audio-window []
|
||||||
|
(box :class "audio"
|
||||||
|
:orientation "v"
|
||||||
|
:space-evenly false
|
||||||
|
;; TODO: Maybe individual applications as well.
|
||||||
|
(box :orientation "h"
|
||||||
|
(media-player)
|
||||||
|
(box
|
||||||
|
;; TODO: Put something here
|
||||||
|
)
|
||||||
|
)
|
||||||
|
(box :orientation "h"
|
||||||
|
(audio-sinks)
|
||||||
|
(audio-sources)
|
||||||
|
)
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
(defwindow audio
|
||||||
|
:monitor 2
|
||||||
|
:geometry (geometry :x "10px"
|
||||||
|
:y "10px"
|
||||||
|
:width "1060"
|
||||||
|
:height "500px"
|
||||||
|
:anchor "top center")
|
||||||
|
:stacking "overlay"
|
||||||
|
:exclusive false
|
||||||
|
(audio-window)
|
||||||
|
)
|
200
flake.lock
generated
200
flake.lock
generated
|
@ -1,200 +0,0 @@
|
||||||
{
|
|
||||||
"nodes": {
|
|
||||||
"ags": {
|
|
||||||
"inputs": {
|
|
||||||
"astal": "astal",
|
|
||||||
"nixpkgs": [
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1744557573,
|
|
||||||
"narHash": "sha256-XAyj0iDuI51BytJ1PwN53uLpzTDdznPDQFG4RwihlTQ=",
|
|
||||||
"owner": "Aylur",
|
|
||||||
"repo": "ags",
|
|
||||||
"rev": "3ed9737bdbc8fc7a7c7ceef2165c9109f336bff6",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "Aylur",
|
|
||||||
"repo": "ags",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"astal": {
|
|
||||||
"inputs": {
|
|
||||||
"nixpkgs": [
|
|
||||||
"ags",
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1742571008,
|
|
||||||
"narHash": "sha256-5WgfJAeBpxiKbTR/gJvxrGYfqQRge5aUDcGKmU1YZ1Q=",
|
|
||||||
"owner": "aylur",
|
|
||||||
"repo": "astal",
|
|
||||||
"rev": "dc0e5d37abe9424c53dcbd2506a4886ffee6296e",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "aylur",
|
|
||||||
"repo": "astal",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"home-manager": {
|
|
||||||
"inputs": {
|
|
||||||
"nixpkgs": [
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1750127463,
|
|
||||||
"narHash": "sha256-K2xFtlD3PcKAZriOE3LaBLYmVfGQu+rIF4Jr1RFYR0Q=",
|
|
||||||
"owner": "nix-community",
|
|
||||||
"repo": "home-manager",
|
|
||||||
"rev": "28eef8722d1af18ca13e687dbf485e1c653a0402",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "nix-community",
|
|
||||||
"ref": "master",
|
|
||||||
"repo": "home-manager",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"home-manager_2": {
|
|
||||||
"inputs": {
|
|
||||||
"nixpkgs": [
|
|
||||||
"zen-browser",
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1743604125,
|
|
||||||
"narHash": "sha256-ZD61DNbsBt1mQbinAaaEqKaJk2RFo9R/j+eYWeGMx7A=",
|
|
||||||
"owner": "nix-community",
|
|
||||||
"repo": "home-manager",
|
|
||||||
"rev": "180fd43eea296e62ae68e079fcf56aba268b9a1a",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "nix-community",
|
|
||||||
"repo": "home-manager",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"nixpkgs": {
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1749794982,
|
|
||||||
"narHash": "sha256-Kh9K4taXbVuaLC0IL+9HcfvxsSUx8dPB5s5weJcc9pc=",
|
|
||||||
"owner": "nixos",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"rev": "ee930f9755f58096ac6e8ca94a1887e0534e2d81",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "nixos",
|
|
||||||
"ref": "nixos-unstable",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"nixpkgs_2": {
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1743448293,
|
|
||||||
"narHash": "sha256-bmEPmSjJakAp/JojZRrUvNcDX2R5/nuX6bm+seVaGhs=",
|
|
||||||
"owner": "nixos",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"rev": "77b584d61ff80b4cef9245829a6f1dfad5afdfa3",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "nixos",
|
|
||||||
"ref": "nixos-unstable",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"plugin-harpoon1": {
|
|
||||||
"flake": false,
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1724948422,
|
|
||||||
"narHash": "sha256-ksPNAYnaFbq7N5ifF+RFbLexLW2Lm1ey0agHLzhn9GA=",
|
|
||||||
"owner": "ThePrimeagen",
|
|
||||||
"repo": "harpoon",
|
|
||||||
"rev": "1bc17e3e42ea3c46b33c0bbad6a880792692a1b3",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "ThePrimeagen",
|
|
||||||
"repo": "harpoon",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"plugin-rainbow-delimiters-nvim": {
|
|
||||||
"flake": false,
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1744834150,
|
|
||||||
"narHash": "sha256-EeJvGtBwZgR7i9PEnGe4NTRiDQCgVKkSh5t8Xy5EYfE=",
|
|
||||||
"owner": "HiPhish",
|
|
||||||
"repo": "rainbow-delimiters.nvim",
|
|
||||||
"rev": "55ad4fb76ab68460f700599b7449385f0c4e858e",
|
|
||||||
"type": "gitlab"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "HiPhish",
|
|
||||||
"repo": "rainbow-delimiters.nvim",
|
|
||||||
"type": "gitlab"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"plugin-undotree-nvim": {
|
|
||||||
"flake": false,
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1707485506,
|
|
||||||
"narHash": "sha256-FIYDyfkaIS9C16ClWKLMdpSPv/OrcOalVVsyFJBU2eI=",
|
|
||||||
"owner": "jiaoshijie",
|
|
||||||
"repo": "undotree",
|
|
||||||
"rev": "eab459ab87dd249617b5f7187bb69e614a083047",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "jiaoshijie",
|
|
||||||
"repo": "undotree",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"root": {
|
|
||||||
"inputs": {
|
|
||||||
"ags": "ags",
|
|
||||||
"home-manager": "home-manager",
|
|
||||||
"nixpkgs": "nixpkgs",
|
|
||||||
"plugin-harpoon1": "plugin-harpoon1",
|
|
||||||
"plugin-rainbow-delimiters-nvim": "plugin-rainbow-delimiters-nvim",
|
|
||||||
"plugin-undotree-nvim": "plugin-undotree-nvim",
|
|
||||||
"zen-browser": "zen-browser"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"zen-browser": {
|
|
||||||
"inputs": {
|
|
||||||
"home-manager": "home-manager_2",
|
|
||||||
"nixpkgs": "nixpkgs_2"
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1750152169,
|
|
||||||
"narHash": "sha256-XN5OBCCXKmPBL+UXyyScI5HGgs4U8OFGQTnKuxurBFI=",
|
|
||||||
"owner": "0xc000022070",
|
|
||||||
"repo": "zen-browser-flake",
|
|
||||||
"rev": "ed811ab0d0b407b59cda1023820e9986fd28c8c3",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "0xc000022070",
|
|
||||||
"repo": "zen-browser-flake",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"root": "root",
|
|
||||||
"version": 7
|
|
||||||
}
|
|
70
flake.nix
70
flake.nix
|
@ -1,70 +0,0 @@
|
||||||
{
|
|
||||||
description = "My NixOS and home-manager configs";
|
|
||||||
|
|
||||||
inputs = {
|
|
||||||
# Nixpkgs
|
|
||||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
|
||||||
|
|
||||||
# Home manager
|
|
||||||
home-manager.url = "github:nix-community/home-manager/master";
|
|
||||||
home-manager.inputs.nixpkgs.follows = "nixpkgs";
|
|
||||||
|
|
||||||
# Zen browser
|
|
||||||
zen-browser.url = "github:0xc000022070/zen-browser-flake";
|
|
||||||
|
|
||||||
# AGS
|
|
||||||
ags.url = "github:Aylur/ags";
|
|
||||||
ags.inputs.nixpkgs.follows = "nixpkgs";
|
|
||||||
|
|
||||||
# Neovim plugins not in nixpkgs
|
|
||||||
plugin-rainbow-delimiters-nvim.url = "gitlab:HiPhish/rainbow-delimiters.nvim";
|
|
||||||
plugin-rainbow-delimiters-nvim.flake = false;
|
|
||||||
|
|
||||||
plugin-undotree-nvim.url = "github:jiaoshijie/undotree";
|
|
||||||
plugin-undotree-nvim.flake = false;
|
|
||||||
|
|
||||||
plugin-harpoon1.url = "github:ThePrimeagen/harpoon";
|
|
||||||
plugin-harpoon1.flake = false;
|
|
||||||
};
|
|
||||||
|
|
||||||
outputs =
|
|
||||||
{
|
|
||||||
self,
|
|
||||||
nixpkgs,
|
|
||||||
...
|
|
||||||
}@inputs:
|
|
||||||
let
|
|
||||||
inherit (self) outputs;
|
|
||||||
lib = nixpkgs.lib;
|
|
||||||
|
|
||||||
rootRel = path: ./. + ("/" + path);
|
|
||||||
moduleRel = map (path: rootRel ("modules/" + path));
|
|
||||||
assetRel = path: rootRel ("assets/" + path);
|
|
||||||
|
|
||||||
createSystemConfig =
|
|
||||||
hostname:
|
|
||||||
lib.nixosSystem {
|
|
||||||
specialArgs = {
|
|
||||||
inherit
|
|
||||||
inputs
|
|
||||||
outputs
|
|
||||||
rootRel
|
|
||||||
moduleRel
|
|
||||||
assetRel
|
|
||||||
hostname
|
|
||||||
;
|
|
||||||
};
|
|
||||||
modules = [
|
|
||||||
./hosts/_base
|
|
||||||
./hosts/${hostname}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
in
|
|
||||||
{
|
|
||||||
overlays = import ./overlays { inherit inputs; };
|
|
||||||
nixosConfigurations = lib.genAttrs [
|
|
||||||
"kalle-pc"
|
|
||||||
"kalle-laptop"
|
|
||||||
] createSystemConfig;
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,138 +0,0 @@
|
||||||
{
|
|
||||||
inputs,
|
|
||||||
pkgs,
|
|
||||||
hostname,
|
|
||||||
moduleRel,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
imports =
|
|
||||||
[
|
|
||||||
inputs.home-manager.nixosModules.home-manager
|
|
||||||
]
|
|
||||||
++ moduleRel [
|
|
||||||
"_base"
|
|
||||||
];
|
|
||||||
|
|
||||||
nix.settings = {
|
|
||||||
# Enable flakes and new 'nix' command
|
|
||||||
experimental-features = "nix-command flakes";
|
|
||||||
# Deduplicate and optimize nix store
|
|
||||||
auto-optimise-store = true;
|
|
||||||
# Allow me to use cachix
|
|
||||||
trusted-users = [
|
|
||||||
"root"
|
|
||||||
"kalle"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
nixpkgs.config.allowUnfree = true;
|
|
||||||
|
|
||||||
home-manager.useGlobalPkgs = true;
|
|
||||||
home-manager.useUserPackages = true;
|
|
||||||
|
|
||||||
# Select internationalisation properties.
|
|
||||||
i18n.defaultLocale = "en_US.UTF-8";
|
|
||||||
time.timeZone = "Europe/Amsterdam";
|
|
||||||
|
|
||||||
console = {
|
|
||||||
font = "Lat2-Terminus16";
|
|
||||||
useXkbConfig = true; # use xkbOptions in tty.
|
|
||||||
};
|
|
||||||
|
|
||||||
services.xserver = {
|
|
||||||
enable = true;
|
|
||||||
xkb.layout = "us";
|
|
||||||
};
|
|
||||||
|
|
||||||
# All my systems are systemd-boot
|
|
||||||
boot.loader.systemd-boot.enable = true;
|
|
||||||
boot.loader.efi.canTouchEfiVariables = true;
|
|
||||||
|
|
||||||
# Use network manager to manage networks
|
|
||||||
networking.networkmanager.enable = true;
|
|
||||||
networking.hostName = hostname;
|
|
||||||
|
|
||||||
# Disable firewall.
|
|
||||||
networking.firewall.enable = false;
|
|
||||||
|
|
||||||
# Enable CUPS to print documents.
|
|
||||||
services.printing.enable = true;
|
|
||||||
|
|
||||||
services.gvfs.enable = true;
|
|
||||||
|
|
||||||
# Enable bluetooth. If no bluetooth adapter is present, this does nothing.
|
|
||||||
hardware.bluetooth.enable = true;
|
|
||||||
hardware.bluetooth.powerOnBoot = true;
|
|
||||||
|
|
||||||
# Enable sound.
|
|
||||||
security.rtkit.enable = true;
|
|
||||||
services.pipewire = {
|
|
||||||
enable = true;
|
|
||||||
alsa.enable = true;
|
|
||||||
alsa.support32Bit = true;
|
|
||||||
pulse.enable = true;
|
|
||||||
jack.enable = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
|
||||||
xdg-user-dirs
|
|
||||||
cachix
|
|
||||||
usbutils
|
|
||||||
];
|
|
||||||
|
|
||||||
fonts = {
|
|
||||||
enableDefaultPackages = true;
|
|
||||||
packages = with pkgs; [
|
|
||||||
noto-fonts
|
|
||||||
noto-fonts-cjk-sans
|
|
||||||
noto-fonts-color-emoji
|
|
||||||
|
|
||||||
fira-code
|
|
||||||
fira-code-symbols
|
|
||||||
|
|
||||||
nerd-fonts.symbols-only
|
|
||||||
];
|
|
||||||
|
|
||||||
fontconfig = {
|
|
||||||
defaultFonts = {
|
|
||||||
serif = [
|
|
||||||
"Noto Serif"
|
|
||||||
"Symbols Nerd Font"
|
|
||||||
];
|
|
||||||
sansSerif = [
|
|
||||||
"Noto Sans"
|
|
||||||
"Symbols Nerd Font"
|
|
||||||
];
|
|
||||||
monospace = [
|
|
||||||
"Fira Code"
|
|
||||||
"Symbols Nerd Font Mono"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
users.users.kalle = {
|
|
||||||
isNormalUser = true;
|
|
||||||
group = "kalle";
|
|
||||||
extraGroups = [
|
|
||||||
"wheel"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
users.groups.kalle.gid = 1000;
|
|
||||||
|
|
||||||
home-manager.users.kalle = {
|
|
||||||
home = {
|
|
||||||
username = "kalle";
|
|
||||||
homeDirectory = "/home/kalle";
|
|
||||||
sessionVariables = {
|
|
||||||
EDITOR = "nvim";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.home-manager.enable = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
services.openssh.enable = true;
|
|
||||||
}
|
|
|
@ -1,60 +0,0 @@
|
||||||
{
|
|
||||||
inputs,
|
|
||||||
config,
|
|
||||||
pkgs,
|
|
||||||
moduleRel,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
imports =
|
|
||||||
[
|
|
||||||
./hardware-configuration.nix
|
|
||||||
]
|
|
||||||
++ moduleRel [
|
|
||||||
"sddm.nix"
|
|
||||||
"plasma.nix"
|
|
||||||
|
|
||||||
"bash.nix"
|
|
||||||
"kitty.nix"
|
|
||||||
"git.nix"
|
|
||||||
"direnv.nix"
|
|
||||||
"firefox.nix"
|
|
||||||
"nvim"
|
|
||||||
];
|
|
||||||
|
|
||||||
services.xserver.xkb.options = "eurosign:e,caps:escape";
|
|
||||||
|
|
||||||
home-manager.users.kalle = {
|
|
||||||
home.packages = with pkgs; [
|
|
||||||
discord
|
|
||||||
vesktop
|
|
||||||
chromium
|
|
||||||
httpie
|
|
||||||
kdePackages.kate
|
|
||||||
kdePackages.dolphin
|
|
||||||
kdePackages.ark
|
|
||||||
rustup
|
|
||||||
gcc
|
|
||||||
pavucontrol
|
|
||||||
difftastic
|
|
||||||
sops
|
|
||||||
obsidian
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
# This value determines the NixOS release from which the default
|
|
||||||
# settings for stateful data, like file locations and database versions
|
|
||||||
# on your system were taken. It's perfectly fine and recommended to leave
|
|
||||||
# this value at the release version of the first install of this system.
|
|
||||||
# Before changing this value read the documentation for this option
|
|
||||||
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
|
||||||
system.stateVersion = "23.05"; # Did you read the comment?
|
|
||||||
# This value determines the Home Manager release that your configuration is
|
|
||||||
# compatible with. This helps avoid breakage when a new Home Manager release
|
|
||||||
# introduces backwards incompatible changes.
|
|
||||||
#
|
|
||||||
# You should not change this value, even if you update Home Manager. If you do
|
|
||||||
# want to update the value, then make sure to first check the Home Manager
|
|
||||||
# release notes.
|
|
||||||
home-manager.users.kalle.home.stateVersion = "23.05"; # Please read the comment before changing.
|
|
||||||
}
|
|
|
@ -1,39 +0,0 @@
|
||||||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
|
||||||
# and may be overwritten by future invocations. Please make changes
|
|
||||||
# to /etc/nixos/configuration.nix instead.
|
|
||||||
{ config, lib, pkgs, modulesPath, ... }:
|
|
||||||
|
|
||||||
{
|
|
||||||
imports =
|
|
||||||
[ (modulesPath + "/installer/scan/not-detected.nix")
|
|
||||||
];
|
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "nvme" "usb_storage" "sd_mod" ];
|
|
||||||
boot.initrd.kernelModules = [ ];
|
|
||||||
boot.kernelModules = [ "kvm-intel" ];
|
|
||||||
boot.extraModulePackages = [ ];
|
|
||||||
|
|
||||||
fileSystems."/" =
|
|
||||||
{ device = "/dev/disk/by-uuid/f39bc45f-1489-4fe3-8a2f-6f768563ce20";
|
|
||||||
fsType = "ext4";
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/boot" =
|
|
||||||
{ device = "/dev/disk/by-uuid/C42C-12CF";
|
|
||||||
fsType = "vfat";
|
|
||||||
};
|
|
||||||
|
|
||||||
swapDevices = [ ];
|
|
||||||
|
|
||||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
|
||||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
|
||||||
# still possible to use this option, but it's recommended to use it in conjunction
|
|
||||||
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
|
||||||
networking.useDHCP = lib.mkDefault true;
|
|
||||||
# networking.interfaces.eno1.useDHCP = lib.mkDefault true;
|
|
||||||
# networking.interfaces.wlo1.useDHCP = lib.mkDefault true;
|
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
|
||||||
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
|
|
||||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
|
||||||
}
|
|
|
@ -1,160 +0,0 @@
|
||||||
{
|
|
||||||
inputs,
|
|
||||||
pkgs,
|
|
||||||
moduleRel,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
imports =
|
|
||||||
[
|
|
||||||
./hardware-configuration.nix
|
|
||||||
./hardware-configuration.override.nix
|
|
||||||
]
|
|
||||||
++ moduleRel [
|
|
||||||
# Roles
|
|
||||||
"desktop"
|
|
||||||
"development"
|
|
||||||
"gaming"
|
|
||||||
|
|
||||||
# Desktop environment
|
|
||||||
"hyprland"
|
|
||||||
"theming"
|
|
||||||
"sddm.nix"
|
|
||||||
|
|
||||||
# Communication
|
|
||||||
"signal.nix"
|
|
||||||
"discord.nix"
|
|
||||||
|
|
||||||
# Browsers - Yes I need them all
|
|
||||||
"browsers/firefox.nix"
|
|
||||||
"browsers/zen-browser.nix"
|
|
||||||
"browsers/chromium.nix"
|
|
||||||
|
|
||||||
# Hardware
|
|
||||||
"hardware/zsa.nix"
|
|
||||||
];
|
|
||||||
|
|
||||||
services.btrfs.autoScrub.enable = true;
|
|
||||||
|
|
||||||
monitors = [
|
|
||||||
{
|
|
||||||
isPrimary = true;
|
|
||||||
name = "DP-2";
|
|
||||||
width = 1920;
|
|
||||||
height = 1080;
|
|
||||||
refreshRate = 144;
|
|
||||||
x = 1080;
|
|
||||||
y = 420;
|
|
||||||
vrr = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
name = "HDMI-A-2";
|
|
||||||
width = 1920;
|
|
||||||
height = 1080;
|
|
||||||
x = 0;
|
|
||||||
y = 0;
|
|
||||||
transform = "counterclockwise";
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
name = "HDMI-A-1";
|
|
||||||
width = 1920;
|
|
||||||
height = 1080;
|
|
||||||
x = 1080 + 1920;
|
|
||||||
y = 0;
|
|
||||||
transform = "clockwise";
|
|
||||||
}
|
|
||||||
];
|
|
||||||
|
|
||||||
hyprland =
|
|
||||||
let
|
|
||||||
mod = "SUPER";
|
|
||||||
uwsm = "${pkgs.uwsm}/bin/uwsm";
|
|
||||||
mkUwsmApp = pkg: name: "${uwsm} app -- ${pkg}/share/applications/${name}.desktop";
|
|
||||||
in
|
|
||||||
{
|
|
||||||
mod = mod;
|
|
||||||
|
|
||||||
autoStart = [
|
|
||||||
"uwsm-app -- ags run"
|
|
||||||
(mkUwsmApp inputs.zen-browser.packages.x86_64-linux.default "zen-beta")
|
|
||||||
(mkUwsmApp pkgs.discord "discord")
|
|
||||||
];
|
|
||||||
|
|
||||||
binds =
|
|
||||||
let
|
|
||||||
grimPre = "${pkgs.grimblast}/bin/grimblast --freeze";
|
|
||||||
in
|
|
||||||
{
|
|
||||||
"${mod}, return" = "exec, ${mkUwsmApp pkgs.kitty "kitty"}";
|
|
||||||
"${mod}, E" = "exec, ${pkgs.ulauncher}/bin/ulauncher-toggle #wofi --show drun";
|
|
||||||
", Print" = "exec, ${grimPre} copy area";
|
|
||||||
"SHIFT, Print" = "exec, ${grimPre} copy output";
|
|
||||||
"CTRL, Print" = "exec, ${grimPre} copy screen";
|
|
||||||
"${mod}, Print" = "exec, ${pkgs.hyprpicker}/bin/hyprpicker -anf hex";
|
|
||||||
|
|
||||||
# Clipboard history
|
|
||||||
# bind = $mainMod, V, exec, cliphist list | wofi --dmenu | cliphist decode | wl-copy
|
|
||||||
};
|
|
||||||
|
|
||||||
sensitivity = 0.1;
|
|
||||||
|
|
||||||
layerRules = {
|
|
||||||
"gtk-layer-shell" = [
|
|
||||||
"blur"
|
|
||||||
"ignorezero"
|
|
||||||
];
|
|
||||||
"notifications2" = [
|
|
||||||
"noanim"
|
|
||||||
"blur"
|
|
||||||
"ignorezero"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
windowRules = {
|
|
||||||
# ULauncher
|
|
||||||
"class:^(ulauncher)$" = [
|
|
||||||
"dimaround"
|
|
||||||
];
|
|
||||||
# Auto workspace
|
|
||||||
"class:zen-beta" = [ "workspace 1 silent" ];
|
|
||||||
"class:discord" = [ "workspace name:HDMI-A-1" ];
|
|
||||||
};
|
|
||||||
|
|
||||||
};
|
|
||||||
hyprpaper.wallpaperFolder = "/home/kalle/Pictures/Wallpapers";
|
|
||||||
|
|
||||||
home-manager.users.kalle = {
|
|
||||||
home.packages = with pkgs; [
|
|
||||||
unzip
|
|
||||||
podman
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
services.udev.packages = [
|
|
||||||
# Allow flashing android devices and using ADB
|
|
||||||
pkgs.android-udev-rules
|
|
||||||
];
|
|
||||||
|
|
||||||
# ROCm support
|
|
||||||
hardware.graphics.extraPackages = with pkgs; [
|
|
||||||
rocmPackages.clr.icd
|
|
||||||
];
|
|
||||||
|
|
||||||
# This value determines the NixOS release from which the default
|
|
||||||
# settings for stateful data, like file locations and database versions
|
|
||||||
# on your system were taken. It's perfectly fine and recommended to leave
|
|
||||||
# this value at the release version of the first install of this system.
|
|
||||||
# Before changing this value read the documentation for this option
|
|
||||||
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
|
||||||
system.stateVersion = "23.05"; # Did you read the comment?
|
|
||||||
# This value determines the Home Manager release that your configuration is
|
|
||||||
# compatible with. This helps avoid breakage when a new Home Manager release
|
|
||||||
# introduces backwards incompatible changes.
|
|
||||||
#
|
|
||||||
# You should not change this value, even if you update Home Manager. If you do
|
|
||||||
# want to update the value, then make sure to first check the Home Manager
|
|
||||||
# release notes.
|
|
||||||
home-manager.users.kalle.home.stateVersion = "23.05"; # Please read the comment before changing.
|
|
||||||
}
|
|
|
@ -1,68 +0,0 @@
|
||||||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
|
||||||
# and may be overwritten by future invocations. Please make changes
|
|
||||||
# to /etc/nixos/configuration.nix instead.
|
|
||||||
{
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
pkgs,
|
|
||||||
modulesPath,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
|
|
||||||
{
|
|
||||||
imports = [
|
|
||||||
(modulesPath + "/installer/scan/not-detected.nix")
|
|
||||||
];
|
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = [
|
|
||||||
"xhci_pci"
|
|
||||||
"ahci"
|
|
||||||
"usb_storage"
|
|
||||||
"usbhid"
|
|
||||||
"sd_mod"
|
|
||||||
];
|
|
||||||
boot.initrd.kernelModules = [ ];
|
|
||||||
boot.kernelModules = [ "kvm-amd" ];
|
|
||||||
boot.extraModulePackages = [ ];
|
|
||||||
|
|
||||||
fileSystems."/" = {
|
|
||||||
device = "/dev/disk/by-uuid/d453acaf-12a4-4f7a-b33e-90d87a086995";
|
|
||||||
fsType = "btrfs";
|
|
||||||
options = [ "subvol=root" ];
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/home" = {
|
|
||||||
device = "/dev/disk/by-uuid/d453acaf-12a4-4f7a-b33e-90d87a086995";
|
|
||||||
fsType = "btrfs";
|
|
||||||
options = [ "subvol=home" ];
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/nix" = {
|
|
||||||
device = "/dev/disk/by-uuid/d453acaf-12a4-4f7a-b33e-90d87a086995";
|
|
||||||
fsType = "btrfs";
|
|
||||||
options = [ "subvol=nix" ];
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/boot" = {
|
|
||||||
device = "/dev/disk/by-uuid/23F6-1045";
|
|
||||||
fsType = "vfat";
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/swap" = {
|
|
||||||
device = "/dev/disk/by-uuid/d453acaf-12a4-4f7a-b33e-90d87a086995";
|
|
||||||
fsType = "btrfs";
|
|
||||||
options = [ "subvol=swap" ];
|
|
||||||
};
|
|
||||||
|
|
||||||
swapDevices = [ ];
|
|
||||||
|
|
||||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
|
||||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
|
||||||
# still possible to use this option, but it's recommended to use it in conjunction
|
|
||||||
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
|
||||||
networking.useDHCP = lib.mkDefault true;
|
|
||||||
# networking.interfaces.enp35s0.useDHCP = lib.mkDefault true;
|
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
|
||||||
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
|
||||||
}
|
|
|
@ -1,36 +0,0 @@
|
||||||
{
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
pkgs,
|
|
||||||
modulesPath,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
|
|
||||||
{
|
|
||||||
fileSystems = {
|
|
||||||
# Extra filesystem configs to enable compression.
|
|
||||||
"/".options = [ "compress=zstd" ];
|
|
||||||
"/home".options = [ "compress=zstd" ];
|
|
||||||
"/nix".options = [
|
|
||||||
"compress=zstd"
|
|
||||||
"noatime"
|
|
||||||
];
|
|
||||||
"/swap".options = [ "noatime" ];
|
|
||||||
|
|
||||||
# Mount other drives
|
|
||||||
"/mnt/games" = {
|
|
||||||
device = "/dev/disk/by-uuid/0ac05c3f-df12-458e-b145-e912febe1205";
|
|
||||||
fsType = "ext4";
|
|
||||||
};
|
|
||||||
"/mnt/games-nvme" = {
|
|
||||||
device = "/dev/disk/by-uuid/7ae70244-cf8e-491e-b617-5d2d2ea3e4f1";
|
|
||||||
fsType = "ext4";
|
|
||||||
};
|
|
||||||
"/mnt/external" = {
|
|
||||||
device = "/dev/disk/by-uuid/13e2dfc3-7b4d-44ac-9417-51b933a36917";
|
|
||||||
fsType = "ext4";
|
|
||||||
};
|
|
||||||
|
|
||||||
};
|
|
||||||
|
|
||||||
}
|
|
214
hypr/hyprland.conf
Normal file
214
hypr/hyprland.conf
Normal file
|
@ -0,0 +1,214 @@
|
||||||
|
#
|
||||||
|
# Please note not all available settings / options are set here.
|
||||||
|
# For a full list, see the wiki
|
||||||
|
#
|
||||||
|
|
||||||
|
# Monitor configuration
|
||||||
|
monitor=DP-2,1920x1080@144,0x1080,1
|
||||||
|
monitor=HDMI-A-1,1920x1080@60,1500x0,1
|
||||||
|
monitor=HDMI-A-2,1920x1080@60,1920x1080,1,transform,3
|
||||||
|
monitor=,preferred,auto,auto
|
||||||
|
|
||||||
|
# Clipboard history
|
||||||
|
exec-once = wl-paste --watch cliphist store
|
||||||
|
# Notifications
|
||||||
|
exec-once = dunst
|
||||||
|
# Polkit
|
||||||
|
exec-once = /usr/lib/polkit-kde-authentication-agent-1
|
||||||
|
# Wallpapers
|
||||||
|
exec-once = hyprpaper
|
||||||
|
# Launcher
|
||||||
|
exec-once = ulauncher --no-window-shadow --hide-window
|
||||||
|
# Kde Connect
|
||||||
|
exec-once = kdeconnect-indicator
|
||||||
|
|
||||||
|
# Bar
|
||||||
|
exec-once = eww daemon
|
||||||
|
exec-once = eww open bar
|
||||||
|
|
||||||
|
# Autostart applications
|
||||||
|
exec-once = firefox
|
||||||
|
exec-once = flatpak run org.mozilla.Thunderbird
|
||||||
|
exec-once = flatpak run com.discordapp.Discord
|
||||||
|
|
||||||
|
|
||||||
|
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
|
||||||
|
|
||||||
|
# Source a file (multi-file configs)
|
||||||
|
# source = ~/.config/hypr/myColors.conf
|
||||||
|
|
||||||
|
# Some default env vars.
|
||||||
|
env = XCURSOR_SIZE,24
|
||||||
|
env = QT_QPA_PLATFORMTHEME,qt5ct
|
||||||
|
# For all categories, see https://wiki.hyprland.org/Configuring/Variables/
|
||||||
|
input {
|
||||||
|
kb_layout = us
|
||||||
|
kb_variant = dvorak
|
||||||
|
kb_model =
|
||||||
|
kb_options = caps:escape
|
||||||
|
kb_rules =
|
||||||
|
|
||||||
|
follow_mouse = 1
|
||||||
|
|
||||||
|
touchpad {
|
||||||
|
natural_scroll = no
|
||||||
|
}
|
||||||
|
|
||||||
|
sensitivity = 0.1 # -1.0 - 1.0, 0 means no modification.
|
||||||
|
accel_profile = flat
|
||||||
|
}
|
||||||
|
|
||||||
|
general {
|
||||||
|
# See https://wiki.hyprland.org/Configuring/Variables/ for more
|
||||||
|
|
||||||
|
gaps_in = 5
|
||||||
|
gaps_out = 10
|
||||||
|
border_size = 1
|
||||||
|
col.active_border = rgba(33ccffee) rgba(00ff99ee) 45deg
|
||||||
|
col.inactive_border = rgba(595959aa)
|
||||||
|
|
||||||
|
layout = dwindle
|
||||||
|
}
|
||||||
|
|
||||||
|
decoration {
|
||||||
|
# See https://wiki.hyprland.org/Configuring/Variables/ for more
|
||||||
|
|
||||||
|
rounding = 5
|
||||||
|
blur {
|
||||||
|
enabled = yes
|
||||||
|
size = 3
|
||||||
|
passes = 1
|
||||||
|
new_optimizations = on
|
||||||
|
}
|
||||||
|
|
||||||
|
drop_shadow = yes
|
||||||
|
shadow_range = 4
|
||||||
|
shadow_render_power = 3
|
||||||
|
col.shadow = rgba(1a1a1aee)
|
||||||
|
}
|
||||||
|
|
||||||
|
layerrule = blur,gtk-layer-shell
|
||||||
|
layerrule = ignorezero,gtk-layer-shell
|
||||||
|
|
||||||
|
animations {
|
||||||
|
enabled = yes
|
||||||
|
|
||||||
|
# Some default animations, see https://wiki.hyprland.org/Configuring/Animations/ for more
|
||||||
|
|
||||||
|
bezier = myBezier, 0.05, 0.9, 0.1, 1.05
|
||||||
|
|
||||||
|
animation = windows, 1, 3, myBezier
|
||||||
|
animation = windowsOut, 1, 3, default, popin 80%
|
||||||
|
animation = border, 1, 5, default
|
||||||
|
animation = borderangle, 1, 4, default
|
||||||
|
animation = fade, 1, 3, default
|
||||||
|
animation = workspaces, 1, 2, default
|
||||||
|
}
|
||||||
|
|
||||||
|
dwindle {
|
||||||
|
# See https://wiki.hyprland.org/Configuring/Dwindle-Layout/ for more
|
||||||
|
pseudotile = yes # master switch for pseudotiling. Enabling is bound to mainMod + P in the keybinds section below
|
||||||
|
preserve_split = yes # you probably want this
|
||||||
|
}
|
||||||
|
|
||||||
|
master {
|
||||||
|
# See https://wiki.hyprland.org/Configuring/Master-Layout/ for more
|
||||||
|
new_is_master = true
|
||||||
|
}
|
||||||
|
|
||||||
|
gestures {
|
||||||
|
# See https://wiki.hyprland.org/Configuring/Variables/ for more
|
||||||
|
workspace_swipe = off
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
# workspaces
|
||||||
|
workspace = HDMI-A-1, name:third
|
||||||
|
workspace = HDMI-A-2, name:second
|
||||||
|
workspace = 1, monitor:DP-2
|
||||||
|
workspace = 2, monitor:DP-2
|
||||||
|
workspace = 3, monitor:DP-2
|
||||||
|
workspace = 4, monitor:DP-2
|
||||||
|
workspace = 5, monitor:DP-2
|
||||||
|
workspace = 6, monitor:DP-2
|
||||||
|
workspace = 7, monitor:DP-2
|
||||||
|
workspace = 8, monitor:DP-2
|
||||||
|
workspace = 9, monitor:DP-2
|
||||||
|
workspace = 10, monitor:DP-2
|
||||||
|
|
||||||
|
|
||||||
|
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
|
||||||
|
$mainMod = SUPER
|
||||||
|
$mainModShift = SUPER_SHIFT
|
||||||
|
|
||||||
|
bind = $mainMod, return, exec, kitty
|
||||||
|
bind = $mainModShift, Q, killactive,
|
||||||
|
bind = $mainMod, F, togglefloating,
|
||||||
|
bind = $mainModShift, F, fullscreen
|
||||||
|
bind = $mainMod, E, exec, ulauncher-toggle #wofi --show drun
|
||||||
|
bind = $mainMod, V, exec, cliphist list | wofi --dmenu | cliphist decode | wl-copy
|
||||||
|
bind = CTRL, Print, exec, flameshot gui
|
||||||
|
|
||||||
|
# Switch workspaces with mainMod + [0-9]
|
||||||
|
bind = $mainMod, 1, workspace, 1
|
||||||
|
bind = $mainMod, 2, workspace, 2
|
||||||
|
bind = $mainMod, 3, workspace, 3
|
||||||
|
bind = $mainMod, 4, workspace, 4
|
||||||
|
bind = $mainMod, 5, workspace, 5
|
||||||
|
bind = $mainMod, 6, workspace, 6
|
||||||
|
bind = $mainMod, 7, workspace, 7
|
||||||
|
bind = $mainMod, 8, workspace, 8
|
||||||
|
bind = $mainMod, 9, workspace, 9
|
||||||
|
bind = $mainMod, 0, workspace, 10
|
||||||
|
|
||||||
|
# Move active window to a workspace with mainMod + SHIFT + [0-9]
|
||||||
|
bind = $mainMod SHIFT, 1, movetoworkspace, 1
|
||||||
|
bind = $mainMod SHIFT, 2, movetoworkspace, 2
|
||||||
|
bind = $mainMod SHIFT, 3, movetoworkspace, 3
|
||||||
|
bind = $mainMod SHIFT, 4, movetoworkspace, 4
|
||||||
|
bind = $mainMod SHIFT, 5, movetoworkspace, 5
|
||||||
|
bind = $mainMod SHIFT, 6, movetoworkspace, 6
|
||||||
|
bind = $mainMod SHIFT, 7, movetoworkspace, 7
|
||||||
|
bind = $mainMod SHIFT, 8, movetoworkspace, 8
|
||||||
|
bind = $mainMod SHIFT, 9, movetoworkspace, 9
|
||||||
|
bind = $mainMod SHIFT, 0, movetoworkspace, 10
|
||||||
|
|
||||||
|
# Scroll through existing workspaces with mainMod + scroll
|
||||||
|
bind = $mainMod, mouse_down, workspace, e+1
|
||||||
|
bind = $mainMod, mouse_up, workspace, e-1
|
||||||
|
|
||||||
|
# Move/resize windows with mainMod + LMB/RMB and dragging
|
||||||
|
bindm = $mainMod, mouse:272, movewindow
|
||||||
|
bindm = $mainMod, mouse:273, resizewindow
|
||||||
|
|
||||||
|
# Media keys
|
||||||
|
bind = ,XF86AudioPlay, exec, playerctl --player plasma-browser-integration play-pause
|
||||||
|
bind = ,XF86AudioPrev, exec, playerctl previous
|
||||||
|
bind = ,XF86AudioNext, exec, playerctl next
|
||||||
|
bind = ,XF86AudioLowerVolume, exec, playerctl --player plasma-browser-integration volume 0.01-
|
||||||
|
bind = ,XF86AudioRaiseVolume, exec, playerctl --player plasma-browser-integration volume 0.01+
|
||||||
|
|
||||||
|
|
||||||
|
# This is a dumb work around for hyprland not passing ALT half the time with the pass dispatcher.
|
||||||
|
bind = ALT, M, exec, xdotool key 'ALT+m'
|
||||||
|
bind = ALT, B, exec, xdotool key 'ALT+b'
|
||||||
|
#bind = ALT,M,pass,^(discord)$
|
||||||
|
#bind = ALT,B,pass,^(discord)$
|
||||||
|
|
||||||
|
# Window rules
|
||||||
|
# Auto workspace
|
||||||
|
windowrule = workspace 1 silent,firefox
|
||||||
|
windowrule = workspace name:second silent,discord
|
||||||
|
windowrule = workspace 10 silent,thunderbird
|
||||||
|
|
||||||
|
# ULauncher
|
||||||
|
windowrulev2 = forceinput,class:^(ulauncher)$
|
||||||
|
windowrulev2 = dimaround,class:^(ulauncher)$
|
||||||
|
|
||||||
|
|
||||||
|
# Flameshot
|
||||||
|
windowrulev2 = nofullscreenrequest,title:^(flameshot)$
|
||||||
|
windowrulev2 = float,title:^(flameshot)$
|
||||||
|
windowrulev2 = move 0 -1080,title:^(flameshot)$
|
||||||
|
windowrulev2 = noanim,title:^(flameshot)$
|
||||||
|
windowrulev2 = rounding 0,title:^(flameshot)$
|
7
hypr/hyprpaper.conf
Normal file
7
hypr/hyprpaper.conf
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
preload = ~/Pictures/Wallpapers/digital-art-16-1920×1080.jpg
|
||||||
|
preload = ~/Pictures/Wallpapers/old-island-3-3840×2160.jpg
|
||||||
|
preload = ~/Pictures/Wallpapers/lava-dragon-3-1920×1080.jpg
|
||||||
|
|
||||||
|
wallpaper = DP-2, ~/Pictures/Wallpapers/digital-art-16-1920×1080.jpg
|
||||||
|
wallpaper = HDMI-A-1, ~/Pictures/Wallpapers/old-island-3-3840×2160.jpg
|
||||||
|
wallpaper = HDMI-A-2, ~/Pictures/Wallpapers/lava-dragon-3-1920×1080.jpg
|
4
kitty/kitty.conf
Normal file
4
kitty/kitty.conf
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
font_family Fira Code
|
||||||
|
|
||||||
|
background_opacity 0.8
|
||||||
|
allow_remote_control yes
|
|
@ -1,43 +0,0 @@
|
||||||
{
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
home-manager.users.kalle = {
|
|
||||||
programs.bash = {
|
|
||||||
enable = true;
|
|
||||||
shellAliases = {
|
|
||||||
# Replace some commands with better versions
|
|
||||||
diff = "${pkgs.difftastic}/bin/difft";
|
|
||||||
};
|
|
||||||
initExtra = ''
|
|
||||||
function open() {
|
|
||||||
xdg-open $@ &> /dev/null &
|
|
||||||
}
|
|
||||||
|
|
||||||
# Fzf for command history
|
|
||||||
if command -v fzf-share >/dev/null; then
|
|
||||||
source "$(fzf-share)/key-bindings.bash"
|
|
||||||
source "$(fzf-share)/completion.bash"
|
|
||||||
fi
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.starship = {
|
|
||||||
enable = true;
|
|
||||||
settings = {
|
|
||||||
add_newline = true;
|
|
||||||
|
|
||||||
# Remove text from nix shell component
|
|
||||||
nix_shell.format = "via [$symbol]($style) ";
|
|
||||||
|
|
||||||
git_status.disabled = true;
|
|
||||||
package.disabled = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
home.packages = with pkgs; [
|
|
||||||
fzf
|
|
||||||
];
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,19 +0,0 @@
|
||||||
{
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
imports = [
|
|
||||||
./monitor.nix
|
|
||||||
./bash.nix
|
|
||||||
./kitty.nix
|
|
||||||
./nvim
|
|
||||||
./kdeglobals.nix
|
|
||||||
./menus
|
|
||||||
./zoxide.nix
|
|
||||||
];
|
|
||||||
|
|
||||||
home-manager.users.kalle.home.packages = with pkgs; [
|
|
||||||
htop
|
|
||||||
];
|
|
||||||
}
|
|
|
@ -1,32 +0,0 @@
|
||||||
{
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
|
|
||||||
options.kdeglobals = lib.mkOption {
|
|
||||||
type = lib.types.nullOr lib.types.attrs;
|
|
||||||
default = null;
|
|
||||||
description = ''
|
|
||||||
Uses `lib.generators.toINI` to generate a kde configuration file that
|
|
||||||
is symlinked to `kdeglobals` inside the XDG configuration home. Do NOT
|
|
||||||
enable this module and set this when your system is running Plasma, this
|
|
||||||
can cause issues including inability to boot the DE properly.
|
|
||||||
|
|
||||||
Configuring this can be useful when running KDE applications or the
|
|
||||||
Breeze theme outside of Plasma because some of their features rely on
|
|
||||||
settings defined in this file (e.g. custom coloring in Breeze partially
|
|
||||||
relies on values defined here, applications like Dolphin read the
|
|
||||||
default terminal from this file).
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
config = {
|
|
||||||
home-manager.users.kalle.xdg.configFile = {
|
|
||||||
${if config.kdeglobals != null then "kdeglobals" else null}.text =
|
|
||||||
lib.generators.toINI { }
|
|
||||||
config.kdeglobals;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,20 +0,0 @@
|
||||||
{
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
home-manager.users.kalle.programs.kitty = {
|
|
||||||
enable = true;
|
|
||||||
themeFile = "Catppuccin-Mocha";
|
|
||||||
settings = {
|
|
||||||
background_opacity = "0.8";
|
|
||||||
allow_remote_control = true;
|
|
||||||
enable_audio_bell = false;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
kdeglobals = {
|
|
||||||
General = {
|
|
||||||
TerminalApplication = "kitty";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,5 +0,0 @@
|
||||||
{ ... }:
|
|
||||||
{
|
|
||||||
home-manager.users.kalle.xdg.configFile."menus/applications.menu".source =
|
|
||||||
./plasma-applications.menu;
|
|
||||||
}
|
|
|
@ -1,417 +0,0 @@
|
||||||
<!DOCTYPE Menu PUBLIC "-//freedesktop//DTD Menu 1.0//EN"
|
|
||||||
"http://www.freedesktop.org/standards/menu-spec/1.0/menu.dtd">
|
|
||||||
|
|
||||||
<!--
|
|
||||||
The plasma-applications.menu file is copied directly from
|
|
||||||
https://github.com/KDE/plasma-workspace/commits/master/menu/desktop/plasma-applications.menu
|
|
||||||
at hash 11e7f5306fa013ec5c2b894a28457dabf5c42bad
|
|
||||||
It would certainly be more desirable to just have this file be a
|
|
||||||
flake-input, but alas, flake inputs do not support sparse repo checkouts,
|
|
||||||
and I don't wanna pull in half of the Plasma source (100+ MiB) for a single
|
|
||||||
few KiB file. In any case, even if this file gets outdated compared to the
|
|
||||||
newer version it is VERY unlikely this would actually break anything
|
|
||||||
(unless we go from Plasma 6 to 7 or something).
|
|
||||||
-->
|
|
||||||
|
|
||||||
<Menu>
|
|
||||||
<Name>Applications</Name>
|
|
||||||
<Directory>kde-main.directory</Directory>
|
|
||||||
<!-- Search the default locations -->
|
|
||||||
<DefaultAppDirs/>
|
|
||||||
<DefaultDirectoryDirs/>
|
|
||||||
<DefaultLayout>
|
|
||||||
<Merge type="menus"/>
|
|
||||||
<Merge type="files"/>
|
|
||||||
<Separator/>
|
|
||||||
<Menuname>More</Menuname>
|
|
||||||
</DefaultLayout>
|
|
||||||
<Layout>
|
|
||||||
<Merge type="menus"/>
|
|
||||||
<Menuname>Applications</Menuname>
|
|
||||||
<Merge type="files"/>
|
|
||||||
</Layout>
|
|
||||||
|
|
||||||
<Menu>
|
|
||||||
<Name>Applications</Name>
|
|
||||||
<Directory>kf5-unknown.directory</Directory>
|
|
||||||
<OnlyUnallocated/>
|
|
||||||
<Include>
|
|
||||||
<Not>
|
|
||||||
<!-- Don't list non-KDE core applications -->
|
|
||||||
<And>
|
|
||||||
<Category>Core</Category>
|
|
||||||
<Not><Category>KDE</Category></Not>
|
|
||||||
</And>
|
|
||||||
<!-- Don't list SUSE's YaST in here -->
|
|
||||||
<Category>X-SuSE-YaST</Category>
|
|
||||||
<Category>X-KDE-settings-hardware</Category>
|
|
||||||
<Category>X-KDE-settings-accessibility</Category>
|
|
||||||
<Category>X-KDE-settings-components</Category>
|
|
||||||
<Category>X-KDE-settings-desktop</Category>
|
|
||||||
<Category>X-KDE-settings-looknfeel</Category>
|
|
||||||
<Category>X-KDE-settings-network</Category>
|
|
||||||
<Category>X-KDE-settings-webbrowsing</Category>
|
|
||||||
<Category>X-KDE-settings-peripherals</Category>
|
|
||||||
<Category>X-KDE-settings-hardware</Category>
|
|
||||||
<Category>X-KDE-settings-power</Category>
|
|
||||||
<Category>X-KDE-settings-security</Category>
|
|
||||||
<Category>X-KDE-settings-sound</Category>
|
|
||||||
<Category>X-KDE-settings-system</Category>
|
|
||||||
<Category>X-KDE-information</Category>
|
|
||||||
<Filename>kde-kcm_knetworkconfmodule_ss.desktop</Filename>
|
|
||||||
<Filename>kde-medianotifications.desktop</Filename>
|
|
||||||
<Filename>kde-audioencoding.desktop</Filename>
|
|
||||||
</Not>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>Development</Name>
|
|
||||||
<Directory>kf5-development.directory</Directory>
|
|
||||||
<Menu>
|
|
||||||
<Name>Translation</Name>
|
|
||||||
<Directory>kf5-development-translation.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Development</Category>
|
|
||||||
<Category>Translation</Category>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>Web Development</Name>
|
|
||||||
<Directory>kf5-development-webdevelopment.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Development</Category>
|
|
||||||
<Category>WebDevelopment</Category>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Development</Category>
|
|
||||||
<Not><Category>Translation</Category></Not>
|
|
||||||
<Not><Category>WebDevelopment</Category></Not>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>Science</Name>
|
|
||||||
<Directory>kf5-science.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And><!-- Include /any/ Science app which is not an Education app -->
|
|
||||||
<Or>
|
|
||||||
<Category>Astronomy</Category>
|
|
||||||
<Category>Biology</Category>
|
|
||||||
<Category>Chemistry</Category>
|
|
||||||
<Category>Geology</Category>
|
|
||||||
<Category>MedicalSoftware</Category>
|
|
||||||
<Category>Physics</Category>
|
|
||||||
<Category>Math</Category>
|
|
||||||
<Category>Science</Category>
|
|
||||||
</Or>
|
|
||||||
<Not><Category>Education</Category></Not>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>Education</Name>
|
|
||||||
<Directory>kf5-education.directory</Directory>
|
|
||||||
<Menu>
|
|
||||||
<Name>Languages</Name>
|
|
||||||
<Directory>kf5-edu-languages.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Education</Category>
|
|
||||||
<Category>Languages</Category>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>Mathematics</Name>
|
|
||||||
<Directory>kf5-edu-mathematics.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Education</Category>
|
|
||||||
<Category>Math</Category>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>Miscellaneous</Name>
|
|
||||||
<Directory>kf5-edu-miscellaneous.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Education</Category>
|
|
||||||
<Not>
|
|
||||||
<Category>Languages</Category>
|
|
||||||
<Category>Math</Category>
|
|
||||||
<Category>Science</Category>
|
|
||||||
<Category>Teaching</Category>
|
|
||||||
</Not>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>Science</Name>
|
|
||||||
<Directory>kf5-edu-science.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Education</Category>
|
|
||||||
<Category>Science</Category>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>Tools</Name>
|
|
||||||
<Directory>kf5-edu-tools.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Education</Category>
|
|
||||||
<Category>Teaching</Category>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>Games</Name>
|
|
||||||
<Directory>kf5-games.directory</Directory>
|
|
||||||
<Menu>
|
|
||||||
<Name>Arcade</Name>
|
|
||||||
<Directory>kf5-games-arcade.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Game</Category>
|
|
||||||
<Category>ArcadeGame</Category>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>Board</Name>
|
|
||||||
<Directory>kf5-games-board.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Game</Category>
|
|
||||||
<Category>BoardGame</Category>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>Card</Name>
|
|
||||||
<Directory>kf5-games-card.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Game</Category>
|
|
||||||
<Category>CardGame</Category>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>Kidsgames</Name>
|
|
||||||
<Directory>kf5-games-kids.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Game</Category>
|
|
||||||
<Category>KidsGame</Category>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>TacticStrategy</Name>
|
|
||||||
<Directory>kf5-games-strategy.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Game</Category>
|
|
||||||
<Category>StrategyGame</Category>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>Logic</Name>
|
|
||||||
<Directory>kf5-games-logic.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Game</Category>
|
|
||||||
<Category>LogicGame</Category>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Game</Category>
|
|
||||||
<Not>
|
|
||||||
<Category>ArcadeGame</Category>
|
|
||||||
<Category>BoardGame</Category>
|
|
||||||
<Category>CardGame</Category>
|
|
||||||
<Category>KidsGame</Category>
|
|
||||||
<Category>StrategyGame</Category>
|
|
||||||
<Category>LogicGame</Category>
|
|
||||||
</Not>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>Graphics</Name>
|
|
||||||
<Directory>kf5-graphics.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Graphics</Category>
|
|
||||||
<Not><Category>X-KDE-More</Category></Not>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
<Menu>
|
|
||||||
<Name>More</Name>
|
|
||||||
<Directory>kf5-more.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Graphics</Category>
|
|
||||||
<Category>X-KDE-More</Category>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>Internet</Name>
|
|
||||||
<Directory>kf5-internet.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Network</Category>
|
|
||||||
<Not><Category>X-KDE-More</Category></Not>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
<Menu>
|
|
||||||
<Name>Terminal</Name>
|
|
||||||
<Directory>kf5-internet-terminal.directory</Directory>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>More</Name>
|
|
||||||
<Directory>kf5-more.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Network</Category>
|
|
||||||
<Category>X-KDE-More</Category>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>Multimedia</Name>
|
|
||||||
<Directory>kf5-multimedia.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>AudioVideo</Category>
|
|
||||||
<Not><Category>X-KDE-More</Category></Not>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
<Menu>
|
|
||||||
<Name>More</Name>
|
|
||||||
<Directory>kf5-more.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>AudioVideo</Category>
|
|
||||||
<Category>X-KDE-More</Category>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>Office</Name>
|
|
||||||
<Directory>kf5-office.directory</Directory>
|
|
||||||
<Layout>
|
|
||||||
<Merge type="menus"/>
|
|
||||||
<Filename>kde-koshell.desktop</Filename>
|
|
||||||
<Filename>kde-Kontact.desktop</Filename>
|
|
||||||
<Separator/>
|
|
||||||
<Filename>kde-kword.desktop</Filename>
|
|
||||||
<Filename>kde-kspread.desktop</Filename>
|
|
||||||
<Filename>kde-kpresenter.desktop</Filename>
|
|
||||||
<Merge type="files"/>
|
|
||||||
<Separator/>
|
|
||||||
<Menuname>More</Menuname>
|
|
||||||
</Layout>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Office</Category>
|
|
||||||
<Not><Category>X-KDE-More</Category></Not>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
<Menu>
|
|
||||||
<Name>More</Name>
|
|
||||||
<Directory>kf5-more.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Office</Category>
|
|
||||||
<Category>X-KDE-More</Category>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>System</Name>
|
|
||||||
<Directory>kf5-system.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<Category>Settings</Category>
|
|
||||||
<And>
|
|
||||||
<Category>System</Category>
|
|
||||||
<Not><Category>X-KDE-More</Category></Not>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
<Menu>
|
|
||||||
<Name>More</Name>
|
|
||||||
<Directory>kf5-more.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>System</Category>
|
|
||||||
<Category>X-KDE-More</Category>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>ScreenSavers</Name>
|
|
||||||
<Directory>kf5-system-screensavers.directory</Directory>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>Terminal</Name>
|
|
||||||
<Directory>kf5-system-terminal.directory</Directory>
|
|
||||||
</Menu>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>Utilities</Name>
|
|
||||||
<Directory>kf5-utilities.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Utility</Category>
|
|
||||||
<Not><Category>X-KDE-More</Category></Not>
|
|
||||||
</And>
|
|
||||||
<Category>TextEditor</Category>
|
|
||||||
<Category>Accessibility</Category>
|
|
||||||
<Category>X-KDE-Utilities-Desktop</Category>
|
|
||||||
<Category>X-KDE-Utilities-File</Category>
|
|
||||||
<Category>X-KDE-Utilities-Peripherals</Category>
|
|
||||||
<Category>X-KDE-Utilities-PIM</Category>
|
|
||||||
</Include>
|
|
||||||
<Menu>
|
|
||||||
<Name>XUtilities</Name>
|
|
||||||
<Directory>kf5-utilities-xutils.directory</Directory>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>More</Name>
|
|
||||||
<Directory>kf5-more.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<And>
|
|
||||||
<Category>Utility</Category>
|
|
||||||
<Category>X-KDE-More</Category>
|
|
||||||
</And>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
</Menu>
|
|
||||||
<Menu>
|
|
||||||
<Name>Help</Name>
|
|
||||||
<Directory>kf5-help.directory</Directory>
|
|
||||||
<Include>
|
|
||||||
<Category>Documentation</Category>
|
|
||||||
</Include>
|
|
||||||
</Menu>
|
|
||||||
<DefaultMergeDirs/>
|
|
||||||
<MergeFile>applications-kmenuedit.menu</MergeFile>
|
|
||||||
</Menu>
|
|
|
@ -1,74 +0,0 @@
|
||||||
{
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
options =
|
|
||||||
let
|
|
||||||
inherit (lib) mkOption types;
|
|
||||||
mkStrOption =
|
|
||||||
default:
|
|
||||||
mkOption {
|
|
||||||
type = types.str;
|
|
||||||
default = default;
|
|
||||||
};
|
|
||||||
mkIntOption =
|
|
||||||
default:
|
|
||||||
mkOption {
|
|
||||||
type = types.int;
|
|
||||||
default = default;
|
|
||||||
};
|
|
||||||
mkBoolOption =
|
|
||||||
default:
|
|
||||||
mkOption {
|
|
||||||
type = types.bool;
|
|
||||||
default = default;
|
|
||||||
};
|
|
||||||
in
|
|
||||||
{
|
|
||||||
monitors = mkOption {
|
|
||||||
type = types.listOf (
|
|
||||||
types.submodule {
|
|
||||||
options = {
|
|
||||||
isPrimary = mkBoolOption false;
|
|
||||||
name = mkStrOption null;
|
|
||||||
width = mkIntOption 1920;
|
|
||||||
height = mkIntOption 1080;
|
|
||||||
refreshRate = mkIntOption 60;
|
|
||||||
x = mkIntOption 0;
|
|
||||||
y = mkIntOption 0;
|
|
||||||
transform = mkOption {
|
|
||||||
type = types.enum [
|
|
||||||
"normal"
|
|
||||||
"clockwise"
|
|
||||||
"flip"
|
|
||||||
"counterclockwise"
|
|
||||||
];
|
|
||||||
default = "normal";
|
|
||||||
};
|
|
||||||
vrr = mkBoolOption false;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
);
|
|
||||||
default = [ ];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
config =
|
|
||||||
let
|
|
||||||
monitors = config.monitors;
|
|
||||||
primaryMonitor = lib.findSingle (m: m.isPrimary) "none" "multiple" monitors;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
assertions = [
|
|
||||||
{
|
|
||||||
assertion = primaryMonitor != "none";
|
|
||||||
message = "No primary monitor";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
assertion = primaryMonitor != "multiple";
|
|
||||||
message = "Multiple primary monitors";
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,131 +0,0 @@
|
||||||
{
|
|
||||||
pkgs,
|
|
||||||
outputs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
|
|
||||||
{
|
|
||||||
nixpkgs = {
|
|
||||||
overlays = with outputs.overlays; [ nvim-plugins ];
|
|
||||||
};
|
|
||||||
|
|
||||||
home-manager.users.kalle.programs.neovim =
|
|
||||||
let
|
|
||||||
toLua = str: "lua << EOF\n${str}\nEOF\n";
|
|
||||||
toLuaFile = file: "lua << EOF\n${builtins.readFile file}\nEOF\n";
|
|
||||||
in
|
|
||||||
{
|
|
||||||
enable = true;
|
|
||||||
|
|
||||||
viAlias = true;
|
|
||||||
vimAlias = true;
|
|
||||||
vimdiffAlias = true;
|
|
||||||
|
|
||||||
extraPackages = with pkgs; [
|
|
||||||
ripgrep # Required for telescope
|
|
||||||
wl-clipboard # Required for clipboard sync
|
|
||||||
|
|
||||||
# Language servers
|
|
||||||
clang-tools
|
|
||||||
lua-language-server
|
|
||||||
nodePackages.typescript-language-server
|
|
||||||
nodePackages."@astrojs/language-server"
|
|
||||||
typescript
|
|
||||||
tailwindcss-language-server
|
|
||||||
gopls
|
|
||||||
vhdl-ls
|
|
||||||
nixd
|
|
||||||
nixfmt-rfc-style
|
|
||||||
];
|
|
||||||
|
|
||||||
plugins = with pkgs.vimPlugins; [
|
|
||||||
yuck-vim
|
|
||||||
|
|
||||||
{
|
|
||||||
plugin = which-key-nvim;
|
|
||||||
config = toLua "require('which-key').setup()";
|
|
||||||
}
|
|
||||||
|
|
||||||
neodev-nvim
|
|
||||||
plenary-nvim
|
|
||||||
|
|
||||||
{
|
|
||||||
plugin = telescope-nvim;
|
|
||||||
config = toLuaFile ./plugin/telescope.lua;
|
|
||||||
}
|
|
||||||
telescope-ui-select-nvim
|
|
||||||
|
|
||||||
FTerm-nvim
|
|
||||||
|
|
||||||
vim-fugitive
|
|
||||||
|
|
||||||
harpoon1
|
|
||||||
|
|
||||||
{
|
|
||||||
plugin = undotree-nvim;
|
|
||||||
config = toLua "require('undotree').setup()";
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
plugin = comment-nvim;
|
|
||||||
config = toLua "require('Comment').setup()";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
plugin = todo-comments-nvim;
|
|
||||||
config = toLua "require('todo-comments').setup()";
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
plugin = neoconf-nvim;
|
|
||||||
config = toLua "require('neoconf').setup()";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
plugin = catppuccin-nvim;
|
|
||||||
config = "colorscheme catppuccin-mocha";
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
plugin = oil-nvim;
|
|
||||||
config = toLua "require('oil').setup()";
|
|
||||||
}
|
|
||||||
|
|
||||||
cmp-nvim-lsp
|
|
||||||
cmp-nvim-lsp-signature-help
|
|
||||||
cmp-buffer
|
|
||||||
cmp-path
|
|
||||||
cmp-cmdline
|
|
||||||
cmp-git
|
|
||||||
cmp-calc
|
|
||||||
cmp_luasnip
|
|
||||||
luasnip
|
|
||||||
friendly-snippets
|
|
||||||
{
|
|
||||||
plugin = nvim-cmp;
|
|
||||||
config = toLuaFile ./plugin/cmp.lua;
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
plugin = nvim-lspconfig;
|
|
||||||
config = toLuaFile ./plugin/lsp.lua;
|
|
||||||
}
|
|
||||||
rust-tools-nvim
|
|
||||||
{
|
|
||||||
plugin = fidget-nvim;
|
|
||||||
config = toLua "require('fidget').setup({})";
|
|
||||||
}
|
|
||||||
|
|
||||||
rainbow-delimiters-nvim
|
|
||||||
|
|
||||||
{
|
|
||||||
plugin = (nvim-treesitter.withAllGrammars);
|
|
||||||
config = toLuaFile ./plugin/treesitter.lua;
|
|
||||||
}
|
|
||||||
];
|
|
||||||
|
|
||||||
extraLuaConfig = ''
|
|
||||||
${builtins.readFile ./options.lua}
|
|
||||||
${builtins.readFile ./keymaps.lua}
|
|
||||||
'';
|
|
||||||
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,99 +0,0 @@
|
||||||
local cmp = require 'cmp'
|
|
||||||
local luasnip = require 'luasnip'
|
|
||||||
|
|
||||||
local has_words_before = function()
|
|
||||||
if vim.api.nvim_buf_get_option(0, "buftype") == "prompt" then return false end
|
|
||||||
local line, col = unpack(vim.api.nvim_win_get_cursor(0))
|
|
||||||
return col ~= 0 and vim.api.nvim_buf_get_text(0, line - 1, 0, line - 1, col, {})[1]:match("^%s*$") == nil
|
|
||||||
end
|
|
||||||
|
|
||||||
cmp.setup({
|
|
||||||
snippet = {
|
|
||||||
expand = function(args)
|
|
||||||
luasnip.lsp_expand(args.body)
|
|
||||||
end,
|
|
||||||
},
|
|
||||||
mapping = cmp.mapping.preset.insert({
|
|
||||||
['<C-p>'] = cmp.mapping.select_prev_item(),
|
|
||||||
['<C-n>'] = cmp.mapping.select_next_item(),
|
|
||||||
-- Add tab support
|
|
||||||
['<S-Tab>'] = cmp.mapping(function(fallback)
|
|
||||||
if cmp.visible() then
|
|
||||||
cmp.select_prev_item()
|
|
||||||
elseif luasnip.jumpable(-1) then
|
|
||||||
luasnip.jump(-1)
|
|
||||||
else
|
|
||||||
fallback()
|
|
||||||
end
|
|
||||||
end, { 'i', 's' }),
|
|
||||||
['<Tab>'] = cmp.mapping(function(fallback)
|
|
||||||
if cmp.visible() and has_words_before() then
|
|
||||||
cmp.select_next_item()
|
|
||||||
elseif luasnip.expand_or_jumpable() then
|
|
||||||
luasnip.expand_or_jump()
|
|
||||||
else
|
|
||||||
fallback()
|
|
||||||
end
|
|
||||||
end, { 'i', 's' }),
|
|
||||||
['<C-f>'] = cmp.mapping.scroll_docs(-4),
|
|
||||||
['<C-d>'] = cmp.mapping.scroll_docs(4),
|
|
||||||
['<C-Space>'] = cmp.mapping.complete(),
|
|
||||||
['<C-e>'] = cmp.mapping.close(),
|
|
||||||
['<CR>'] = cmp.mapping.confirm({
|
|
||||||
behavior = cmp.ConfirmBehavior.Insert,
|
|
||||||
select = true,
|
|
||||||
})
|
|
||||||
}),
|
|
||||||
sources = cmp.config.sources({
|
|
||||||
{ name = 'path' }, -- file paths
|
|
||||||
{ name = 'nvim_lsp' }, -- from language server
|
|
||||||
{ name = 'nvim_lsp_signature_help' }, -- display function signatures with current parameter emphasized
|
|
||||||
{ name = 'luasnip' },
|
|
||||||
{ name = 'nvim_lua' }, -- complete neovim's Lua runtime API such vim.lsp.*
|
|
||||||
{ name = 'buffer' }, -- source current buffer
|
|
||||||
{ name = 'calc' }, -- source for math calculation
|
|
||||||
}),
|
|
||||||
window = {
|
|
||||||
completion = cmp.config.window.bordered(),
|
|
||||||
documentation = cmp.config.window.bordered(),
|
|
||||||
},
|
|
||||||
formatting = {
|
|
||||||
fields = { 'menu', 'abbr', 'kind' },
|
|
||||||
format = function(entry, item)
|
|
||||||
local menu_icon = {
|
|
||||||
nvim_lsp = 'λ',
|
|
||||||
vsnip = '⋗',
|
|
||||||
buffer = 'Ω',
|
|
||||||
path = '🖫',
|
|
||||||
}
|
|
||||||
item.menu = menu_icon[entry.source.name]
|
|
||||||
return item
|
|
||||||
end,
|
|
||||||
},
|
|
||||||
})
|
|
||||||
|
|
||||||
cmp.setup.filetype('gitcommit', {
|
|
||||||
sources = cmp.config.sources({
|
|
||||||
{ name = 'cmp_git' }, -- You can specify the `cmp_git` source if you were installed it.
|
|
||||||
}, {
|
|
||||||
{ name = 'buffer' },
|
|
||||||
})
|
|
||||||
})
|
|
||||||
|
|
||||||
-- Use buffer source for `/` (if you enabled `native_menu`, this won't work anymore).
|
|
||||||
cmp.setup.cmdline('/', {
|
|
||||||
mapping = cmp.mapping.preset.cmdline(),
|
|
||||||
sources = {
|
|
||||||
{ name = 'buffer' }
|
|
||||||
}
|
|
||||||
})
|
|
||||||
|
|
||||||
-- Use cmdline & path source for ':' (if you enabled `native_menu`, this won't work anymore).
|
|
||||||
cmp.setup.cmdline(':', {
|
|
||||||
mapping = cmp.mapping.preset.cmdline(),
|
|
||||||
sources = cmp.config.sources({
|
|
||||||
{ name = 'path' }
|
|
||||||
}, {
|
|
||||||
{ name = 'cmdline' }
|
|
||||||
})
|
|
||||||
})
|
|
|
@ -1,170 +0,0 @@
|
||||||
local on_attach = function(_, bufnr)
|
|
||||||
local nmap = function(keys, func, desc)
|
|
||||||
if desc then
|
|
||||||
desc = 'LSP: ' .. desc
|
|
||||||
end
|
|
||||||
|
|
||||||
vim.keymap.set('n', keys, func, { buffer = bufnr, desc = desc })
|
|
||||||
end
|
|
||||||
|
|
||||||
nmap('<leader>rn', vim.lsp.buf.rename, '[R]e[n]ame')
|
|
||||||
nmap('<leader>ca', vim.lsp.buf.code_action, '[C]ode [A]ction')
|
|
||||||
|
|
||||||
nmap('gd', require('telescope.builtin').lsp_definitions, '[G]oto [D]efinition')
|
|
||||||
nmap('gr', require('telescope.builtin').lsp_references, '[G]oto [R]eferences')
|
|
||||||
nmap('gI', require('telescope.builtin').lsp_implementations, '[G]oto [I]mplementation')
|
|
||||||
nmap('<leader>D', require('telescope.builtin').lsp_type_definitions, 'Type [D]efinition')
|
|
||||||
nmap('<leader>ds', require('telescope.builtin').lsp_document_symbols, '[D]ocument [S]ymbols')
|
|
||||||
nmap('<leader>ws', require('telescope.builtin').lsp_dynamic_workspace_symbols, '[W]orkspace [S]ymbols')
|
|
||||||
|
|
||||||
-- See `:help K` for why this keymap
|
|
||||||
nmap('K', vim.lsp.buf.hover, 'Hover Documentation')
|
|
||||||
nmap('<C-k>', vim.lsp.buf.signature_help, 'Signature Documentation')
|
|
||||||
|
|
||||||
-- Lesser used LSP functionality
|
|
||||||
nmap('gD', vim.lsp.buf.declaration, '[G]oto [D]eclaration')
|
|
||||||
nmap('<leader>wa', vim.lsp.buf.add_workspace_folder, '[W]orkspace [A]dd Folder')
|
|
||||||
nmap('<leader>wr', vim.lsp.buf.remove_workspace_folder, '[W]orkspace [R]emove Folder')
|
|
||||||
nmap('<leader>wl', function()
|
|
||||||
print(vim.inspect(vim.lsp.buf.list_workspace_folders()))
|
|
||||||
end, '[W]orkspace [L]ist Folders')
|
|
||||||
|
|
||||||
-- Create a command `:Format` local to the LSP buffer
|
|
||||||
vim.api.nvim_buf_create_user_command(bufnr, 'Format', function(_)
|
|
||||||
if vim.lsp.buf.format then
|
|
||||||
vim.lsp.buf.format()
|
|
||||||
elseif vim.lsp.buf.formatting then
|
|
||||||
vim.lsp.buf.formatting()
|
|
||||||
end
|
|
||||||
end, { desc = 'Format current buffer with LSP' })
|
|
||||||
end
|
|
||||||
|
|
||||||
-- LSP Diagnostics Options Setup
|
|
||||||
local sign = function(opts)
|
|
||||||
vim.fn.sign_define(opts.name, {
|
|
||||||
texthl = opts.name,
|
|
||||||
text = opts.text,
|
|
||||||
numhl = ''
|
|
||||||
})
|
|
||||||
end
|
|
||||||
|
|
||||||
sign({ name = 'DiagnosticSignError', text = '' })
|
|
||||||
sign({ name = 'DiagnosticSignWarn', text = '' })
|
|
||||||
sign({ name = 'DiagnosticSignHint', text = '' })
|
|
||||||
sign({ name = 'DiagnosticSignInfo', text = '' })
|
|
||||||
|
|
||||||
vim.diagnostic.config({
|
|
||||||
virtual_text = false,
|
|
||||||
signs = true,
|
|
||||||
update_in_insert = true,
|
|
||||||
underline = true,
|
|
||||||
severity_sort = false,
|
|
||||||
float = {
|
|
||||||
border = 'rounded',
|
|
||||||
source = 'always',
|
|
||||||
header = '',
|
|
||||||
prefix = '',
|
|
||||||
},
|
|
||||||
})
|
|
||||||
|
|
||||||
vim.cmd([[
|
|
||||||
autocmd CursorHold * lua vim.diagnostic.open_float(nil, { focusable = false })
|
|
||||||
]])
|
|
||||||
|
|
||||||
-- LSP Configuration
|
|
||||||
|
|
||||||
local capabilities = vim.lsp.protocol.make_client_capabilities()
|
|
||||||
capabilities = require('cmp_nvim_lsp').default_capabilities(capabilities)
|
|
||||||
|
|
||||||
require('neodev').setup({
|
|
||||||
override = function(root_dir, library)
|
|
||||||
if root_dir:find("/home/kalle/.dots", 1, true) == 1 then
|
|
||||||
library.enabled = true
|
|
||||||
library.plugins = true
|
|
||||||
end
|
|
||||||
end,
|
|
||||||
})
|
|
||||||
|
|
||||||
require('lspconfig').lua_ls.setup {
|
|
||||||
on_attach = on_attach,
|
|
||||||
capabilities = capabilities,
|
|
||||||
root_dir = function()
|
|
||||||
return vim.loop.cwd()
|
|
||||||
end,
|
|
||||||
cmd = { "lua-language-server" },
|
|
||||||
settings = {
|
|
||||||
Lua = {
|
|
||||||
workspace = { checkThirdParty = false },
|
|
||||||
telemetry = { enable = false },
|
|
||||||
},
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
require('lspconfig').nixd.setup {
|
|
||||||
on_attach = on_attach,
|
|
||||||
capabilities = capabilities,
|
|
||||||
settings = {
|
|
||||||
nixd = {
|
|
||||||
formatting = {
|
|
||||||
command = { "nixfmt" },
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
require('lspconfig').ts_ls.setup {
|
|
||||||
on_attach = on_attach,
|
|
||||||
capabilities = capabilities,
|
|
||||||
init_options = {
|
|
||||||
tsserver = {
|
|
||||||
fallbackPath = string.gsub(vim.fn.system("dirname `which tsserver`"), '^%s*(.-)%s*$', '%1') .. "/../lib/node_modules/typescript/lib",
|
|
||||||
},
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
require('lspconfig').tailwindcss.setup {
|
|
||||||
on_attach = on_attach,
|
|
||||||
capabilities = capabilities,
|
|
||||||
}
|
|
||||||
|
|
||||||
require('lspconfig').clangd.setup {
|
|
||||||
on_attach = on_attach,
|
|
||||||
capabilities = capabilities,
|
|
||||||
}
|
|
||||||
|
|
||||||
require('lspconfig').gopls.setup {
|
|
||||||
on_attach = on_attach,
|
|
||||||
capabilities = capabilities,
|
|
||||||
}
|
|
||||||
|
|
||||||
require('lspconfig').vhdl_ls.setup {
|
|
||||||
on_attach = on_attach,
|
|
||||||
capabilities = capabilities,
|
|
||||||
}
|
|
||||||
|
|
||||||
require('lspconfig').astro.setup {
|
|
||||||
on_attach = on_attach,
|
|
||||||
capabilities = capabilities,
|
|
||||||
}
|
|
||||||
|
|
||||||
require('rust-tools').setup({
|
|
||||||
server = {
|
|
||||||
on_attach = on_attach,
|
|
||||||
settings = {
|
|
||||||
["rust-analyzer"] = {
|
|
||||||
checkOnSave = true,
|
|
||||||
},
|
|
||||||
}
|
|
||||||
},
|
|
||||||
})
|
|
||||||
|
|
||||||
-- Workaround for https://github.com/neovim/neovim/issues/30985
|
|
||||||
for _, method in ipairs({ 'textDocument/diagnostic', 'workspace/diagnostic' }) do
|
|
||||||
local default_diagnostic_handler = vim.lsp.handlers[method]
|
|
||||||
vim.lsp.handlers[method] = function(err, result, context, config)
|
|
||||||
if err ~= nil and err.code == -32802 then
|
|
||||||
return
|
|
||||||
end
|
|
||||||
return default_diagnostic_handler(err, result, context, config)
|
|
||||||
end
|
|
||||||
end
|
|
|
@ -1,13 +0,0 @@
|
||||||
require('telescope').setup {
|
|
||||||
defaults = {
|
|
||||||
mappings = {
|
|
||||||
i = {
|
|
||||||
['<C-u>'] = false,
|
|
||||||
['<C-d>'] = false,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
require("telescope").load_extension("ui-select")
|
|
||||||
pcall(require('telescope').load_extension, 'fzf')
|
|
|
@ -1,9 +0,0 @@
|
||||||
require('nvim-treesitter.configs').setup {
|
|
||||||
ensure_installed = {},
|
|
||||||
|
|
||||||
auto_install = false,
|
|
||||||
|
|
||||||
highlight = { enable = true },
|
|
||||||
|
|
||||||
indent = { enable = true },
|
|
||||||
}
|
|
|
@ -1,4 +0,0 @@
|
||||||
{ ... }:
|
|
||||||
{
|
|
||||||
home-manager.users.kalle.programs.zoxide.enable = true;
|
|
||||||
}
|
|
|
@ -1,8 +0,0 @@
|
||||||
{
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
home-manager.users.kalle.programs.chromium = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,11 +0,0 @@
|
||||||
{
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
home-manager.users.kalle.programs.firefox = {
|
|
||||||
enable = true;
|
|
||||||
nativeMessagingHosts = [ pkgs.kdePackages.plasma-browser-integration ];
|
|
||||||
};
|
|
||||||
|
|
||||||
}
|
|
|
@ -1,10 +0,0 @@
|
||||||
{
|
|
||||||
inputs,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
home-manager.users.kalle.home.packages = [
|
|
||||||
inputs.zen-browser.packages.${pkgs.system}.default
|
|
||||||
];
|
|
||||||
}
|
|
|
@ -1,21 +0,0 @@
|
||||||
{ pkgs, ... }:
|
|
||||||
{
|
|
||||||
imports = [
|
|
||||||
./dolphin.nix
|
|
||||||
];
|
|
||||||
home-manager.users.kalle.home.packages =
|
|
||||||
with pkgs;
|
|
||||||
[
|
|
||||||
vlc
|
|
||||||
feishin
|
|
||||||
pavucontrol
|
|
||||||
inkscape
|
|
||||||
gimp
|
|
||||||
krita
|
|
||||||
]
|
|
||||||
++ (with pkgs.kdePackages; [
|
|
||||||
kate
|
|
||||||
gwenview
|
|
||||||
okular
|
|
||||||
]);
|
|
||||||
}
|
|
|
@ -1,20 +0,0 @@
|
||||||
{
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
kdeglobals = {
|
|
||||||
PreviewSettings = {
|
|
||||||
EnableRemoteFolderThumbnail = false;
|
|
||||||
MaximumRemoteSize = 52428800;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
home-manager.users.kalle.home.packages = with pkgs.kdePackages; [
|
|
||||||
dolphin
|
|
||||||
ark
|
|
||||||
qtsvg
|
|
||||||
kio-fuse
|
|
||||||
kio-extras
|
|
||||||
];
|
|
||||||
}
|
|
|
@ -1,19 +0,0 @@
|
||||||
{
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
imports = [
|
|
||||||
./git.nix
|
|
||||||
./direnv.nix
|
|
||||||
./fd.nix
|
|
||||||
./ripgrep.nix
|
|
||||||
];
|
|
||||||
|
|
||||||
home-manager.users.kalle.home.packages = with pkgs; [
|
|
||||||
httpie
|
|
||||||
gcc
|
|
||||||
jq
|
|
||||||
difftastic
|
|
||||||
];
|
|
||||||
}
|
|
|
@ -1,8 +0,0 @@
|
||||||
{ ... }:
|
|
||||||
{
|
|
||||||
home-manager.users.kalle.programs.direnv = {
|
|
||||||
enable = true;
|
|
||||||
enableBashIntegration = true;
|
|
||||||
nix-direnv.enable = true;
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,14 +0,0 @@
|
||||||
{ ... }:
|
|
||||||
{
|
|
||||||
home-manager.users.kalle.programs.fd = {
|
|
||||||
enable = true;
|
|
||||||
extraOptions = [
|
|
||||||
"--hidden"
|
|
||||||
];
|
|
||||||
ignores = [
|
|
||||||
".git/"
|
|
||||||
"/nix/store"
|
|
||||||
".nix-profile"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,21 +0,0 @@
|
||||||
{
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
home-manager.users.kalle = {
|
|
||||||
programs.git = {
|
|
||||||
enable = true;
|
|
||||||
userName = "Kalle Struik";
|
|
||||||
userEmail = "kalle@kallestruik.nl";
|
|
||||||
extraConfig = {
|
|
||||||
init.defaultBranch = "main";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.bash.shellAliases = {
|
|
||||||
gg = "git log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold green)(%ar)%C(reset)%C(bold yellow)%d%C(reset)%n'' %C(white)%s%C(reset) %C(dim white)- %an (%ae)%C(reset)' --all";
|
|
||||||
gca = "git add -A; git commit -a --amend --no-edit";
|
|
||||||
gs = "git status";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,12 +0,0 @@
|
||||||
{ ... }:
|
|
||||||
{
|
|
||||||
home-manager.users.kalle.programs.ripgrep = {
|
|
||||||
enable = true;
|
|
||||||
arguments = [
|
|
||||||
"--hidden"
|
|
||||||
"--glob=!.nix-profile/*"
|
|
||||||
"--glob=!.git/*"
|
|
||||||
"--glob=!/nix/store/*"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,9 +0,0 @@
|
||||||
{
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
home-manager.users.kalle.home.packages = with pkgs; [
|
|
||||||
discord
|
|
||||||
];
|
|
||||||
}
|
|
|
@ -1,7 +0,0 @@
|
||||||
{ ... }:
|
|
||||||
{
|
|
||||||
imports = [
|
|
||||||
./steam.nix
|
|
||||||
./prismlauncher.nix
|
|
||||||
];
|
|
||||||
}
|
|
|
@ -1,9 +0,0 @@
|
||||||
{
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
home-manager.users.kalle.home.packages = with pkgs; [
|
|
||||||
prismlauncher
|
|
||||||
];
|
|
||||||
}
|
|
|
@ -1,34 +0,0 @@
|
||||||
{
|
|
||||||
lib,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
programs.steam = {
|
|
||||||
enable = true;
|
|
||||||
package = pkgs.steam.override {
|
|
||||||
extraPkgs =
|
|
||||||
pkgs: with pkgs; [
|
|
||||||
xorg.libXcursor
|
|
||||||
xorg.libXi
|
|
||||||
xorg.libXinerama
|
|
||||||
xorg.libXScrnSaver
|
|
||||||
libpng
|
|
||||||
libpulseaudio
|
|
||||||
libvorbis
|
|
||||||
stdenv.cc.cc.lib
|
|
||||||
libkrb5
|
|
||||||
keyutils
|
|
||||||
];
|
|
||||||
extraLibraries =
|
|
||||||
pkgs: with pkgs; [
|
|
||||||
gperftools # Needed for tf2 to work
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
|
||||||
gamescope
|
|
||||||
pkgsi686Linux.gperftools # Needed for tf2
|
|
||||||
];
|
|
||||||
}
|
|
|
@ -1,11 +0,0 @@
|
||||||
{
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
# Allow flashing ZSA keyboards
|
|
||||||
hardware.keyboard.zsa.enable = true;
|
|
||||||
environment.systemPackages = with pkgs; [
|
|
||||||
keymapp
|
|
||||||
];
|
|
||||||
}
|
|
2
modules/hyprland/ags/config/.gitignore
vendored
2
modules/hyprland/ags/config/.gitignore
vendored
|
@ -1,2 +0,0 @@
|
||||||
node_modules/
|
|
||||||
@girs/
|
|
|
@ -1,15 +0,0 @@
|
||||||
import { App } from "astal/gtk3"
|
|
||||||
import style from "./style.scss"
|
|
||||||
import LeftBar from "./widget/LeftBar"
|
|
||||||
import RightBar from "./widget/RightBar"
|
|
||||||
|
|
||||||
const LEFT_DISPLAY = "HF237"
|
|
||||||
const RIGHT_DISPLAY = "LCDTV16"
|
|
||||||
|
|
||||||
App.start({
|
|
||||||
css: style,
|
|
||||||
main() {
|
|
||||||
LeftBar(App.get_monitors().find(it => it.get_model() == LEFT_DISPLAY)!);
|
|
||||||
RightBar(App.get_monitors().find(it => it.get_model() == RIGHT_DISPLAY)!);
|
|
||||||
},
|
|
||||||
})
|
|
21
modules/hyprland/ags/config/env.d.ts
vendored
21
modules/hyprland/ags/config/env.d.ts
vendored
|
@ -1,21 +0,0 @@
|
||||||
declare const SRC: string
|
|
||||||
|
|
||||||
declare module "inline:*" {
|
|
||||||
const content: string
|
|
||||||
export default content
|
|
||||||
}
|
|
||||||
|
|
||||||
declare module "*.scss" {
|
|
||||||
const content: string
|
|
||||||
export default content
|
|
||||||
}
|
|
||||||
|
|
||||||
declare module "*.blp" {
|
|
||||||
const content: string
|
|
||||||
export default content
|
|
||||||
}
|
|
||||||
|
|
||||||
declare module "*.css" {
|
|
||||||
const content: string
|
|
||||||
export default content
|
|
||||||
}
|
|
|
@ -1 +0,0 @@
|
||||||
/nix/store/hd98qfcisszjr5prmb9dz0wd7fq74ffn-astal-gjs/share/astal/gjs
|
|
21
modules/hyprland/ags/config/package-lock.json
generated
21
modules/hyprland/ags/config/package-lock.json
generated
|
@ -1,21 +0,0 @@
|
||||||
{
|
|
||||||
"name": "astal-shell",
|
|
||||||
"lockfileVersion": 3,
|
|
||||||
"requires": true,
|
|
||||||
"packages": {
|
|
||||||
"": {
|
|
||||||
"name": "astal-shell",
|
|
||||||
"dependencies": {
|
|
||||||
"astal": "/home/kalle/.local/share/ags"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"../../../../../.local/share/ags": {
|
|
||||||
"name": "astal",
|
|
||||||
"license": "LGPL-2.1"
|
|
||||||
},
|
|
||||||
"node_modules/astal": {
|
|
||||||
"resolved": "../../../../../.local/share/ags",
|
|
||||||
"link": true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -1,6 +0,0 @@
|
||||||
{
|
|
||||||
"name": "astal-shell",
|
|
||||||
"dependencies": {
|
|
||||||
"astal": "/home/kalle/.local/share/ags"
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -1,96 +0,0 @@
|
||||||
// https://gitlab.gnome.org/GNOME/gtk/-/blob/gtk-3-24/gtk/theme/Adwaita/_colors-public.scss
|
|
||||||
@use 'sass:color';
|
|
||||||
|
|
||||||
@import "themes/catpuccin.scss";
|
|
||||||
|
|
||||||
window.Bar {
|
|
||||||
background: transparent;
|
|
||||||
color: $ctp-text;
|
|
||||||
|
|
||||||
>centerbox {
|
|
||||||
margin: 8px 8px 0 8px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.pill {
|
|
||||||
>.icon {
|
|
||||||
color: $ctp-surface-0;
|
|
||||||
padding: 6px 8px;
|
|
||||||
font-size: 18px;
|
|
||||||
}
|
|
||||||
|
|
||||||
&.icon-left {
|
|
||||||
&>.icon {
|
|
||||||
border-radius: 5px 0 0 5px;
|
|
||||||
}
|
|
||||||
&>.label {
|
|
||||||
border-radius: 0 5px 5px 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
&.icon-right {
|
|
||||||
&>.icon {
|
|
||||||
border-radius: 0 5px 5px 0;
|
|
||||||
}
|
|
||||||
&>.label {
|
|
||||||
border-radius: 5px 0 0 5px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
>.label {
|
|
||||||
background: $ctp-surface-0;
|
|
||||||
padding: 0 8px;
|
|
||||||
font-size: 16px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.Time >.icon {
|
|
||||||
background: $ctp-red;
|
|
||||||
}
|
|
||||||
|
|
||||||
.Date >.icon {
|
|
||||||
background: $ctp-lavender;
|
|
||||||
}
|
|
||||||
|
|
||||||
.Workspaces {
|
|
||||||
>.icon {
|
|
||||||
background: $ctp-blue;
|
|
||||||
}
|
|
||||||
|
|
||||||
>.label button {
|
|
||||||
all: unset;
|
|
||||||
|
|
||||||
&.add {
|
|
||||||
font-size: 12px;
|
|
||||||
margin-left: 4px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.Systray {
|
|
||||||
>.icon {
|
|
||||||
background: $ctp-green;
|
|
||||||
padding: 4px 8px 0 8px;
|
|
||||||
font-size: 20px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.items {
|
|
||||||
background: $ctp-surface-0;
|
|
||||||
font-size: 16px;
|
|
||||||
}
|
|
||||||
|
|
||||||
&.icon-left {
|
|
||||||
.items {
|
|
||||||
border-radius: 0 5px 5px 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
&.icon-right {
|
|
||||||
.items {
|
|
||||||
border-radius: 5px 0 0 5px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.item {
|
|
||||||
all: unset;
|
|
||||||
padding: 8px 8px;
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -1,27 +0,0 @@
|
||||||
$ctp-rosewater: #f5e0dc;
|
|
||||||
$ctp-flamingo: #f2cdcd;
|
|
||||||
$ctp-pink: #f5c2e7;
|
|
||||||
$ctp-mauve: #cba6f7;
|
|
||||||
$ctp-red: #f38ba8;
|
|
||||||
$ctp-maroon: #eba0ac;
|
|
||||||
$ctp-peach: #fab387;
|
|
||||||
$ctp-yellow: #f9e2af;
|
|
||||||
$ctp-green: #a6e3a1;
|
|
||||||
$ctp-teal: #94e2d5;
|
|
||||||
$ctp-sky: #89dceb;
|
|
||||||
$ctp-sapphire: #74c7ec;
|
|
||||||
$ctp-blue: #89b4fa;
|
|
||||||
$ctp-lavender: #b4befe;
|
|
||||||
$ctp-text: #cdd6f4;
|
|
||||||
$ctp-subtext-1: #bac2de;
|
|
||||||
$ctp-subtext-0: #a6adc8;
|
|
||||||
$ctp-overlay-2: #9399b2;
|
|
||||||
$ctp-overlay-1: #7f849c;
|
|
||||||
$ctp-overlay-0: #6c7086;
|
|
||||||
$ctp-surface-2: #585b70;
|
|
||||||
$ctp-surface-1: #45475a;
|
|
||||||
$ctp-surface-0: #313244;
|
|
||||||
$ctp-base: #1e1e2e;
|
|
||||||
$ctp-mantle: #181825;
|
|
||||||
$ctp-crust: #11111b;
|
|
||||||
|
|
|
@ -1,14 +0,0 @@
|
||||||
{
|
|
||||||
"$schema": "https://json.schemastore.org/tsconfig",
|
|
||||||
"compilerOptions": {
|
|
||||||
"experimentalDecorators": true,
|
|
||||||
"strict": true,
|
|
||||||
"target": "ES2022",
|
|
||||||
"module": "ES2022",
|
|
||||||
"moduleResolution": "Bundler",
|
|
||||||
// "checkJs": true,
|
|
||||||
// "allowJs": true,
|
|
||||||
"jsx": "react-jsx",
|
|
||||||
"jsxImportSource": "astal/gtk3",
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -1,18 +0,0 @@
|
||||||
import { GLib, Variable } from "astal"
|
|
||||||
|
|
||||||
const TIME_FORMAT = "%H:%M"
|
|
||||||
|
|
||||||
export default function Clock(props: { iconSide: "left" | "right" }) {
|
|
||||||
const time = Variable<string>("").poll(1000, () =>
|
|
||||||
GLib.DateTime.new_now_local().format(TIME_FORMAT)!)
|
|
||||||
|
|
||||||
return <box className={`pill Time icon-${props.iconSide}`}>
|
|
||||||
{props.iconSide == "left" && <label className="icon" label="" />}
|
|
||||||
<label
|
|
||||||
className="label"
|
|
||||||
onDestroy={() => time.drop()}
|
|
||||||
label={time()}
|
|
||||||
/>
|
|
||||||
{props.iconSide == "right" && <label className="icon" label="" />}
|
|
||||||
</box>
|
|
||||||
}
|
|
|
@ -1,18 +0,0 @@
|
||||||
import { GLib, Variable } from "astal"
|
|
||||||
|
|
||||||
const DATE_FORMAT = "%Y-%m-%d"
|
|
||||||
|
|
||||||
export default function Date(props: { iconSide: "left" | "right" }) {
|
|
||||||
const date = Variable<string>("").poll(1000, () =>
|
|
||||||
GLib.DateTime.new_now_local().format(DATE_FORMAT)!)
|
|
||||||
|
|
||||||
return <box className={`pill Date icon-${props.iconSide}`}>
|
|
||||||
{props.iconSide == "left" && <label className="icon" label="" />}
|
|
||||||
<label
|
|
||||||
className="label"
|
|
||||||
onDestroy={() => date.drop()}
|
|
||||||
label={date()}
|
|
||||||
/>
|
|
||||||
{props.iconSide == "right" && <label className="icon" label="" />}
|
|
||||||
</box>
|
|
||||||
}
|
|
|
@ -1,25 +0,0 @@
|
||||||
import { App, Astal, Gdk, Gtk } from "astal/gtk3";
|
|
||||||
import Clock from "./Clock";
|
|
||||||
import Workspaces from "./Workspaces";
|
|
||||||
|
|
||||||
export default function LeftBar(gdkmonitor: Gdk.Monitor) {
|
|
||||||
const { TOP, LEFT, RIGHT } = Astal.WindowAnchor;
|
|
||||||
|
|
||||||
return <window
|
|
||||||
className="LeftBar Bar"
|
|
||||||
gdkmonitor={gdkmonitor}
|
|
||||||
exclusivity={Astal.Exclusivity.EXCLUSIVE}
|
|
||||||
anchor={TOP | LEFT | RIGHT}
|
|
||||||
application={App}>
|
|
||||||
<centerbox>
|
|
||||||
<box halign={Gtk.Align.START}>
|
|
||||||
</box>
|
|
||||||
<box halign={Gtk.Align.CENTER}>
|
|
||||||
<Workspaces monitor="HDMI-A-2" iconSide="right" />
|
|
||||||
</box>
|
|
||||||
<box halign={Gtk.Align.END}>
|
|
||||||
<Clock iconSide="right" />
|
|
||||||
</box>
|
|
||||||
</centerbox>
|
|
||||||
</window>
|
|
||||||
}
|
|
|
@ -1,29 +0,0 @@
|
||||||
import { App, Astal, Gdk, Gtk } from "astal/gtk3";
|
|
||||||
import Clock from "./Clock";
|
|
||||||
import Date from "./Date";
|
|
||||||
import Workspaces from "./Workspaces";
|
|
||||||
import Systray from "./Systray";
|
|
||||||
|
|
||||||
export default function RightBar(gdkmonitor: Gdk.Monitor) {
|
|
||||||
const { TOP, LEFT, RIGHT } = Astal.WindowAnchor;
|
|
||||||
|
|
||||||
return <window
|
|
||||||
className="RightBar Bar"
|
|
||||||
gdkmonitor={gdkmonitor}
|
|
||||||
exclusivity={Astal.Exclusivity.EXCLUSIVE}
|
|
||||||
anchor={TOP | LEFT | RIGHT}
|
|
||||||
application={App}>
|
|
||||||
<centerbox>
|
|
||||||
<box halign={Gtk.Align.START} spacing={8}>
|
|
||||||
<Clock iconSide="left" />
|
|
||||||
<Date iconSide="left" />
|
|
||||||
</box>
|
|
||||||
<box halign={Gtk.Align.CENTER} spacing={8}>
|
|
||||||
<Workspaces monitor="HDMI-A-1" iconSide="left" />
|
|
||||||
</box>
|
|
||||||
<box halign={Gtk.Align.END} spacing={8}>
|
|
||||||
<Systray iconSide="left" />
|
|
||||||
</box>
|
|
||||||
</centerbox>
|
|
||||||
</window>
|
|
||||||
}
|
|
|
@ -1,25 +0,0 @@
|
||||||
import { bind } from "astal"
|
|
||||||
import Tray from "gi://AstalTray"
|
|
||||||
|
|
||||||
const tray = Tray.get_default()
|
|
||||||
|
|
||||||
export default function Systray(props: { iconSide: "left" | "right" }) {
|
|
||||||
return <box className={`pill Systray icon-${props.iconSide}`}>
|
|
||||||
{props.iconSide == "left" && <label className="icon" label="" />}
|
|
||||||
<box className="items">
|
|
||||||
{bind(tray, "items").as(items => items.map(item => <SystrayItem item={item} />))}
|
|
||||||
</box>
|
|
||||||
{props.iconSide == "right" && <label className="icon" label="" />}
|
|
||||||
</box >
|
|
||||||
}
|
|
||||||
|
|
||||||
function SystrayItem({ item }: { item: Tray.TrayItem }) {
|
|
||||||
return <menubutton
|
|
||||||
className="item"
|
|
||||||
tooltipMarkup={bind(item, "tooltipMarkup")}
|
|
||||||
usePopover={false}
|
|
||||||
actionGroup={bind(item, "actionGroup").as(ag => ["dbusmenu", ag])}
|
|
||||||
menuModel={bind(item, "menuModel")}>
|
|
||||||
<icon gicon={bind(item, "gicon")} />
|
|
||||||
</menubutton>
|
|
||||||
}
|
|
|
@ -1,55 +0,0 @@
|
||||||
import { bind } from "astal"
|
|
||||||
import Hyprland from "gi://AstalHyprland"
|
|
||||||
|
|
||||||
export default function Workspaces(props: { monitor: string, iconSide: "left" | "right" }) {
|
|
||||||
const hyprland = Hyprland.get_default();
|
|
||||||
|
|
||||||
return <box className={`pill Workspaces icon-${props.iconSide}`}>
|
|
||||||
{props.iconSide == "left" && <label className="icon" label="" />}
|
|
||||||
<box className="label">
|
|
||||||
{bind(hyprland, "workspaces").as(wss => wss
|
|
||||||
.filter(it => it && it.get_monitor && it.get_monitor().name == props.monitor)
|
|
||||||
.sort((a, b) => a.get_id() - b.get_id())
|
|
||||||
.map(workspace => <Workspace workspace={workspace} />)
|
|
||||||
)}
|
|
||||||
<button
|
|
||||||
className="add"
|
|
||||||
onClick={() => {
|
|
||||||
hyprland.dispatch("workspace", "emptynm");
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
<label label="" />
|
|
||||||
</button>
|
|
||||||
</box>
|
|
||||||
{props.iconSide == "right" && <label className="icon" label="" />}
|
|
||||||
</box>
|
|
||||||
}
|
|
||||||
|
|
||||||
function Workspace(props: { workspace: Hyprland.Workspace }) {
|
|
||||||
const hyprland = Hyprland.get_default();
|
|
||||||
|
|
||||||
return <box>
|
|
||||||
{bind(props.workspace.get_monitor(), "activeWorkspace").as(ws => {
|
|
||||||
if (ws == props.workspace) {
|
|
||||||
return <label
|
|
||||||
label=""
|
|
||||||
/>
|
|
||||||
} else {
|
|
||||||
return <button
|
|
||||||
onClick={() => {
|
|
||||||
const name = props.workspace.name
|
|
||||||
if (name) {
|
|
||||||
hyprland.dispatch("workspace", `name:${name}`);
|
|
||||||
} else {
|
|
||||||
hyprland.dispatch("workspace", `id:${props.workspace.get_id()}`);
|
|
||||||
}
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
<label
|
|
||||||
label=""
|
|
||||||
/>
|
|
||||||
</button>
|
|
||||||
}
|
|
||||||
})}
|
|
||||||
</box>
|
|
||||||
}
|
|
|
@ -1,20 +0,0 @@
|
||||||
{
|
|
||||||
inputs,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
home-manager.users.kalle = {
|
|
||||||
imports = [ inputs.ags.homeManagerModules.default ];
|
|
||||||
programs.ags = {
|
|
||||||
enable = true;
|
|
||||||
configDir = ./config;
|
|
||||||
extraPackages = with inputs.ags.packages.${pkgs.system}; [
|
|
||||||
tray
|
|
||||||
hyprland
|
|
||||||
mpris
|
|
||||||
wireplumber
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,8 +0,0 @@
|
||||||
{ ... }:
|
|
||||||
{
|
|
||||||
imports = [
|
|
||||||
./hyprland.nix
|
|
||||||
./hyprpaper.nix
|
|
||||||
./ags
|
|
||||||
];
|
|
||||||
}
|
|
|
@ -1,254 +0,0 @@
|
||||||
{
|
|
||||||
inputs,
|
|
||||||
pkgs,
|
|
||||||
lib,
|
|
||||||
config,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
options =
|
|
||||||
let
|
|
||||||
inherit (lib) mkOption types;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
hyprland = {
|
|
||||||
mod = mkOption {
|
|
||||||
type = types.str;
|
|
||||||
default = "SUPER";
|
|
||||||
};
|
|
||||||
|
|
||||||
autoStart = mkOption {
|
|
||||||
type = types.listOf types.str;
|
|
||||||
default = [ ];
|
|
||||||
};
|
|
||||||
|
|
||||||
sensitivity = mkOption {
|
|
||||||
type = types.float;
|
|
||||||
default = 0.0;
|
|
||||||
};
|
|
||||||
|
|
||||||
layerRules = mkOption {
|
|
||||||
type = types.attrsOf (types.listOf types.str);
|
|
||||||
default = { };
|
|
||||||
};
|
|
||||||
|
|
||||||
windowRules = mkOption {
|
|
||||||
type = types.attrsOf (types.listOf types.str);
|
|
||||||
default = { };
|
|
||||||
};
|
|
||||||
|
|
||||||
binds = mkOption {
|
|
||||||
type = types.attrsOf types.str;
|
|
||||||
default = { };
|
|
||||||
};
|
|
||||||
|
|
||||||
};
|
|
||||||
|
|
||||||
};
|
|
||||||
|
|
||||||
config =
|
|
||||||
let
|
|
||||||
uwsm = "${pkgs.uwsm}/bin/uwsm";
|
|
||||||
mkUwsmApp = bin: "${uwsm} app -- ${bin}";
|
|
||||||
mkUwsmDesktopApp = pkg: name: "${uwsm} app -- ${pkg}/share/applications/${name}.desktop";
|
|
||||||
cfg = config.hyprland;
|
|
||||||
monitors = config.monitors;
|
|
||||||
# There is always exactly one primary monitor as asserted in the monitor module
|
|
||||||
primaryMonitor = lib.findSingle (m: m.isPrimary) "" "" monitors;
|
|
||||||
transformToOption =
|
|
||||||
transform:
|
|
||||||
if transform == "normal" then
|
|
||||||
""
|
|
||||||
else if transform == "clockwise" then
|
|
||||||
"transform,1"
|
|
||||||
else if transform == "flip" then
|
|
||||||
"transform,2"
|
|
||||||
else if transform == "counterclockwise" then
|
|
||||||
"transform,3"
|
|
||||||
else
|
|
||||||
abort "Invalid transform ${transform}";
|
|
||||||
in
|
|
||||||
{
|
|
||||||
nix.settings = {
|
|
||||||
substituters = [
|
|
||||||
"https://hyprland.cachix.org"
|
|
||||||
];
|
|
||||||
trusted-public-keys = [
|
|
||||||
"hyprland.cachix.org-1:a7pgxzMz7+chwVL3/pzj6jIBMioiJM7ypFP8PwtkuGc="
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.hyprland = {
|
|
||||||
enable = true;
|
|
||||||
withUWSM = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
xdg.portal.extraPortals = [ pkgs.xdg-desktop-portal-gtk ];
|
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
|
||||||
grim # For xdg-desktop-portal-hyprland which does not declare this dependency
|
|
||||||
slurp # Some for this one
|
|
||||||
];
|
|
||||||
|
|
||||||
home-manager.users.kalle = {
|
|
||||||
home.packages = with pkgs; [
|
|
||||||
wl-clipboard
|
|
||||||
cliphist
|
|
||||||
ulauncher
|
|
||||||
];
|
|
||||||
|
|
||||||
wayland.windowManager.hyprland = {
|
|
||||||
enable = true;
|
|
||||||
# Disable systemd integration since we are using UWSM
|
|
||||||
systemd.enable = false;
|
|
||||||
|
|
||||||
settings = {
|
|
||||||
monitor =
|
|
||||||
map (
|
|
||||||
m:
|
|
||||||
let
|
|
||||||
resolution = "${toString m.width}x${toString m.height}@${toString m.refreshRate}";
|
|
||||||
position = "${toString m.x}x${toString m.y}";
|
|
||||||
vrr = if m.vrr != 0 then "vrr,1," else "";
|
|
||||||
transform = transformToOption m.transform;
|
|
||||||
in
|
|
||||||
"${m.name},${resolution},${position},1,${vrr}${transform}"
|
|
||||||
) (monitors)
|
|
||||||
# Automatically detect newly connected monitors
|
|
||||||
++ [ ",preferred,auto,auto" ];
|
|
||||||
|
|
||||||
exec-once = [
|
|
||||||
(mkUwsmApp "${pkgs.wl-clipboard}/bin/wl-paste --watch ${pkgs.cliphist}/bin/cliphist store")
|
|
||||||
(mkUwsmApp "${pkgs.ulauncher}/bin/ulauncher --no-window-shadow --hide-window")
|
|
||||||
(mkUwsmApp "${pkgs.hyprpolkitagent}/libexec/hyprpolkitagent")
|
|
||||||
] ++ cfg.autoStart;
|
|
||||||
|
|
||||||
env = [
|
|
||||||
"XCURSOR_SIZE,24"
|
|
||||||
];
|
|
||||||
|
|
||||||
input = {
|
|
||||||
kb_layout = "us";
|
|
||||||
kb_variant = "";
|
|
||||||
kb_options = "";
|
|
||||||
|
|
||||||
follow_mouse = 1;
|
|
||||||
|
|
||||||
touchpad = {
|
|
||||||
natural_scroll = "yes";
|
|
||||||
};
|
|
||||||
|
|
||||||
sensitivity = cfg.sensitivity;
|
|
||||||
accel_profile = "flat";
|
|
||||||
};
|
|
||||||
|
|
||||||
general = {
|
|
||||||
gaps_in = 5;
|
|
||||||
gaps_out = 10;
|
|
||||||
|
|
||||||
border_size = 1;
|
|
||||||
# TODO: Make this use system color scheme
|
|
||||||
"col.active_border" = "rgba(33ccffee) rgba(00ff99ee) 45deg";
|
|
||||||
"col.inactive_border" = "rgba(595959aa)";
|
|
||||||
|
|
||||||
layout = "dwindle";
|
|
||||||
};
|
|
||||||
|
|
||||||
misc.force_default_wallpaper = 1;
|
|
||||||
|
|
||||||
decoration = {
|
|
||||||
rounding = 5;
|
|
||||||
|
|
||||||
blur = {
|
|
||||||
enabled = "yes";
|
|
||||||
size = 3;
|
|
||||||
passes = 1;
|
|
||||||
new_optimizations = "on";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
animations = {
|
|
||||||
enabled = "yes";
|
|
||||||
|
|
||||||
bezier = [
|
|
||||||
"myBezier, 0.05, 0.9, 0.1, 1.05"
|
|
||||||
];
|
|
||||||
|
|
||||||
animation = [
|
|
||||||
"windows, 1, 3, myBezier"
|
|
||||||
"windowsOut, 1, 3, default, popin 80%"
|
|
||||||
"border, 1, 5, default"
|
|
||||||
"borderangle, 1, 4, default"
|
|
||||||
"fade, 1, 3, default"
|
|
||||||
"workspaces, 1, 2, default"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
layerrule =
|
|
||||||
let
|
|
||||||
y = ident: value: "${value},${ident}";
|
|
||||||
x = ident: values: map (y ident) values;
|
|
||||||
in
|
|
||||||
lib.flatten (lib.mapAttrsToList x cfg.layerRules);
|
|
||||||
|
|
||||||
workspace =
|
|
||||||
let
|
|
||||||
# Create one work space for each non primary monitor
|
|
||||||
perMonitorWorkspaces = map (m: "name:${m.name}, monitor:${m.name}") (
|
|
||||||
lib.filter (m: m.name != primaryMonitor.name) monitors
|
|
||||||
);
|
|
||||||
|
|
||||||
# Create 10 work spaces on the primary monitor
|
|
||||||
primaryMonitorWorkspaces = map (i: "${toString i}, monitor:${primaryMonitor.name}") (
|
|
||||||
lib.range 1 10
|
|
||||||
);
|
|
||||||
|
|
||||||
in
|
|
||||||
primaryMonitorWorkspaces ++ perMonitorWorkspaces;
|
|
||||||
|
|
||||||
bind =
|
|
||||||
let
|
|
||||||
# Create binds to switch workspaces and move windows between them
|
|
||||||
workspaceBinds = lib.flatten (
|
|
||||||
map (
|
|
||||||
i:
|
|
||||||
let
|
|
||||||
k = if i == 10 then 0 else i;
|
|
||||||
in
|
|
||||||
[
|
|
||||||
"${cfg.mod}, ${toString k}, workspace, ${toString i}"
|
|
||||||
"${cfg.mod} SHIFT, ${toString k}, movetoworkspace, ${toString i}"
|
|
||||||
]
|
|
||||||
) (lib.range 1 10)
|
|
||||||
);
|
|
||||||
|
|
||||||
# Create binds to manage windows
|
|
||||||
windowManagementBinds = [
|
|
||||||
"${cfg.mod} SHIFT, Q, killactive"
|
|
||||||
"${cfg.mod}, F, togglefloating"
|
|
||||||
"${cfg.mod} SHIFT, F, fullscreen"
|
|
||||||
];
|
|
||||||
|
|
||||||
configBinds = lib.mapAttrsToList (k: v: "${k}, ${v}") cfg.binds;
|
|
||||||
in
|
|
||||||
configBinds ++ workspaceBinds ++ windowManagementBinds;
|
|
||||||
|
|
||||||
bindm = [
|
|
||||||
"${cfg.mod}, mouse:272, movewindow"
|
|
||||||
"${cfg.mod}, mouse:273, resizewindow"
|
|
||||||
];
|
|
||||||
|
|
||||||
windowrule =
|
|
||||||
let
|
|
||||||
y = ident: value: "${value},${ident}";
|
|
||||||
x = ident: values: map (y ident) values;
|
|
||||||
in
|
|
||||||
lib.flatten (lib.mapAttrsToList x cfg.windowRules);
|
|
||||||
|
|
||||||
# Enable color management protocol
|
|
||||||
debug.full_cm_proto = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,59 +0,0 @@
|
||||||
{
|
|
||||||
lib,
|
|
||||||
config,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
|
|
||||||
{
|
|
||||||
options =
|
|
||||||
let
|
|
||||||
inherit (lib) mkOption types;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
hyprpaper = {
|
|
||||||
wallpaperFolder = mkOption {
|
|
||||||
type = types.str;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
config =
|
|
||||||
let
|
|
||||||
cfg = config.hyprpaper;
|
|
||||||
hyprlandCfg = config.hyprland;
|
|
||||||
monitors = config.monitors;
|
|
||||||
|
|
||||||
changeWallpaperScript = pkgs.writeShellScriptBin "change-wallpaper" (
|
|
||||||
lib.concatStringsSep "\n" (
|
|
||||||
lib.flatten (
|
|
||||||
map (
|
|
||||||
m:
|
|
||||||
let
|
|
||||||
output = m.name;
|
|
||||||
wallpaper = "\"$(${pkgs.findutils}/bin/find -L \"${cfg.wallpaperFolder}\" -type f | ${pkgs.coreutils}/bin/shuf -n 1)\"";
|
|
||||||
in
|
|
||||||
[
|
|
||||||
"wallpaper=${wallpaper}"
|
|
||||||
"${pkgs.hyprland}/bin/hyprctl hyprpaper preload $wallpaper"
|
|
||||||
"${pkgs.hyprland}/bin/hyprctl hyprpaper wallpaper ${output},$wallpaper"
|
|
||||||
]
|
|
||||||
) monitors
|
|
||||||
)
|
|
||||||
++ [ "${pkgs.hyprland}/bin/hyprctl hyprpaper unload all" ]
|
|
||||||
)
|
|
||||||
);
|
|
||||||
in
|
|
||||||
{
|
|
||||||
hyprland.autoStart = [
|
|
||||||
"${pkgs.hyprpaper}/bin/hyprpaper"
|
|
||||||
"sleep 2; ${changeWallpaperScript}/bin/change-wallpaper"
|
|
||||||
];
|
|
||||||
|
|
||||||
home-manager.users.kalle.home.packages = with pkgs; [
|
|
||||||
hyprpaper
|
|
||||||
changeWallpaperScript
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
}
|
|
|
@ -1,6 +0,0 @@
|
||||||
{
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
services.desktopManager.plasma6.enable = true;
|
|
||||||
}
|
|
|
@ -1,55 +0,0 @@
|
||||||
{
|
|
||||||
lib,
|
|
||||||
pkgs,
|
|
||||||
assetRel,
|
|
||||||
config,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
let
|
|
||||||
accentColor = "#306cf8";
|
|
||||||
monitors = config.monitors;
|
|
||||||
themePkg = pkgs.sddm-astronaut.override {
|
|
||||||
themeConfig = {
|
|
||||||
Background = "${assetRel "login_wallpaper.jpg"}";
|
|
||||||
|
|
||||||
FullBlur = "false";
|
|
||||||
PartialBlur = "true";
|
|
||||||
HideVirtualKeyboard = "true";
|
|
||||||
HideLoginButton = "true";
|
|
||||||
|
|
||||||
BlurMax = "170";
|
|
||||||
Blur = "0.8";
|
|
||||||
HaveFormBackground = "false";
|
|
||||||
FormPosition = "right";
|
|
||||||
|
|
||||||
HighlightBorderColor = accentColor;
|
|
||||||
HighlightBackgroundColor = accentColor;
|
|
||||||
DropdownSelectedBackgroundColor = accentColor;
|
|
||||||
HoverUserIconColor = accentColor;
|
|
||||||
HoverPasswordIconColor = accentColor;
|
|
||||||
HoverSystemButtonsIconsColor = accentColor;
|
|
||||||
HoverSessionButtonTextColor = accentColor;
|
|
||||||
HoverVirtualKeyboardButtonTextColor = accentColor;
|
|
||||||
WarningColor = accentColor;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
in
|
|
||||||
{
|
|
||||||
services.displayManager.sddm = {
|
|
||||||
enable = true;
|
|
||||||
theme = "sddm-astronaut-theme";
|
|
||||||
# Force the use qt6 based sddm, as the default is still qt5
|
|
||||||
package = lib.mkForce pkgs.kdePackages.sddm;
|
|
||||||
extraPackages = [ themePkg ];
|
|
||||||
};
|
|
||||||
# Disable all non-primary monitors on the login screen
|
|
||||||
services.xserver.displayManager.setupCommands = lib.concatStringsSep "\n" (
|
|
||||||
map (m: "${pkgs.xorg.xrandr}/bin/xrandr --output ${m.name} --off") (
|
|
||||||
lib.filter (m: !m.isPrimary) monitors
|
|
||||||
)
|
|
||||||
);
|
|
||||||
|
|
||||||
environment.systemPackages = [
|
|
||||||
themePkg
|
|
||||||
];
|
|
||||||
}
|
|
|
@ -1,9 +0,0 @@
|
||||||
{
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
home-manager.users.kalle.home.packages = [
|
|
||||||
pkgs.signal-desktop
|
|
||||||
];
|
|
||||||
}
|
|
|
@ -1,25 +0,0 @@
|
||||||
{
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
let
|
|
||||||
cursorName = "breeze_cursors";
|
|
||||||
cursorSize = 24;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
home-manager.users.kalle.home.pointerCursor = {
|
|
||||||
gtk.enable = true;
|
|
||||||
x11.enable = true;
|
|
||||||
|
|
||||||
package = pkgs.kdePackages.breeze;
|
|
||||||
name = cursorName;
|
|
||||||
size = cursorSize;
|
|
||||||
};
|
|
||||||
|
|
||||||
home-manager.users.kalle.dconf.settings = {
|
|
||||||
"org/gnome/desktop/interface" = {
|
|
||||||
cursor-theme = cursorName;
|
|
||||||
cursor-size = cursorSize;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,8 +0,0 @@
|
||||||
{ ... }:
|
|
||||||
{
|
|
||||||
imports = [
|
|
||||||
./gtk.nix
|
|
||||||
./cursor.nix
|
|
||||||
./qt.nix
|
|
||||||
];
|
|
||||||
}
|
|
|
@ -1,51 +0,0 @@
|
||||||
{
|
|
||||||
pkgs,
|
|
||||||
config,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
|
|
||||||
let
|
|
||||||
# WARNING: Official theme, but archived since Jun 2024.
|
|
||||||
themePackage = pkgs.catppuccin-gtk.override {
|
|
||||||
accents = [ "blue" ];
|
|
||||||
size = "standard";
|
|
||||||
variant = "mocha";
|
|
||||||
};
|
|
||||||
themeName = "catppuccin-mocha-blue-standard";
|
|
||||||
|
|
||||||
iconPackage = pkgs.kdePackages.breeze-icons;
|
|
||||||
iconName = "breeze-dark";
|
|
||||||
in
|
|
||||||
{
|
|
||||||
home-manager.users.kalle.gtk = {
|
|
||||||
enable = true;
|
|
||||||
theme = {
|
|
||||||
package = themePackage;
|
|
||||||
name = themeName;
|
|
||||||
};
|
|
||||||
iconTheme = {
|
|
||||||
package = iconPackage;
|
|
||||||
name = iconName;
|
|
||||||
};
|
|
||||||
# cursorTheme = {package name size}; defaults to home.pointerCursor vals.
|
|
||||||
|
|
||||||
gtk3 = {
|
|
||||||
extraConfig.gtk-application-prefer-dark-theme = true;
|
|
||||||
};
|
|
||||||
gtk4 = {
|
|
||||||
extraConfig.gtk-application-prefer-dark-theme = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
# Some software will only behave with theming if you set this (i.e. adjust
|
|
||||||
# font color), especially software that has heavy integration with DEs
|
|
||||||
# normally and GTK4 stuff. Also for Wayland software this may work only if
|
|
||||||
# the gtk desktop portal is installed.
|
|
||||||
home-manager.users.kalle.dconf.settings = {
|
|
||||||
"org/gnome/desktop/interface" = {
|
|
||||||
color-scheme = "prefer-dark";
|
|
||||||
gtk-theme = themeName;
|
|
||||||
icon-theme = iconName;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -1,248 +0,0 @@
|
||||||
{
|
|
||||||
pkgs,
|
|
||||||
lib,
|
|
||||||
config,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
{
|
|
||||||
home-manager.users.kalle = {
|
|
||||||
qt = {
|
|
||||||
enable = true;
|
|
||||||
platformTheme.name = "qtct";
|
|
||||||
};
|
|
||||||
|
|
||||||
home.packages = with pkgs.kdePackages; [
|
|
||||||
# Install both breeze5 and breeze6 since qt5 is still very commonplace.
|
|
||||||
# Use the qt5 output instead of libsForQt5 to prevent package collisions.
|
|
||||||
breeze
|
|
||||||
breeze.qt5
|
|
||||||
|
|
||||||
# The HM qt module does not actually seem to ship wayland support by default.
|
|
||||||
qtwayland # for qt6
|
|
||||||
pkgs.libsForQt5.qtwayland # for qt5
|
|
||||||
];
|
|
||||||
|
|
||||||
xdg.configFile =
|
|
||||||
let
|
|
||||||
toStr = builtins.toString;
|
|
||||||
toINI = lib.generators.toINI { };
|
|
||||||
confDir = v: "qt${toStr v}ct";
|
|
||||||
confFile = v: "${confDir v}/qt${toStr v}ct.conf";
|
|
||||||
colorsFile = v: "${confDir v}/colors/catppuccin-mocha-blue-breeze.conf";
|
|
||||||
absColorsFile = v: "${config.home-manager.users.kalle.xdg.configHome}/${colorsFile v}";
|
|
||||||
|
|
||||||
sharedConf = {
|
|
||||||
Appearance = {
|
|
||||||
custom_palette = "true";
|
|
||||||
icon_theme = "breeze-dark";
|
|
||||||
standard_dialogs = "default";
|
|
||||||
style = "Breeze";
|
|
||||||
};
|
|
||||||
Interface = {
|
|
||||||
activate_item_on_single_click = "1";
|
|
||||||
buttonbox_layout = "0";
|
|
||||||
cursor_flash_time = "1000";
|
|
||||||
dialog_buttons_have_icons = "1";
|
|
||||||
double_click_interval = "400";
|
|
||||||
keyboard_scheme = "2";
|
|
||||||
menus_have_icons = "true";
|
|
||||||
show_shortcuts_in_context_menus = "true";
|
|
||||||
toolbutton_style = "4";
|
|
||||||
underline_shortcut = "1";
|
|
||||||
wheel_scroll_lines = "3";
|
|
||||||
};
|
|
||||||
Troubleshooting = {
|
|
||||||
force_raster_widgets = "1";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
# qt6 expects slightly different config values from qt5 for color schemes.
|
|
||||||
# In the case of colorschemes (assuming we aim for a consistent coloring
|
|
||||||
# between both versions) these differences are only at the end. Not
|
|
||||||
# entirely sure what changes but I have checked that this is also consist
|
|
||||||
# with what happens in Breeze and Catppuccin-KDE and as far as I can tell
|
|
||||||
# the theme is consist between qt5 and qt6 apps, so whatever.
|
|
||||||
colorsConf = v: {
|
|
||||||
ColorScheme = {
|
|
||||||
active_colors =
|
|
||||||
"#ffcdd6f4, #ff313244, #ff3d3d5e, #ff2f2f48, #ff0c0c12, #ff151520, #ffcdd6f4, #ffcdd6f4, #ffcdd6f4, #ff1e1e2e, #ff181825, #ff09090d, #ff89b4fa, #ff11111b, #ff89b4fa, #ffcba6f7, #ff181825, #ffffffff, #ff1e1e2e, #ffcdd6f4, "
|
|
||||||
+ "${if v == 5 then "#806c7086" else "#ffa6adc8, #ff89b4fa"}";
|
|
||||||
disabled_colors =
|
|
||||||
"#ff6c7086, #ff313244, #ff45475a, #ff313244, #ff11111b, #ff181825, #ff6c7086, #ffcdd6f4, #ff6c7086, #ff1e1e2e, #ff181825, #ff11111b, #ff181825, #ff6c7086, #ffa9bcdb, #ffc7cceb, #ff181825, #ffffffff, #ff1e1e2e, #ffcdd6f4, #806c7086"
|
|
||||||
+ "${if v == 5 then "" else ", #ff181825"}";
|
|
||||||
inactive_colors =
|
|
||||||
"#ffcdd6f4, #ff313244, #ff3d3d5e, #ff2f2f48, #ff0c0c12, #ff151520, #ffcdd6f4, #ffcdd6f4, #ffcdd6f4, #ff1e1e2e, #ff181825, #ff09090d, #ff89b4fa, #ff11111b, #ff89b4fa, #ffcba6f7, #ff181825, #ffffffff, #ff1e1e2e, #ffcdd6f4, #806c7086, "
|
|
||||||
+ "${if v == 5 then "#806c7086" else "#ffa6adc8, #ff89b4fa"}";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
in
|
|
||||||
{
|
|
||||||
"${confFile 5}".text = toINI (
|
|
||||||
lib.recursiveUpdate sharedConf {
|
|
||||||
Appearance = {
|
|
||||||
color_scheme_path = absColorsFile 5;
|
|
||||||
};
|
|
||||||
Fonts = {
|
|
||||||
fixed = "\"Noto Sans,10,-1,5,50,0,0,0,0,0,Regular\"";
|
|
||||||
general = "\"Noto Sans,10,-1,5,50,0,0,0,0,0,Regular\"";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
);
|
|
||||||
"${confFile 6}".text = toINI (
|
|
||||||
lib.recursiveUpdate sharedConf {
|
|
||||||
Appearance = {
|
|
||||||
color_scheme_path = absColorsFile 6;
|
|
||||||
};
|
|
||||||
Fonts = {
|
|
||||||
fixed = "\"Noto Sans,10,-1,5,400,0,0,0,0,0,0,0,0,0,0,1,Regular\"";
|
|
||||||
general = "\"Noto Sans,10,-1,5,400,0,0,0,0,0,0,0,0,0,0,1,Regular\"";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
);
|
|
||||||
|
|
||||||
"${colorsFile 5}".text = toINI (colorsConf 5);
|
|
||||||
"${colorsFile 6}".text = toINI (colorsConf 6);
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
kdeglobals = {
|
|
||||||
UiSettings = {
|
|
||||||
# Without setting specifically this key to this value, many config
|
|
||||||
# values for Breeze both from kdeglobals and the qt colorscheme
|
|
||||||
# are ignored when running outside of Plasma.
|
|
||||||
ColorScheme = "*";
|
|
||||||
};
|
|
||||||
|
|
||||||
# The colors used here are the Catppuccin Mocha Blue colors. More specifically,
|
|
||||||
# I stole them directly from the values the offical Catppuccin-KDE distribution
|
|
||||||
# sets when you apply that theme inside KDE.
|
|
||||||
"ColorEffects:Disabled" = {
|
|
||||||
ChangeSelectionColor = "";
|
|
||||||
Color = "30, 30, 46";
|
|
||||||
ColorAmount = "0.3";
|
|
||||||
ColorEffect = "2";
|
|
||||||
ContrastAmount = "0.1";
|
|
||||||
ContrastEffect = "0";
|
|
||||||
Enable = "";
|
|
||||||
IntensityAmount = "-1";
|
|
||||||
IntensityEffect = "0";
|
|
||||||
};
|
|
||||||
|
|
||||||
"ColorEffects:Inactive" = {
|
|
||||||
ChangeSelectionColor = "true";
|
|
||||||
Color = "30, 30, 46";
|
|
||||||
ColorAmount = "0.5";
|
|
||||||
ColorEffect = "3";
|
|
||||||
ContrastAmount = "0";
|
|
||||||
ContrastEffect = "0";
|
|
||||||
Enable = "true";
|
|
||||||
IntensityAmount = "0";
|
|
||||||
IntensityEffect = "0";
|
|
||||||
};
|
|
||||||
|
|
||||||
"Colors:Button" = {
|
|
||||||
BackgroundAlternate = "137,180,250";
|
|
||||||
BackgroundNormal = "49, 50, 68";
|
|
||||||
DecorationFocus = "137,180,250";
|
|
||||||
DecorationHover = "49, 50, 68";
|
|
||||||
ForegroundActive = "250, 179, 135";
|
|
||||||
ForegroundInactive = "166, 173, 200";
|
|
||||||
ForegroundLink = "137,180,250";
|
|
||||||
ForegroundNegative = "243, 139, 168";
|
|
||||||
ForegroundNeutral = "249, 226, 175";
|
|
||||||
ForegroundNormal = "205, 214, 244";
|
|
||||||
ForegroundPositive = "166, 227, 161";
|
|
||||||
ForegroundVisited = "203, 166, 247";
|
|
||||||
};
|
|
||||||
|
|
||||||
"Colors:Complementary" = {
|
|
||||||
BackgroundAlternate = "17, 17, 27";
|
|
||||||
BackgroundNormal = "24, 24, 37";
|
|
||||||
DecorationFocus = "137,180,250";
|
|
||||||
DecorationHover = "49, 50, 68";
|
|
||||||
ForegroundActive = "250, 179, 135";
|
|
||||||
ForegroundInactive = "166, 173, 200";
|
|
||||||
ForegroundLink = "137,180,250";
|
|
||||||
ForegroundNegative = "243, 139, 168";
|
|
||||||
ForegroundNeutral = "249, 226, 175";
|
|
||||||
ForegroundNormal = "205, 214, 244";
|
|
||||||
ForegroundPositive = "166, 227, 161";
|
|
||||||
ForegroundVisited = "203, 166, 247";
|
|
||||||
};
|
|
||||||
|
|
||||||
"Colors:Header" = {
|
|
||||||
BackgroundAlternate = "17, 17, 27";
|
|
||||||
BackgroundNormal = "24, 24, 37";
|
|
||||||
DecorationFocus = "137,180,250";
|
|
||||||
DecorationHover = "49, 50, 68";
|
|
||||||
ForegroundActive = "250, 179, 135";
|
|
||||||
ForegroundInactive = "166, 173, 200";
|
|
||||||
ForegroundLink = "137,180,250";
|
|
||||||
ForegroundNegative = "243, 139, 168";
|
|
||||||
ForegroundNeutral = "249, 226, 175";
|
|
||||||
ForegroundNormal = "205, 214, 244";
|
|
||||||
ForegroundPositive = "166, 227, 161";
|
|
||||||
ForegroundVisited = "203, 166, 247";
|
|
||||||
};
|
|
||||||
|
|
||||||
"Colors:Selection" = {
|
|
||||||
BackgroundAlternate = "137,180,250";
|
|
||||||
BackgroundNormal = "137,180,250";
|
|
||||||
DecorationFocus = "137,180,250";
|
|
||||||
DecorationHover = "49, 50, 68";
|
|
||||||
ForegroundActive = "250, 179, 135";
|
|
||||||
ForegroundInactive = "24, 24, 37";
|
|
||||||
ForegroundLink = "137,180,250";
|
|
||||||
ForegroundNegative = "243, 139, 168";
|
|
||||||
ForegroundNeutral = "249, 226, 175";
|
|
||||||
ForegroundNormal = "17, 17, 27";
|
|
||||||
ForegroundPositive = "166, 227, 161";
|
|
||||||
ForegroundVisited = "203, 166, 247";
|
|
||||||
};
|
|
||||||
|
|
||||||
"Colors:Tooltip" = {
|
|
||||||
BackgroundAlternate = "27,25,35";
|
|
||||||
BackgroundNormal = "30, 30, 46";
|
|
||||||
DecorationFocus = "137,180,250";
|
|
||||||
DecorationHover = "49, 50, 68";
|
|
||||||
ForegroundActive = "250, 179, 135";
|
|
||||||
ForegroundInactive = "166, 173, 200";
|
|
||||||
ForegroundLink = "137,180,250";
|
|
||||||
ForegroundNegative = "243, 139, 168";
|
|
||||||
ForegroundNeutral = "249, 226, 175";
|
|
||||||
ForegroundNormal = "205, 214, 244";
|
|
||||||
ForegroundPositive = "166, 227, 161";
|
|
||||||
ForegroundVisited = "203, 166, 247";
|
|
||||||
};
|
|
||||||
|
|
||||||
"Colors:View" = {
|
|
||||||
BackgroundAlternate = "24, 24, 37";
|
|
||||||
BackgroundNormal = "30, 30, 46";
|
|
||||||
DecorationFocus = "137,180,250";
|
|
||||||
DecorationHover = "49, 50, 68";
|
|
||||||
ForegroundActive = "250, 179, 135";
|
|
||||||
ForegroundInactive = "166, 173, 200";
|
|
||||||
ForegroundLink = "137,180,250";
|
|
||||||
ForegroundNegative = "243, 139, 168";
|
|
||||||
ForegroundNeutral = "249, 226, 175";
|
|
||||||
ForegroundNormal = "205, 214, 244";
|
|
||||||
ForegroundPositive = "166, 227, 161";
|
|
||||||
ForegroundVisited = "203, 166, 247";
|
|
||||||
};
|
|
||||||
|
|
||||||
"Colors:Window" = {
|
|
||||||
BackgroundAlternate = "17, 17, 27";
|
|
||||||
BackgroundNormal = "24, 24, 37";
|
|
||||||
DecorationFocus = "137,180,250";
|
|
||||||
DecorationHover = "49, 50, 68";
|
|
||||||
ForegroundActive = "250, 179, 135";
|
|
||||||
ForegroundInactive = "166, 173, 200";
|
|
||||||
ForegroundLink = "137,180,250";
|
|
||||||
ForegroundNegative = "243, 139, 168";
|
|
||||||
ForegroundNeutral = "249, 226, 175";
|
|
||||||
ForegroundNormal = "205, 214, 244";
|
|
||||||
ForegroundPositive = "166, 227, 161";
|
|
||||||
ForegroundVisited = "203, 166, 247";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
1
nvim/after/ftplugin/agda.lua
Normal file
1
nvim/after/ftplugin/agda.lua
Normal file
|
@ -0,0 +1 @@
|
||||||
|
vim.opt.commentstring = "--%s"
|
3
nvim/after/ftplugin/tex.lua
Normal file
3
nvim/after/ftplugin/tex.lua
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
vim.opt_local.textwidth = 80
|
||||||
|
vim.opt_local.colorcolumn = "81"
|
||||||
|
vim.opt_local.formatoptions:append("a")
|
52
nvim/after/plugin/bufferline.lua
Normal file
52
nvim/after/plugin/bufferline.lua
Normal file
|
@ -0,0 +1,52 @@
|
||||||
|
require('bufferline').setup {
|
||||||
|
options = {
|
||||||
|
mode = 'buffers',
|
||||||
|
numbers = 'ordinal',
|
||||||
|
separator_style = 'slant',
|
||||||
|
show_buffer_icons = true,
|
||||||
|
show_buffer_close_icons = false,
|
||||||
|
show_close_icon = false,
|
||||||
|
always_show_bufferline = true,
|
||||||
|
right_mouse_command = function(bufnum) end,
|
||||||
|
middle_mouse_command = function(bufnum)
|
||||||
|
require('bufdelete').bufdelete(bufnum)
|
||||||
|
end,
|
||||||
|
custom_areas = {
|
||||||
|
right = function()
|
||||||
|
local result = {}
|
||||||
|
local seve = vim.diagnostic.severity
|
||||||
|
local error = #vim.diagnostic.get(0, {severity = seve.ERROR})
|
||||||
|
local warning = #vim.diagnostic.get(0, {severity = seve.WARN})
|
||||||
|
local info = #vim.diagnostic.get(0, {severity = seve.INFO})
|
||||||
|
local hint = #vim.diagnostic.get(0, {severity = seve.HINT})
|
||||||
|
|
||||||
|
if error ~= 0 then
|
||||||
|
table.insert(result, {text = " " .. error, fg = "#EC5241"})
|
||||||
|
end
|
||||||
|
|
||||||
|
if warning ~= 0 then
|
||||||
|
table.insert(result, {text = " " .. warning, fg = "#EFB839"})
|
||||||
|
end
|
||||||
|
|
||||||
|
if hint ~= 0 then
|
||||||
|
table.insert(result, {text = " " .. hint, fg = "#A3BA5E"})
|
||||||
|
end
|
||||||
|
|
||||||
|
if info ~= 0 then
|
||||||
|
table.insert(result, {text = " " .. info, fg = "#7EA9A7"})
|
||||||
|
end
|
||||||
|
return result
|
||||||
|
end,
|
||||||
|
},
|
||||||
|
offsets = {
|
||||||
|
{
|
||||||
|
filetype = "NvimTree",
|
||||||
|
text = function()
|
||||||
|
return vim.fn.getcwd()
|
||||||
|
end,
|
||||||
|
highlight = "Directory",
|
||||||
|
text_align = "left"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
94
nvim/after/plugin/cmp.lua
Normal file
94
nvim/after/plugin/cmp.lua
Normal file
|
@ -0,0 +1,94 @@
|
||||||
|
local cmp = require'cmp'
|
||||||
|
local luasnip = require'luasnip'
|
||||||
|
|
||||||
|
cmp.setup({
|
||||||
|
snippet = {
|
||||||
|
expand = function(args)
|
||||||
|
require('luasnip').lsp_expand(args.body)
|
||||||
|
end,
|
||||||
|
},
|
||||||
|
mapping = cmp.mapping.preset.insert({
|
||||||
|
['<C-p>'] = cmp.mapping.select_prev_item(),
|
||||||
|
['<C-n>'] = cmp.mapping.select_next_item(),
|
||||||
|
-- Add tab support
|
||||||
|
['<S-Tab>'] = cmp.mapping(function(fallback)
|
||||||
|
if cmp.visible() then
|
||||||
|
cmp.select_prev_item()
|
||||||
|
elseif luasnip.jumpable(-1) then
|
||||||
|
luasnip.jump(-1)
|
||||||
|
else
|
||||||
|
fallback()
|
||||||
|
end
|
||||||
|
end, { 'i', 's' }),
|
||||||
|
['<Tab>'] = cmp.mapping(function(fallback)
|
||||||
|
if cmp.visible() then
|
||||||
|
cmp.select_next_item()
|
||||||
|
elseif luasnip.expand_or_jumpable() then
|
||||||
|
luasnip.expand_or_jump()
|
||||||
|
else
|
||||||
|
fallback()
|
||||||
|
end
|
||||||
|
end, { 'i', 's' }),
|
||||||
|
['<C-f>'] = cmp.mapping.scroll_docs(-4),
|
||||||
|
['<C-d>'] = cmp.mapping.scroll_docs(4),
|
||||||
|
['<C-Space>'] = cmp.mapping.complete(),
|
||||||
|
['<C-e>'] = cmp.mapping.close(),
|
||||||
|
['<CR>'] = cmp.mapping.confirm({
|
||||||
|
behavior = cmp.ConfirmBehavior.Insert,
|
||||||
|
select = true,
|
||||||
|
})
|
||||||
|
}),
|
||||||
|
sources = cmp.config.sources({
|
||||||
|
{ name = 'path' }, -- file paths
|
||||||
|
{ name = 'nvim_lsp' }, -- from language server
|
||||||
|
{ name = 'nvim_lsp_signature_help'}, -- display function signatures with current parameter emphasized
|
||||||
|
{ name = 'luasnip' },
|
||||||
|
{ name = 'nvim_lua' }, -- complete neovim's Lua runtime API such vim.lsp.*
|
||||||
|
{ name = 'buffer' }, -- source current buffer
|
||||||
|
{ name = 'calc'}, -- source for math calculation
|
||||||
|
}),
|
||||||
|
window = {
|
||||||
|
completion = cmp.config.window.bordered(),
|
||||||
|
documentation = cmp.config.window.bordered(),
|
||||||
|
},
|
||||||
|
formatting = {
|
||||||
|
fields = {'menu', 'abbr', 'kind'},
|
||||||
|
format = function(entry, item)
|
||||||
|
local menu_icon ={
|
||||||
|
nvim_lsp = 'λ',
|
||||||
|
vsnip = '⋗',
|
||||||
|
buffer = 'Ω',
|
||||||
|
path = '🖫',
|
||||||
|
}
|
||||||
|
item.menu = menu_icon[entry.source.name]
|
||||||
|
return item
|
||||||
|
end,
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|
||||||
|
cmp.setup.filetype('gitcommit', {
|
||||||
|
sources = cmp.config.sources({
|
||||||
|
{ name = 'cmp_git' }, -- You can specify the `cmp_git` source if you were installed it.
|
||||||
|
}, {
|
||||||
|
{ name = 'buffer' },
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
-- Use buffer source for `/` (if you enabled `native_menu`, this won't work anymore).
|
||||||
|
cmp.setup.cmdline('/', {
|
||||||
|
mapping = cmp.mapping.preset.cmdline(),
|
||||||
|
sources = {
|
||||||
|
{ name = 'buffer' }
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
-- Use cmdline & path source for ':' (if you enabled `native_menu`, this won't work anymore).
|
||||||
|
cmp.setup.cmdline(':', {
|
||||||
|
mapping = cmp.mapping.preset.cmdline(),
|
||||||
|
sources = cmp.config.sources({
|
||||||
|
{ name = 'path' }
|
||||||
|
}, {
|
||||||
|
{ name = 'cmdline' }
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
14
nvim/after/plugin/general.lua
Normal file
14
nvim/after/plugin/general.lua
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
require('which-key').setup()
|
||||||
|
require('neogit').setup()
|
||||||
|
require('lualine').setup()
|
||||||
|
require('marks').setup()
|
||||||
|
require('Comment').setup()
|
||||||
|
require('illuminate').configure()
|
||||||
|
require("todo-comments").setup()
|
||||||
|
require("nvim-autopairs").setup()
|
||||||
|
require("fidget").setup()
|
||||||
|
require('nvim-highlight-colors').setup()
|
||||||
|
|
||||||
|
require('gitsigns').setup {
|
||||||
|
current_line_blame = true,
|
||||||
|
}
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
local function map(mode, keys, func, desc, silent)
|
local function map(mode, keys, func, desc, silent)
|
||||||
local silent = silent == nil and true or silent
|
local silent = silent == nil and true or silent
|
||||||
vim.keymap.set(mode, keys, func, { desc = desc, silent = silent })
|
vim.keymap.set(mode, keys, func, {desc = desc, silent = silent})
|
||||||
end
|
end
|
||||||
|
|
||||||
-- Movement between windows
|
-- Movement between windows
|
||||||
|
@ -11,19 +11,18 @@ map('n', '<leader>j', function() vim.cmd.wincmd('j') end, "Window Down")
|
||||||
map('n', '<leader>k', function() vim.cmd.wincmd('k') end, "Window Up")
|
map('n', '<leader>k', function() vim.cmd.wincmd('k') end, "Window Up")
|
||||||
map('n', '<leader>l', function() vim.cmd.wincmd('l') end, "Window Right")
|
map('n', '<leader>l', function() vim.cmd.wincmd('l') end, "Window Right")
|
||||||
|
|
||||||
-- Harpoon keybinds
|
-- Buffer hotkeys
|
||||||
map('n', '<leader>mm', require('harpoon.mark').add_file, "[M]ark file in harpoon")
|
map('n', '<leader>1', function() vim.cmd.BufferLineGoToBuffer(1) end, 'Tab 1')
|
||||||
map('n', '<leader>mh', require('harpoon.ui').toggle_quick_menu, "[M]enu [H]arpoon")
|
map('n', '<leader>2', function() vim.cmd.BufferLineGoToBuffer(2) end, 'Tab 2')
|
||||||
map('n', '<leader>1', function() require('harpoon.ui').nav_file(1) end, "Harpoon [1]")
|
map('n', '<leader>3', function() vim.cmd.BufferLineGoToBuffer(3) end, 'Tab 3')
|
||||||
map('n', '<leader>2', function() require('harpoon.ui').nav_file(2) end, "Harpoon [2]")
|
map('n', '<leader>4', function() vim.cmd.BufferLineGoToBuffer(4) end, 'Tab 4')
|
||||||
map('n', '<leader>3', function() require('harpoon.ui').nav_file(3) end, "Harpoon [3]")
|
map('n', '<leader>5', function() vim.cmd.BufferLineGoToBuffer(5) end, 'Tab 5')
|
||||||
map('n', '<leader>4', function() require('harpoon.ui').nav_file(4) end, "Harpoon [4]")
|
map('n', '<leader>6', function() vim.cmd.BufferLineGoToBuffer(6) end, 'Tab 6')
|
||||||
map('n', '<leader>5', function() require('harpoon.ui').nav_file(5) end, "Harpoon [5]")
|
map('n', '<leader>7', function() vim.cmd.BufferLineGoToBuffer(7) end, 'Tab 7')
|
||||||
map('n', '<leader>6', function() require('harpoon.ui').nav_file(6) end, "Harpoon [6]")
|
map('n', '<leader>8', function() vim.cmd.BufferLineGoToBuffer(8) end, 'Tab 8')
|
||||||
map('n', '<leader>7', function() require('harpoon.ui').nav_file(7) end, "Harpoon [7]")
|
map('n', '<leader>9', function() vim.cmd.BufferLineGoToBuffer(9) end, 'Tab 9')
|
||||||
map('n', '<leader>8', function() require('harpoon.ui').nav_file(8) end, "Harpoon [8]")
|
|
||||||
map('n', '<leader>9', function() require('harpoon.ui').nav_file(9) end, "Harpoon [9]")
|
|
||||||
|
|
||||||
|
map('n', '<leader>tt', vim.cmd.NvimTreeToggle, '[T]oggle file [T]ree')
|
||||||
map('n', '<leader>tg', vim.cmd.Neogit, '[T]oggle [G]it view')
|
map('n', '<leader>tg', vim.cmd.Neogit, '[T]oggle [G]it view')
|
||||||
map('n', '<leader>tu', require('undotree').toggle, '[T]oggle [U]ndo tree')
|
map('n', '<leader>tu', require('undotree').toggle, '[T]oggle [U]ndo tree')
|
||||||
|
|
||||||
|
@ -34,11 +33,12 @@ map('n', '<leader>q', vim.diagnostic.setloclist, 'Errors to [Q]uickfix')
|
||||||
|
|
||||||
|
|
||||||
map('n', '<leader>?', require('telescope.builtin').oldfiles, '[?] Find recently opened files')
|
map('n', '<leader>?', require('telescope.builtin').oldfiles, '[?] Find recently opened files')
|
||||||
map('n', '<leader><space>', require('telescope.builtin').find_files, '[ ]Search Files')
|
map('n', '<leader><space>', require('telescope.builtin').buffers, '[ ] Find existing buffers')
|
||||||
map('n', '<leader>sb', require('telescope.builtin').buffers, '[S]earch [B]uffers')
|
map('n', '<leader>sf', require('telescope.builtin').find_files, '[S]earch [F]iles')
|
||||||
map('n', '<leader>sh', require('telescope.builtin').help_tags, '[S]earch [H]elp')
|
map('n', '<leader>sh', require('telescope.builtin').help_tags, '[S]earch [H]elp')
|
||||||
map('n', '<leader>sw', require('telescope.builtin').grep_string, '[S]earch current [W]ord')
|
map('n', '<leader>sw', require('telescope.builtin').grep_string, '[S]earch current [W]ord')
|
||||||
map('n', '<leader>sg', require('telescope.builtin').live_grep, '[S]earch by [G]rep')
|
map('n', '<leader>sg', require('telescope.builtin').live_grep, '[S]earch by [G]rep')
|
||||||
map('n', '<leader>sd', require('telescope.builtin').diagnostics, '[S]earch [D]iagnostics')
|
map('n', '<leader>sd', require('telescope.builtin').diagnostics, '[S]earch [D]iagnostics')
|
||||||
|
|
||||||
map({ 'n', 't' }, '<A-t>', require("FTerm").toggle, 'Toggle Terminal')
|
map({'n', 't'}, '<A-t>', require("FTerm").toggle, 'Toggle Terminal')
|
||||||
|
|
132
nvim/after/plugin/lsp.lua
Normal file
132
nvim/after/plugin/lsp.lua
Normal file
|
@ -0,0 +1,132 @@
|
||||||
|
require("mason").setup()
|
||||||
|
require("mason-lspconfig").setup()
|
||||||
|
|
||||||
|
local capabilities = vim.lsp.protocol.make_client_capabilities()
|
||||||
|
capabilities = require('cmp_nvim_lsp').default_capabilities(capabilities)
|
||||||
|
|
||||||
|
local on_attach = function(_, bufnr)
|
||||||
|
local nmap = function(keys, func, desc)
|
||||||
|
if desc then
|
||||||
|
desc = 'LSP: ' .. desc
|
||||||
|
end
|
||||||
|
|
||||||
|
vim.keymap.set('n', keys, func, { buffer = bufnr, desc = desc })
|
||||||
|
end
|
||||||
|
|
||||||
|
nmap('<leader>rn', vim.lsp.buf.rename, '[R]e[n]ame')
|
||||||
|
nmap('<leader>ca', vim.lsp.buf.code_action, '[C]ode [A]ction')
|
||||||
|
|
||||||
|
nmap('gd', require('telescope.builtin').lsp_definitions, '[G]oto [D]efinition')
|
||||||
|
nmap('gr', require('telescope.builtin').lsp_references, '[G]oto [R]eferences')
|
||||||
|
nmap('gI', require('telescope.builtin').lsp_implementations, '[G]oto [I]mplementation')
|
||||||
|
nmap('<leader>D', require('telescope.builtin').lsp_type_definitions, 'Type [D]efinition')
|
||||||
|
nmap('<leader>ds', require('telescope.builtin').lsp_document_symbols, '[D]ocument [S]ymbols')
|
||||||
|
nmap('<leader>ws', require('telescope.builtin').lsp_dynamic_workspace_symbols, '[W]orkspace [S]ymbols')
|
||||||
|
|
||||||
|
-- See `:help K` for why this keymap
|
||||||
|
nmap('K', vim.lsp.buf.hover, 'Hover Documentation')
|
||||||
|
nmap('<C-k>', vim.lsp.buf.signature_help, 'Signature Documentation')
|
||||||
|
|
||||||
|
-- Lesser used LSP functionality
|
||||||
|
nmap('gD', vim.lsp.buf.declaration, '[G]oto [D]eclaration')
|
||||||
|
nmap('<leader>wa', vim.lsp.buf.add_workspace_folder, '[W]orkspace [A]dd Folder')
|
||||||
|
nmap('<leader>wr', vim.lsp.buf.remove_workspace_folder, '[W]orkspace [R]emove Folder')
|
||||||
|
nmap('<leader>wl', function()
|
||||||
|
print(vim.inspect(vim.lsp.buf.list_workspace_folders()))
|
||||||
|
end, '[W]orkspace [L]ist Folders')
|
||||||
|
|
||||||
|
-- Create a command `:Format` local to the LSP buffer
|
||||||
|
vim.api.nvim_buf_create_user_command(bufnr, 'Format', function(_)
|
||||||
|
if vim.lsp.buf.format then
|
||||||
|
vim.lsp.buf.format()
|
||||||
|
elseif vim.lsp.buf.formatting then
|
||||||
|
vim.lsp.buf.formatting()
|
||||||
|
end
|
||||||
|
end, { desc = 'Format current buffer with LSP' })
|
||||||
|
end
|
||||||
|
|
||||||
|
require("mason-lspconfig").setup_handlers({
|
||||||
|
function (server_name) -- default handler (optional)
|
||||||
|
if server_name == 'sumneko_lua' then
|
||||||
|
require("lspconfig")[server_name].setup {
|
||||||
|
capabilities = capabilities,
|
||||||
|
on_attach = on_attach,
|
||||||
|
settings = {
|
||||||
|
Lua = {
|
||||||
|
diagnostics = {
|
||||||
|
globals = {'vim'}
|
||||||
|
},
|
||||||
|
runtime = {
|
||||||
|
version = "LuaJIT",
|
||||||
|
path = vim.split(package.path, ";")
|
||||||
|
},
|
||||||
|
workspace = {
|
||||||
|
library = {
|
||||||
|
[vim.fn.expand("$VIMRUNTIME/lua")] = true,
|
||||||
|
[vim.fn.expand("$VIMRUNTIME/lua/vim/lsp")] = true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
}
|
||||||
|
else
|
||||||
|
require("lspconfig")[server_name].setup {
|
||||||
|
capabilities = capabilities,
|
||||||
|
on_attach = on_attach,
|
||||||
|
}
|
||||||
|
end
|
||||||
|
end,
|
||||||
|
})
|
||||||
|
|
||||||
|
require('mason-nvim-dap').setup()
|
||||||
|
|
||||||
|
|
||||||
|
local rt_config = {
|
||||||
|
server = {
|
||||||
|
on_attach = on_attach,
|
||||||
|
settings = {
|
||||||
|
["rust-analyzer"] = {
|
||||||
|
checkOnSave = {
|
||||||
|
command = "clippy"
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
require('rust-tools').setup(rt_config)
|
||||||
|
|
||||||
|
-- LSP Diagnostics Options Setup
|
||||||
|
local sign = function(opts)
|
||||||
|
vim.fn.sign_define(opts.name, {
|
||||||
|
texthl = opts.name,
|
||||||
|
text = opts.text,
|
||||||
|
numhl = ''
|
||||||
|
})
|
||||||
|
end
|
||||||
|
|
||||||
|
sign({name = 'DiagnosticSignError', text = ''})
|
||||||
|
sign({name = 'DiagnosticSignWarn', text = ''})
|
||||||
|
sign({name = 'DiagnosticSignHint', text = ''})
|
||||||
|
sign({name = 'DiagnosticSignInfo', text = ''})
|
||||||
|
|
||||||
|
vim.diagnostic.config({
|
||||||
|
virtual_text = false,
|
||||||
|
signs = true,
|
||||||
|
update_in_insert = true,
|
||||||
|
underline = true,
|
||||||
|
severity_sort = false,
|
||||||
|
float = {
|
||||||
|
border = 'rounded',
|
||||||
|
source = 'always',
|
||||||
|
header = '',
|
||||||
|
prefix = '',
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|
||||||
|
vim.cmd([[
|
||||||
|
autocmd CursorHold * lua vim.diagnostic.open_float(nil, { focusable = false })
|
||||||
|
]])
|
||||||
|
|
||||||
|
|
||||||
|
require('nvim-lightbulb').setup({autocmd = {enabled = true}})
|
19
nvim/after/plugin/nvim-tree.lua
Normal file
19
nvim/after/plugin/nvim-tree.lua
Normal file
|
@ -0,0 +1,19 @@
|
||||||
|
require('nvim-tree').setup {
|
||||||
|
sort_by = 'case_sensitive',
|
||||||
|
view = {
|
||||||
|
adaptive_size = true,
|
||||||
|
},
|
||||||
|
renderer = {
|
||||||
|
group_empty = true,
|
||||||
|
highlight_git = true,
|
||||||
|
highlight_opened_files = "name",
|
||||||
|
indent_markers = {
|
||||||
|
enable = true,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
filters = {
|
||||||
|
dotfiles = true,
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
require("lsp-file-operations").setup()
|
13
nvim/after/plugin/telescope.lua
Normal file
13
nvim/after/plugin/telescope.lua
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
require('telescope').setup {
|
||||||
|
defaults = {
|
||||||
|
mappings = {
|
||||||
|
i = {
|
||||||
|
['<C-u>'] = false,
|
||||||
|
['<C-d>'] = false,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
require("telescope").load_extension("ui-select")
|
||||||
|
pcall(require('telescope').load_extension, 'fzf')
|
24
nvim/after/plugin/treesitter.lua
Normal file
24
nvim/after/plugin/treesitter.lua
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
require('nvim-treesitter.configs').setup {
|
||||||
|
ensure_installed = { "lua", "rust", "toml" },
|
||||||
|
auto_install = true,
|
||||||
|
highlight = {
|
||||||
|
enable = true,
|
||||||
|
additional_vim_regex_highlighting = false,
|
||||||
|
},
|
||||||
|
indent = {
|
||||||
|
enable = true
|
||||||
|
},
|
||||||
|
rainbow = {
|
||||||
|
enable = true,
|
||||||
|
extended_mode = true,
|
||||||
|
max_file_lines = nil,
|
||||||
|
},
|
||||||
|
autotag = {
|
||||||
|
enable = true,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
-- Treesitter folding
|
||||||
|
vim.wo.foldmethod = 'expr'
|
||||||
|
vim.wo.foldexpr = 'nvim_treesitter#foldexpr()'
|
||||||
|
vim.o.foldenable = false
|
1
nvim/after/plugin/undotree.lua
Normal file
1
nvim/after/plugin/undotree.lua
Normal file
|
@ -0,0 +1 @@
|
||||||
|
require('undotree').setup()
|
|
@ -37,5 +37,28 @@ vim.opt.updatetime = 50
|
||||||
vim.opt.completeopt = { 'menuone', 'noselect', 'noinsert' }
|
vim.opt.completeopt = { 'menuone', 'noselect', 'noinsert' }
|
||||||
vim.opt.shortmess = vim.opt.shortmess + { c = true }
|
vim.opt.shortmess = vim.opt.shortmess + { c = true }
|
||||||
|
|
||||||
|
vim.opt.timeoutlen = 1000 -- For agda unicode chars to work properly
|
||||||
|
|
||||||
|
-- Languagetool stuff
|
||||||
|
vim.g.languagetool_server_command = '/usr/bin/languagetool --http'
|
||||||
|
|
||||||
|
-- Load plugins
|
||||||
|
require('kalle.plugins')
|
||||||
|
|
||||||
|
vim.cmd.colorscheme('carbonfox')
|
||||||
|
|
||||||
|
vim.g.vimtex_compiler_latexmk = { -- Make vimtex allow shell-escape while compiling
|
||||||
|
options = {
|
||||||
|
'-shell-escape',
|
||||||
|
'-verbose',
|
||||||
|
'-file-line-error',
|
||||||
|
'-synctex=1',
|
||||||
|
'-interaction=nonstopmode'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
-- Autoformat on save
|
-- Autoformat on save
|
||||||
vim.cmd [[autocmd BufWritePre * lua vim.lsp.buf.format()]]
|
vim.cmd [[autocmd BufWritePre * lua vim.lsp.buf.format()]]
|
||||||
|
|
||||||
|
-- TODO:
|
||||||
|
-- - Debugger integration (gdb?, java?/kotlin?, rust?, etc) - nvim-dap and friends
|
135
nvim/lua/kalle/plugins.lua
Normal file
135
nvim/lua/kalle/plugins.lua
Normal file
|
@ -0,0 +1,135 @@
|
||||||
|
vim.cmd([[
|
||||||
|
augroup packer_user_config
|
||||||
|
autocmd!
|
||||||
|
autocmd BufWritePost plugins.lua source <afile> | PackerCompile
|
||||||
|
augroup end
|
||||||
|
]])
|
||||||
|
|
||||||
|
local fn = vim.fn
|
||||||
|
local install_path = fn.stdpath('data') .. '/site/pack/packer/start/packer.nvim'
|
||||||
|
if fn.empty(fn.glob(install_path)) > 0 then
|
||||||
|
packer_bootstrap = fn.system({ 'git', 'clone', '--depth', '1', 'https://github.com/wbthomason/packer.nvim',
|
||||||
|
install_path })
|
||||||
|
vim.cmd [[packadd packer.nvim]]
|
||||||
|
end
|
||||||
|
|
||||||
|
return require('packer').startup({
|
||||||
|
function(use)
|
||||||
|
use('ashinkarov/nvim-agda')
|
||||||
|
use('lervag/vimtex')
|
||||||
|
use('vigoux/LanguageTool.nvim')
|
||||||
|
|
||||||
|
use('wbthomason/packer.nvim')
|
||||||
|
use('EdenEast/nightfox.nvim')
|
||||||
|
use('folke/which-key.nvim')
|
||||||
|
use('numToStr/FTerm.nvim')
|
||||||
|
|
||||||
|
use('brenoprata10/nvim-highlight-colors')
|
||||||
|
|
||||||
|
use('jiaoshijie/undotree')
|
||||||
|
|
||||||
|
use('j-hui/fidget.nvim')
|
||||||
|
|
||||||
|
use('elkowar/yuck.vim')
|
||||||
|
|
||||||
|
use('numToStr/Comment.nvim')
|
||||||
|
use('RRethy/vim-illuminate')
|
||||||
|
|
||||||
|
use {
|
||||||
|
'nvim-treesitter/nvim-treesitter',
|
||||||
|
run = function() require('nvim-treesitter.install').update({ with_sync = true }) end,
|
||||||
|
}
|
||||||
|
use('https://git.sr.ht/~p00f/nvim-ts-rainbow')
|
||||||
|
use('windwp/nvim-autopairs')
|
||||||
|
use('windwp/nvim-ts-autotag')
|
||||||
|
|
||||||
|
use {
|
||||||
|
'kosayoda/nvim-lightbulb',
|
||||||
|
requires = 'antoinemadec/FixCursorHold.nvim',
|
||||||
|
}
|
||||||
|
|
||||||
|
use {
|
||||||
|
'kyazdani42/nvim-tree.lua',
|
||||||
|
requires = {
|
||||||
|
'kyazdani42/nvim-web-devicons',
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
use {
|
||||||
|
'antosha417/nvim-lsp-file-operations',
|
||||||
|
requires = {
|
||||||
|
{ "nvim-lua/plenary.nvim" },
|
||||||
|
{ "kyazdani42/nvim-tree.lua" },
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
use {
|
||||||
|
"williamboman/mason.nvim",
|
||||||
|
"williamboman/mason-lspconfig.nvim",
|
||||||
|
}
|
||||||
|
|
||||||
|
use('simrat39/rust-tools.nvim')
|
||||||
|
|
||||||
|
use('chentoast/marks.nvim')
|
||||||
|
|
||||||
|
use('neovim/nvim-lspconfig')
|
||||||
|
|
||||||
|
use('mfussenegger/nvim-dap')
|
||||||
|
use('rcarriga/nvim-dap-ui')
|
||||||
|
use('theHamsta/nvim-dap-virtual-text')
|
||||||
|
use('nvim-telescope/telescope-dap.nvim')
|
||||||
|
use('jayp0521/mason-nvim-dap.nvim')
|
||||||
|
|
||||||
|
use {
|
||||||
|
'hrsh7th/cmp-nvim-lsp',
|
||||||
|
'hrsh7th/cmp-buffer',
|
||||||
|
'hrsh7th/cmp-path',
|
||||||
|
'hrsh7th/cmp-cmdline',
|
||||||
|
'hrsh7th/cmp-nvim-lsp-signature-help',
|
||||||
|
'hrsh7th/nvim-cmp',
|
||||||
|
'L3MON4D3/LuaSnip',
|
||||||
|
'saadparwaiz1/cmp_luasnip',
|
||||||
|
}
|
||||||
|
|
||||||
|
use 'famiu/bufdelete.nvim'
|
||||||
|
|
||||||
|
use {
|
||||||
|
'TimUntersberger/neogit',
|
||||||
|
'lewis6991/gitsigns.nvim',
|
||||||
|
}
|
||||||
|
use('nvim-lua/plenary.nvim')
|
||||||
|
|
||||||
|
use('nvim-lualine/lualine.nvim')
|
||||||
|
use {
|
||||||
|
'akinsho/bufferline.nvim', tag = "v2.*",
|
||||||
|
requires = 'kyazdani42/nvim-web-devicons'
|
||||||
|
}
|
||||||
|
|
||||||
|
use {
|
||||||
|
'nvim-telescope/telescope.nvim', tag = '0.1.0',
|
||||||
|
requires = {
|
||||||
|
'nvim-lua/plenary.nvim'
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
use('nvim-telescope/telescope-ui-select.nvim')
|
||||||
|
|
||||||
|
use('folke/todo-comments.nvim')
|
||||||
|
|
||||||
|
|
||||||
|
-- Automatically set up your configuration after cloning packer.nvim
|
||||||
|
-- Put this at the end after all plugins
|
||||||
|
if packer_bootstrap then
|
||||||
|
require('packer').sync()
|
||||||
|
end
|
||||||
|
end,
|
||||||
|
config = {
|
||||||
|
auto_reload_compiled = false, -- Automatically reload the compiled file after creating it.
|
||||||
|
display = {
|
||||||
|
open_fn = function()
|
||||||
|
return require('packer.util').float({ border = 'single' })
|
||||||
|
end
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
-- run bootstrap: nvim --headless -c 'autocmd User PackerComplete quitall' -c 'PackerSync'
|
339
nvim/plugin/packer_compiled.lua
Normal file
339
nvim/plugin/packer_compiled.lua
Normal file
|
@ -0,0 +1,339 @@
|
||||||
|
-- Automatically generated packer.nvim plugin loader code
|
||||||
|
|
||||||
|
if vim.api.nvim_call_function('has', {'nvim-0.5'}) ~= 1 then
|
||||||
|
vim.api.nvim_command('echohl WarningMsg | echom "Invalid Neovim version for packer.nvim! | echohl None"')
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
|
vim.api.nvim_command('packadd packer.nvim')
|
||||||
|
|
||||||
|
local no_errors, error_msg = pcall(function()
|
||||||
|
|
||||||
|
_G._packer = _G._packer or {}
|
||||||
|
_G._packer.inside_compile = true
|
||||||
|
|
||||||
|
local time
|
||||||
|
local profile_info
|
||||||
|
local should_profile = false
|
||||||
|
if should_profile then
|
||||||
|
local hrtime = vim.loop.hrtime
|
||||||
|
profile_info = {}
|
||||||
|
time = function(chunk, start)
|
||||||
|
if start then
|
||||||
|
profile_info[chunk] = hrtime()
|
||||||
|
else
|
||||||
|
profile_info[chunk] = (hrtime() - profile_info[chunk]) / 1e6
|
||||||
|
end
|
||||||
|
end
|
||||||
|
else
|
||||||
|
time = function(chunk, start) end
|
||||||
|
end
|
||||||
|
|
||||||
|
local function save_profiles(threshold)
|
||||||
|
local sorted_times = {}
|
||||||
|
for chunk_name, time_taken in pairs(profile_info) do
|
||||||
|
sorted_times[#sorted_times + 1] = {chunk_name, time_taken}
|
||||||
|
end
|
||||||
|
table.sort(sorted_times, function(a, b) return a[2] > b[2] end)
|
||||||
|
local results = {}
|
||||||
|
for i, elem in ipairs(sorted_times) do
|
||||||
|
if not threshold or threshold and elem[2] > threshold then
|
||||||
|
results[i] = elem[1] .. ' took ' .. elem[2] .. 'ms'
|
||||||
|
end
|
||||||
|
end
|
||||||
|
if threshold then
|
||||||
|
table.insert(results, '(Only showing plugins that took longer than ' .. threshold .. ' ms ' .. 'to load)')
|
||||||
|
end
|
||||||
|
|
||||||
|
_G._packer.profile_output = results
|
||||||
|
end
|
||||||
|
|
||||||
|
time([[Luarocks path setup]], true)
|
||||||
|
local package_path_str = "/home/kalle/.cache/nvim/packer_hererocks/2.1.1694285958/share/lua/5.1/?.lua;/home/kalle/.cache/nvim/packer_hererocks/2.1.1694285958/share/lua/5.1/?/init.lua;/home/kalle/.cache/nvim/packer_hererocks/2.1.1694285958/lib/luarocks/rocks-5.1/?.lua;/home/kalle/.cache/nvim/packer_hererocks/2.1.1694285958/lib/luarocks/rocks-5.1/?/init.lua"
|
||||||
|
local install_cpath_pattern = "/home/kalle/.cache/nvim/packer_hererocks/2.1.1694285958/lib/lua/5.1/?.so"
|
||||||
|
if not string.find(package.path, package_path_str, 1, true) then
|
||||||
|
package.path = package.path .. ';' .. package_path_str
|
||||||
|
end
|
||||||
|
|
||||||
|
if not string.find(package.cpath, install_cpath_pattern, 1, true) then
|
||||||
|
package.cpath = package.cpath .. ';' .. install_cpath_pattern
|
||||||
|
end
|
||||||
|
|
||||||
|
time([[Luarocks path setup]], false)
|
||||||
|
time([[try_loadstring definition]], true)
|
||||||
|
local function try_loadstring(s, component, name)
|
||||||
|
local success, result = pcall(loadstring(s), name, _G.packer_plugins[name])
|
||||||
|
if not success then
|
||||||
|
vim.schedule(function()
|
||||||
|
vim.api.nvim_notify('packer.nvim: Error running ' .. component .. ' for ' .. name .. ': ' .. result, vim.log.levels.ERROR, {})
|
||||||
|
end)
|
||||||
|
end
|
||||||
|
return result
|
||||||
|
end
|
||||||
|
|
||||||
|
time([[try_loadstring definition]], false)
|
||||||
|
time([[Defining packer_plugins]], true)
|
||||||
|
_G.packer_plugins = {
|
||||||
|
["Comment.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/Comment.nvim",
|
||||||
|
url = "https://github.com/numToStr/Comment.nvim"
|
||||||
|
},
|
||||||
|
["FTerm.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/FTerm.nvim",
|
||||||
|
url = "https://github.com/numToStr/FTerm.nvim"
|
||||||
|
},
|
||||||
|
["FixCursorHold.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/FixCursorHold.nvim",
|
||||||
|
url = "https://github.com/antoinemadec/FixCursorHold.nvim"
|
||||||
|
},
|
||||||
|
["LanguageTool.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/LanguageTool.nvim",
|
||||||
|
url = "https://github.com/vigoux/LanguageTool.nvim"
|
||||||
|
},
|
||||||
|
LuaSnip = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/LuaSnip",
|
||||||
|
url = "https://github.com/L3MON4D3/LuaSnip"
|
||||||
|
},
|
||||||
|
["bufdelete.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/bufdelete.nvim",
|
||||||
|
url = "https://github.com/famiu/bufdelete.nvim"
|
||||||
|
},
|
||||||
|
["bufferline.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/bufferline.nvim",
|
||||||
|
url = "https://github.com/akinsho/bufferline.nvim"
|
||||||
|
},
|
||||||
|
["cmp-buffer"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/cmp-buffer",
|
||||||
|
url = "https://github.com/hrsh7th/cmp-buffer"
|
||||||
|
},
|
||||||
|
["cmp-cmdline"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/cmp-cmdline",
|
||||||
|
url = "https://github.com/hrsh7th/cmp-cmdline"
|
||||||
|
},
|
||||||
|
["cmp-nvim-lsp"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/cmp-nvim-lsp",
|
||||||
|
url = "https://github.com/hrsh7th/cmp-nvim-lsp"
|
||||||
|
},
|
||||||
|
["cmp-nvim-lsp-signature-help"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/cmp-nvim-lsp-signature-help",
|
||||||
|
url = "https://github.com/hrsh7th/cmp-nvim-lsp-signature-help"
|
||||||
|
},
|
||||||
|
["cmp-path"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/cmp-path",
|
||||||
|
url = "https://github.com/hrsh7th/cmp-path"
|
||||||
|
},
|
||||||
|
cmp_luasnip = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/cmp_luasnip",
|
||||||
|
url = "https://github.com/saadparwaiz1/cmp_luasnip"
|
||||||
|
},
|
||||||
|
["fidget.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/fidget.nvim",
|
||||||
|
url = "https://github.com/j-hui/fidget.nvim"
|
||||||
|
},
|
||||||
|
["gitsigns.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/gitsigns.nvim",
|
||||||
|
url = "https://github.com/lewis6991/gitsigns.nvim"
|
||||||
|
},
|
||||||
|
["lualine.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/lualine.nvim",
|
||||||
|
url = "https://github.com/nvim-lualine/lualine.nvim"
|
||||||
|
},
|
||||||
|
["marks.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/marks.nvim",
|
||||||
|
url = "https://github.com/chentoast/marks.nvim"
|
||||||
|
},
|
||||||
|
["mason-lspconfig.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/mason-lspconfig.nvim",
|
||||||
|
url = "https://github.com/williamboman/mason-lspconfig.nvim"
|
||||||
|
},
|
||||||
|
["mason-nvim-dap.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/mason-nvim-dap.nvim",
|
||||||
|
url = "https://github.com/jayp0521/mason-nvim-dap.nvim"
|
||||||
|
},
|
||||||
|
["mason.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/mason.nvim",
|
||||||
|
url = "https://github.com/williamboman/mason.nvim"
|
||||||
|
},
|
||||||
|
neogit = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/neogit",
|
||||||
|
url = "https://github.com/TimUntersberger/neogit"
|
||||||
|
},
|
||||||
|
["nightfox.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/nightfox.nvim",
|
||||||
|
url = "https://github.com/EdenEast/nightfox.nvim"
|
||||||
|
},
|
||||||
|
["nvim-agda"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/nvim-agda",
|
||||||
|
url = "https://github.com/ashinkarov/nvim-agda"
|
||||||
|
},
|
||||||
|
["nvim-autopairs"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/nvim-autopairs",
|
||||||
|
url = "https://github.com/windwp/nvim-autopairs"
|
||||||
|
},
|
||||||
|
["nvim-cmp"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/nvim-cmp",
|
||||||
|
url = "https://github.com/hrsh7th/nvim-cmp"
|
||||||
|
},
|
||||||
|
["nvim-dap"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/nvim-dap",
|
||||||
|
url = "https://github.com/mfussenegger/nvim-dap"
|
||||||
|
},
|
||||||
|
["nvim-dap-ui"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/nvim-dap-ui",
|
||||||
|
url = "https://github.com/rcarriga/nvim-dap-ui"
|
||||||
|
},
|
||||||
|
["nvim-dap-virtual-text"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/nvim-dap-virtual-text",
|
||||||
|
url = "https://github.com/theHamsta/nvim-dap-virtual-text"
|
||||||
|
},
|
||||||
|
["nvim-highlight-colors"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/nvim-highlight-colors",
|
||||||
|
url = "https://github.com/brenoprata10/nvim-highlight-colors"
|
||||||
|
},
|
||||||
|
["nvim-lightbulb"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/nvim-lightbulb",
|
||||||
|
url = "https://github.com/kosayoda/nvim-lightbulb"
|
||||||
|
},
|
||||||
|
["nvim-lsp-file-operations"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/nvim-lsp-file-operations",
|
||||||
|
url = "https://github.com/antosha417/nvim-lsp-file-operations"
|
||||||
|
},
|
||||||
|
["nvim-lspconfig"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/nvim-lspconfig",
|
||||||
|
url = "https://github.com/neovim/nvim-lspconfig"
|
||||||
|
},
|
||||||
|
["nvim-tree.lua"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/nvim-tree.lua",
|
||||||
|
url = "https://github.com/kyazdani42/nvim-tree.lua"
|
||||||
|
},
|
||||||
|
["nvim-treesitter"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/nvim-treesitter",
|
||||||
|
url = "https://github.com/nvim-treesitter/nvim-treesitter"
|
||||||
|
},
|
||||||
|
["nvim-ts-autotag"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/nvim-ts-autotag",
|
||||||
|
url = "https://github.com/windwp/nvim-ts-autotag"
|
||||||
|
},
|
||||||
|
["nvim-ts-rainbow"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/nvim-ts-rainbow",
|
||||||
|
url = "https://git.sr.ht/~p00f/nvim-ts-rainbow"
|
||||||
|
},
|
||||||
|
["nvim-web-devicons"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/nvim-web-devicons",
|
||||||
|
url = "https://github.com/kyazdani42/nvim-web-devicons"
|
||||||
|
},
|
||||||
|
["packer.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/packer.nvim",
|
||||||
|
url = "https://github.com/wbthomason/packer.nvim"
|
||||||
|
},
|
||||||
|
["plenary.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/plenary.nvim",
|
||||||
|
url = "https://github.com/nvim-lua/plenary.nvim"
|
||||||
|
},
|
||||||
|
["rust-tools.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/rust-tools.nvim",
|
||||||
|
url = "https://github.com/simrat39/rust-tools.nvim"
|
||||||
|
},
|
||||||
|
["telescope-dap.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/telescope-dap.nvim",
|
||||||
|
url = "https://github.com/nvim-telescope/telescope-dap.nvim"
|
||||||
|
},
|
||||||
|
["telescope-ui-select.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/telescope-ui-select.nvim",
|
||||||
|
url = "https://github.com/nvim-telescope/telescope-ui-select.nvim"
|
||||||
|
},
|
||||||
|
["telescope.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/telescope.nvim",
|
||||||
|
url = "https://github.com/nvim-telescope/telescope.nvim"
|
||||||
|
},
|
||||||
|
["todo-comments.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/todo-comments.nvim",
|
||||||
|
url = "https://github.com/folke/todo-comments.nvim"
|
||||||
|
},
|
||||||
|
undotree = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/undotree",
|
||||||
|
url = "https://github.com/jiaoshijie/undotree"
|
||||||
|
},
|
||||||
|
["vim-illuminate"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/vim-illuminate",
|
||||||
|
url = "https://github.com/RRethy/vim-illuminate"
|
||||||
|
},
|
||||||
|
vimtex = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/vimtex",
|
||||||
|
url = "https://github.com/lervag/vimtex"
|
||||||
|
},
|
||||||
|
["which-key.nvim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/which-key.nvim",
|
||||||
|
url = "https://github.com/folke/which-key.nvim"
|
||||||
|
},
|
||||||
|
["yuck.vim"] = {
|
||||||
|
loaded = true,
|
||||||
|
path = "/home/kalle/.local/share/nvim/site/pack/packer/start/yuck.vim",
|
||||||
|
url = "https://github.com/elkowar/yuck.vim"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
time([[Defining packer_plugins]], false)
|
||||||
|
|
||||||
|
_G._packer.inside_compile = false
|
||||||
|
if _G._packer.needs_bufread == true then
|
||||||
|
vim.cmd("doautocmd BufRead")
|
||||||
|
end
|
||||||
|
_G._packer.needs_bufread = false
|
||||||
|
|
||||||
|
if should_profile then save_profiles() end
|
||||||
|
|
||||||
|
end)
|
||||||
|
|
||||||
|
if not no_errors then
|
||||||
|
error_msg = error_msg:gsub('"', '\\"')
|
||||||
|
vim.api.nvim_command('echohl ErrorMsg | echom "Error in packer_compiled: '..error_msg..'" | echom "Please check your config for correctness" | echohl None')
|
||||||
|
end
|
62
nvim/spell/en.utf-8.add
Normal file
62
nvim/spell/en.utf-8.add
Normal file
|
@ -0,0 +1,62 @@
|
||||||
|
unnamedplus
|
||||||
|
updatetime
|
||||||
|
menuone
|
||||||
|
noselect
|
||||||
|
noinsert
|
||||||
|
kalle
|
||||||
|
utils
|
||||||
|
colorscheme
|
||||||
|
config
|
||||||
|
carbonfox
|
||||||
|
lua
|
||||||
|
github
|
||||||
|
nvim
|
||||||
|
treesitter
|
||||||
|
FixCursorHold
|
||||||
|
lightbulb
|
||||||
|
antoinemadec
|
||||||
|
kosayoda
|
||||||
|
kyazdani42
|
||||||
|
devicons
|
||||||
|
lspconfig
|
||||||
|
williamboman
|
||||||
|
simrat39
|
||||||
|
chentoast
|
||||||
|
neovim
|
||||||
|
mfussenegger
|
||||||
|
rcarriga
|
||||||
|
theHamsta
|
||||||
|
dap
|
||||||
|
ui
|
||||||
|
jayp0521
|
||||||
|
MunifTanjim
|
||||||
|
noice
|
||||||
|
folke
|
||||||
|
numToStr
|
||||||
|
EdenEast
|
||||||
|
wbthomason
|
||||||
|
nui
|
||||||
|
RRethy
|
||||||
|
hrsh7th
|
||||||
|
cmp
|
||||||
|
cmdline
|
||||||
|
vsnip
|
||||||
|
lsp
|
||||||
|
bufdelete
|
||||||
|
famiu
|
||||||
|
TimUntersberger
|
||||||
|
lewis6991
|
||||||
|
neogit
|
||||||
|
gitsigns
|
||||||
|
lualine
|
||||||
|
bufferline
|
||||||
|
akinsho
|
||||||
|
v2
|
||||||
|
todo
|
||||||
|
nightfox
|
||||||
|
FTerm
|
||||||
|
dto
|
||||||
|
api
|
||||||
|
loadPage
|
||||||
|
hits
|
||||||
|
Bruijn
|
BIN
nvim/spell/en.utf-8.add.spl
Normal file
BIN
nvim/spell/en.utf-8.add.spl
Normal file
Binary file not shown.
|
@ -1,34 +0,0 @@
|
||||||
{
|
|
||||||
inputs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
|
|
||||||
{
|
|
||||||
nvim-plugins = final: prev: {
|
|
||||||
vimPlugins = prev.vimPlugins // {
|
|
||||||
rainbow-delimiters-nvim = prev.vimUtils.buildVimPlugin {
|
|
||||||
name = "raindow-delimiters.nvim";
|
|
||||||
src = inputs.plugin-rainbow-delimiters-nvim;
|
|
||||||
nvimSkipModule = [
|
|
||||||
"rainbow-delimiters.types"
|
|
||||||
"rainbow-delimiters._test.highlight"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
undotree-nvim = prev.vimUtils.buildVimPlugin {
|
|
||||||
name = "undotree.nvim";
|
|
||||||
src = inputs.plugin-undotree-nvim;
|
|
||||||
nvimSkipModule = [
|
|
||||||
"undotree"
|
|
||||||
"undotree.collector"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
harpoon1 = prev.vimUtils.buildVimPlugin {
|
|
||||||
name = "harpoon";
|
|
||||||
src = inputs.plugin-harpoon1;
|
|
||||||
doCheck = false;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
11
scripts/click
Executable file
11
scripts/click
Executable file
|
@ -0,0 +1,11 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
sleep 3
|
||||||
|
|
||||||
|
for i in $(seq 250); do
|
||||||
|
xdotool mousedown 3
|
||||||
|
sleep 0.010
|
||||||
|
xdotool mouseup 3
|
||||||
|
sleep 0.010
|
||||||
|
done
|
||||||
|
|
10
scripts/confirm-menu
Executable file
10
scripts/confirm-menu
Executable file
|
@ -0,0 +1,10 @@
|
||||||
|
#!/bin/bash
|
||||||
|
options="No\nNo\nNo\nNo\nNo\nYes"
|
||||||
|
|
||||||
|
selected=$(echo -e $options | rofi -p "$1" -mesg "Are you sure you want to run \"$2\"?" -dmenu -theme appsmenu)
|
||||||
|
|
||||||
|
case $selected in
|
||||||
|
"Yes")
|
||||||
|
$2
|
||||||
|
;;
|
||||||
|
esac
|
4
scripts/eww-playerctl-download-image
Executable file
4
scripts/eww-playerctl-download-image
Executable file
|
@ -0,0 +1,4 @@
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
cat | xargs -I '%' curl '%' -o /tmp/mpris-thumb 2>&1 | echo "/tmp/mpris-thumb"
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Reference in a new issue