summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjustanothercatgirl <sotov2070@gmail.com>2023-11-26 02:43:55 +0300
committerjustanothercatgirl <sotov2070@gmail.com>2023-11-26 02:43:55 +0300
commit417cf9b495ebd0da63148e9b5f07e23d9a573276 (patch)
tree09c92cc15cd732be4977c1682498e9ba5943354c
parent920caab3de6ca983a76dc277950158a2d9315210 (diff)
in the middle of creating proper nvim commit
-rw-r--r--.bashrc10
-rw-r--r--.config/i3/config24
-rw-r--r--.config/nvim/init.lua4
-rw-r--r--.config/nvim/lazy-lock.json6
-rw-r--r--.config/nvim/lua/user/beautiful.lua6
-rw-r--r--.config/nvim/lua/user/options.lua35
-rw-r--r--.config/nvim/lua/user/plugins.lua35
-rw-r--r--.config/nvim/lua/user/remaps.lua58
-rwxr-xr-x.screenlayout/doublemonitor.layout.sh2
9 files changed, 169 insertions, 11 deletions
diff --git a/.bashrc b/.bashrc
index 4f87462..0a3e7b3 100644
--- a/.bashrc
+++ b/.bashrc
@@ -1,3 +1,5 @@
+source ~/.cursed_bash.sh
+
# application shortcuts
alias ls="ls --color"
alias dl="bash download.sh"
@@ -7,6 +9,7 @@ alias cppreference="microsoft-edge-dev /usr/share/doc/cppreference/en/cpp.html"
alias nv=nvim
alias whatsapp=whatsie
alias lan="bash zerotierconnect.sh"
+alias python=/home/main/coding/py/venv/bin/python3
export c="/mnt/C"
export d="/mnt/D"
@@ -23,11 +26,16 @@ function kbon() { xinput reattach `xinput \
| grep "Virtual core keyboard" \
| sed -r 's/.+id=([0-9]+).+/\1/'` ; }
+function fix-ntfs() { \
+ sudo umount /dev/sda1 && \
+ sudo ntfsfix /dev/sda1 &&\
+ sudo mount /dev/sda1 /mnt/D ; }
+
# dotfiles
alias config='/usr/bin/git --git-dir=$HOME/.cfg --work-tree=$HOME'
GHC_PACKAGE_PATH="/usr/lib/ghc-9.0.2/package.conf.d"
# Created by `pipx` on 2023-08-09 18:40:17
-export PATH="$PATH:/home/main/.local/bin"
+export PATH="$PATH:/home/main/.local/bin:/home/main/.cargo/bin"
export VISUAL=vim
diff --git a/.config/i3/config b/.config/i3/config
index 7909229..9b11669 100644
--- a/.config/i3/config
+++ b/.config/i3/config
@@ -2,6 +2,8 @@
# 4.22 USER'S GUIDE CHANGE COLOURS
set $mod Mod4
set $terminal sakura
+set $lock_cmd i3lock -i ~/wallpaper/winlock.png -t -beef -up win
+
# Font for window titles. Will also be used by the bar unless a different font
# is used in the bar {} block below.
@@ -12,12 +14,15 @@ exec --no-startup-id dex --autostart --environment i3
# xss-lock grabs a logind suspend inhibit lock and will use i3lock to lock the
# screen before suspend. Use loginctl lock-session to lock your screen.
-exec --no-startup-id xss-lock --transfer-sleep-lock -- i3lock --nofork
+exec --no-startup-id xss-lock --transfer-sleep-lock -- $lock_cmd --nofork
# NetworkManager is the most popular way to manage wireless networks on Linux,
# and nm-applet is a desktop environment-independent system tray GUI for it.
exec --no-startup-id nm-applet
+exec_always --no-startup-id xcompmgr
+exec_always --no-startup-id devilspie -a
+
# Use pactl to adjust volume in PulseAudio.
set $refresh_i3status killall -SIGUSR1 i3status
#set $refresh_i3status killall -SIGUSR1 xmobar
@@ -107,7 +112,7 @@ bindsym $mod+space focus mode_toggle
bindsym $mod+a focus parent
#lock i3lock
-bindsym $mod+Shift+x exec i3lock
+bindsym $mod+Shift+x exec $lock_cmd
# focus the child container
bindsym $mod+Shift+a focus child
@@ -165,6 +170,7 @@ assign [class="pr"] workspace $ws5
assign [class="pm"] workspace $ws5
assign [class="vlc"] workspace $ws8
assign [class="libreoffice"] workspace $ws5
+assign [class="steam"] workspace $ws9
#assign [class="GigaQt"] workspace $ws9
@@ -219,7 +225,7 @@ mode "resize" {
bindsym $mod+r mode "default"
}
-set $ModeName "[e]xit [Enter] | [r]eboot | [s]hutdown | shudown [n]ow | [h]ibernate"
+set $ModeName "[e]xit [Enter] | [r]eboot | [s]hutdown | shudown [n]ow | [h]ibernate | s[u]spend"
mode $ModeName{
bindsym Return exec i3-msg exit
@@ -229,7 +235,8 @@ mode $ModeName{
bindsym n exec shutdown +0
# bindsym t exec "i3-msg exit && startx"
bindsym Escape mode "default"
- bindsym h exec systemctl hibernate
+ bindsym h mode "default"; exec systemctl hibernate
+ bindsym u mode "default"; exec systemctl suspend
}
# modes
@@ -259,19 +266,18 @@ exec kboff
# switch keyboard colors
exec openrgb --color "00FFFF"
-exec $terminal
exec $terminal
+exec $terminal -e bashtop
exec microsoft-edge-dev
#exec telegram-desktop
#exec discord
#exec qtcreator
#exec doublecmd
-exec_always feh --bg-fill ~/wallpaper/october2023.png
+exec_always feh --bg-fill ~/wallpaper/nov2023.png
exec_always setxkbmap -layout us,ru -option grp:alt_shift_toggle
exec_always ~/.screenlayout/fullscreen.sh
-exec_always xset r rate 333 25
-
-
+# exec_always xset r rate 269 19
+exec_always xset r rate 222 22
# empty lines at the EOF
diff --git a/.config/nvim/init.lua b/.config/nvim/init.lua
new file mode 100644
index 0000000..6eafd2c
--- /dev/null
+++ b/.config/nvim/init.lua
@@ -0,0 +1,4 @@
+require "user.options"
+require "user.remaps"
+require "user.plugins"
+require "user.beautiful"
diff --git a/.config/nvim/lazy-lock.json b/.config/nvim/lazy-lock.json
new file mode 100644
index 0000000..c7e83a4
--- /dev/null
+++ b/.config/nvim/lazy-lock.json
@@ -0,0 +1,6 @@
+{
+ "awesome-vim-colorschemes": { "branch": "master", "commit": "4b2787b8894c4a70c42d15c2808d7cf278cb6abb" },
+ "lazy.nvim": { "branch": "main", "commit": "96584866b9c5e998cbae300594d0ccfd0c464627" },
+ "vim-commentary": { "branch": "master", "commit": "e87cd90dc09c2a203e13af9704bd0ef79303d755" },
+ "which-key.nvim": { "branch": "main", "commit": "4433e5ec9a507e5097571ed55c02ea9658fb268a" }
+} \ No newline at end of file
diff --git a/.config/nvim/lua/user/beautiful.lua b/.config/nvim/lua/user/beautiful.lua
new file mode 100644
index 0000000..17b7ed5
--- /dev/null
+++ b/.config/nvim/lua/user/beautiful.lua
@@ -0,0 +1,6 @@
+-- this file contains configuration for colorschemes e.t.c
+
+local colorscheme = "habamax"
+-- local colorscheme = "evening"
+vim.cmd("colo " .. colorscheme)
+
diff --git a/.config/nvim/lua/user/options.lua b/.config/nvim/lua/user/options.lua
new file mode 100644
index 0000000..a8e58bc
--- /dev/null
+++ b/.config/nvim/lua/user/options.lua
@@ -0,0 +1,35 @@
+-- this file contains general options for nvim
+
+local o = vim.opt
+
+local options = {
+ -- general options
+ backup = false,
+ clipboard = "unnamedplus",
+ cmdheight = 1,
+ conceallevel = 0,
+ fileencoding = "utf-8",
+ hlsearch = true,
+ mouse = "a",
+ showmode = true,
+ tabstop = 8,
+ shiftwidth = 8,
+ smartindent = true,
+ swapfile = false,
+ timeoutlen = 1000, --ms
+ updatetime = 300,
+ writebackup = false,
+ expandtab = false, -- !!!!!!!!!
+ cursorline = false,
+ number = true,
+ wrap = false,
+ -- splitting
+ splitbelow = true,
+ splitright = true,
+}
+
+for key, val in pairs(options) do
+ o[key] = val
+end
+
+-- vim.cmd('colo evening')
diff --git a/.config/nvim/lua/user/plugins.lua b/.config/nvim/lua/user/plugins.lua
new file mode 100644
index 0000000..2344087
--- /dev/null
+++ b/.config/nvim/lua/user/plugins.lua
@@ -0,0 +1,35 @@
+-- this file contains plugin settings as well as initialization of lazy.nvim
+
+
+-- plugins to be installed
+plugins = {
+ "folke/lazy.nvim", -- plugin manager
+ "folke/which-key.nvim", -- pretty self-descriptive name
+ "rafi/awesome-vim-colorschemes", -- same here
+ "tpope/vim-commentary" -- gc & gcc for commenting
+}
+
+-- options for lazy
+opts = {
+
+}
+
+
+-- some lazy.nvim magic
+local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
+if not vim.loop.fs_stat(lazypath) then
+ vim.fn.system({
+ "git",
+ "clone",
+ "--filter=blob:none",
+ "https://github.com/folke/lazy.nvim.git",
+ "--branch=stable", -- latest stable release
+ lazypath,
+ })
+end
+vim.opt.rtp:prepend(lazypath)
+
+-- initialization
+lazy = require("lazy")
+lazy.setup(plugins, opts)
+
diff --git a/.config/nvim/lua/user/remaps.lua b/.config/nvim/lua/user/remaps.lua
new file mode 100644
index 0000000..742e967
--- /dev/null
+++ b/.config/nvim/lua/user/remaps.lua
@@ -0,0 +1,58 @@
+-- this file contains general remappings for this nvim configuration
+
+local opt = { noremap = true, silent = true }
+
+local map = vim.api.nvim_set_keymap
+
+map("", "\\", "<Nop>", opt)
+vim.g.mapleader = "\\"
+
+-- some minor commands
+map("c", "w!!", "w !sudo tee % > /dev/null", opt)
+
+-- remap j and k
+-- i refuse to elaborate
+map("n", "j", "<Up>", opt)
+map("n", "k", "<Down>", opt)
+
+-- window navigation
+map("n", "<C-l>", "<C-w>l", opt)
+map("n", "<C-j>", "<C-w>k", opt) -- SWITCHED K AND J
+map("n", "<C-k>", "<C-w>j", opt) -- SWITCHED K AND J
+map("n", "<C-h>", "<C-w>h", opt)
+
+-- Insert mode navigation
+map("i", "<C-h>", "<Left>", opt)
+map("i", "<C-j>", "<Up>", opt) -- SWITCHED K AND J
+map("i", "<C-k>", "<Down>", opt) -- SWITCHED K AND J
+map("i", "<C-l>", "<Right>", opt)
+
+-- lexer options..?
+map("n", "<leader>e", ":Lex 49<cr>", opt)
+
+-- resizing options
+map("n", "<C-Left>", ":vertical resize -5<cr>", opt)
+map("n", "<C-Up>", ":resize +5<cr>", opt)
+map("n", "<C-Right>", ":vertical resize +5<cr>", opt)
+map("n", "<C-Down>", ":resize -5<cr>", opt)
+
+-- better indentation
+map("v", "<", "<gv", opt)
+map("v", ">", ">gv", opt)
+
+-- moving lines
+map("n", "<A-j>", ":m .-2<CR>==", opt) -- SWITCHED K AND J
+map("n", "<A-k>", ":m .+1<CR>==", opt) -- SWITCHED K AND J
+
+-- duplicating lines
+map("n", "<C-Up>", ":.,.t.-1<CR>==", opt)
+map("n", "<C-Down>", ":.,.t.<CR>==", opt)
+
+-- leader remaps
+map("n", "<leader>/", ":nohlsearch<CR>", opt) -- discard search highlighting
+map("n", "<leader>T", ":term<CR>", opt) -- open terminal fullscreen with \T
+map("n", "<leader>t", ":vsplit term <CR>", opt) -- split to terminal with \t
+map("n", "<leader>pl", ":Lazy<CR>", opt) -- open plugin manager
+
+-- miscellaneous
+map("n", "<leader>relaod", ":luafile ~/.config/nvim/lua/init.lua", {noremap = false})
diff --git a/.screenlayout/doublemonitor.layout.sh b/.screenlayout/doublemonitor.layout.sh
index 371cba6..3b3937d 100755
--- a/.screenlayout/doublemonitor.layout.sh
+++ b/.screenlayout/doublemonitor.layout.sh
@@ -1,2 +1,2 @@
#!/bin/sh
-xrandr --output eDP1 --primary --mode 1920x1080 --pos 1360x0 --rotate normal --output DP1 --off --output DP2 --off --output HDMI1 --off --output HDMI2 --off --output VIRTUAL1 --off --output HDMI-1-0 --mode 1360x768 --pos 0x0 --rotate normal
+xrandr --output eDP1 --primary --mode 1920x1080 --pos 1360x0 --rotate normal --output DP1 --off --output DP2 --off --output HDMI1 --off --output HDMI2 --off --output VIRTUAL1 --off --output HDMI-1-0 --mode 1360x768 --pos 0x156 --rotate normal