diff --git a/.bash_profile b/.bash_profile index f340060..159897b 100644 --- a/.bash_profile +++ b/.bash_profile @@ -15,4 +15,3 @@ fi #export DISPLAY=$(cat /etc/resolv.conf | grep nameserver | awk '{print $2}'):0 -export DWM_NOTIF_FILE="/home/iceyrazor/stuff/scripts/c/SDL/notif/notif.txt" diff --git a/.bashrc b/.bashrc old mode 100755 new mode 100644 index a92d2ed..6e08ede --- a/.bashrc +++ b/.bashrc @@ -4,7 +4,7 @@ # If not running interactively, don't do anything [[ $- != *i* ]] && return -PS1='\[\e[37;1m\][\[\e[31;1m\]B\[\e[35;1m\]\u\[\e[33m\]@\[\e[35;1m\]\h \[\e[36;1m\]\W\[\e[37;1m\]]\[\e[0;1m\]∮ ' +PS1='\[\e[37;1m\][\[\e[35;1m\]\u\[\e[33m\]@\[\e[35;1m\]\h \[\e[36;1m\]\W\[\e[37;1m\]]\[\e[0;1m\]∮ ' -source ~/stuff/scripts/system/neoboot.sh +~/stuff/scripts/system/neoboot.sh source ~/.profile diff --git a/.config/atuin/config.toml b/.config/atuin/config.toml new file mode 100644 index 0000000..7ae0b79 --- /dev/null +++ b/.config/atuin/config.toml @@ -0,0 +1,234 @@ +## where to store your database, default is your system data directory +## linux/mac: ~/.local/share/atuin/history.db +## windows: %USERPROFILE%/.local/share/atuin/history.db +# db_path = "~/.history.db" + +## where to store your encryption key, default is your system data directory +## linux/mac: ~/.local/share/atuin/key +## windows: %USERPROFILE%/.local/share/atuin/key +# key_path = "~/.key" + +## where to store your auth session token, default is your system data directory +## linux/mac: ~/.local/share/atuin/session +## windows: %USERPROFILE%/.local/share/atuin/session +# session_path = "~/.session" + +## date format used, either "us" or "uk" +# dialect = "us" + +## default timezone to use when displaying time +## either "l", "local" to use the system's current local timezone, or an offset +## from UTC in the format of "<+|->H[H][:M[M][:S[S]]]" +## for example: "+9", "-05", "+03:30", "-01:23:45", etc. +# timezone = "local" + +## enable or disable automatic sync +# auto_sync = true + +## enable or disable automatic update checks +# update_check = true + +## address of the sync server +# sync_address = "https://api.atuin.sh" + +## how often to sync history. note that this is only triggered when a command +## is ran, so sync intervals may well be longer +## set it to 0 to sync after every command +# sync_frequency = "10m" + +## which search mode to use +## possible values: prefix, fulltext, fuzzy, skim +# search_mode = "fuzzy" + +## which filter mode to use +## possible values: global, host, session, directory +# filter_mode = "global" + +## With workspace filtering enabled, Atuin will filter for commands executed +## in any directory within a git repository tree (default: false) +# workspaces = false + +## which filter mode to use when atuin is invoked from a shell up-key binding +## the accepted values are identical to those of "filter_mode" +## leave unspecified to use same mode set in "filter_mode" +# filter_mode_shell_up_key_binding = "global" + +## which search mode to use when atuin is invoked from a shell up-key binding +## the accepted values are identical to those of "search_mode" +## leave unspecified to use same mode set in "search_mode" +# search_mode_shell_up_key_binding = "fuzzy" + +## which style to use +## possible values: auto, full, compact +# style = "auto" + +## the maximum number of lines the interface should take up +## set it to 0 to always go full screen +# inline_height = 0 +inline_height = 0 + +## Invert the UI - put the search bar at the top , Default to `false` +# invert = false + +## enable or disable showing a preview of the selected command +## useful when the command is longer than the terminal width and is cut off +# show_preview = true + +## what to do when the escape key is pressed when searching +## possible values: return-original, return-query +# exit_mode = "return-original" + +## possible values: emacs, subl +# word_jump_mode = "emacs" + +## characters that count as a part of a word +# word_chars = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789" + +## number of context lines to show when scrolling by pages +# scroll_context_lines = 1 + +## use ctrl instead of alt as the shortcut modifier key for numerical UI shortcuts +## alt-0 .. alt-9 +# ctrl_n_shortcuts = false + +## default history list format - can also be specified with the --format arg +# history_format = "{time}\t{command}\t{duration}" + +## prevent commands matching any of these regexes from being written to history. +## Note that these regular expressions are unanchored, i.e. if they don't start +## with ^ or end with $, they'll match anywhere in the command. +## For details on the supported regular expression syntax, see +## https://docs.rs/regex/latest/regex/#syntax +# history_filter = [ +# "^secret-cmd", +# "^innocuous-cmd .*--secret=.+", +# ] + +## prevent commands run with cwd matching any of these regexes from being written +## to history. Note that these regular expressions are unanchored, i.e. if they don't +## start with ^ or end with $, they'll match anywhere in CWD. +## For details on the supported regular expression syntax, see +## https://docs.rs/regex/latest/regex/#syntax +# cwd_filter = [ +# "^/very/secret/area", +# ] + +## Configure the maximum height of the preview to show. +## Useful when you have long scripts in your history that you want to distinguish +## by more than the first few lines. +# max_preview_height = 4 + +## Configure whether or not to show the help row, which includes the current Atuin +## version (and whether an update is available), a keymap hint, and the total +## amount of commands in your history. +# show_help = true + +## Configure whether or not to show tabs for search and inspect +# show_tabs = true + +## Defaults to true. This matches history against a set of default regex, and will not save it if we get a match. Defaults include +## 1. AWS key id +## 2. Github pat (old and new) +## 3. Slack oauth tokens (bot, user) +## 4. Slack webhooks +## 5. Stripe live/test keys +# secrets_filter = true + +## Defaults to true. If enabled, upon hitting enter Atuin will immediately execute the command. Press tab to return to the shell and edit. +# This applies for new installs. Old installs will keep the old behaviour unless configured otherwise. +enter_accept = true + +## Defaults to "emacs". This specifies the keymap on the startup of `atuin +## search`. If this is set to "auto", the startup keymap mode in the Atuin +## search is automatically selected based on the shell's keymap where the +## keybinding is defined. If this is set to "emacs", "vim-insert", or +## "vim-normal", the startup keymap mode in the Atuin search is forced to be +## the specified one. +# keymap_mode = "auto" +keymap_mode = "vim-normal" + +## Cursor style in each keymap mode. If specified, the cursor style is changed +## in entering the cursor shape. Available values are "default" and +## "{blink,steady}-{block,underline,bar}". +# keymap_cursor = { emacs = "blink-block", vim_insert = "blink-block", vim_normal = "steady-block" } + +# network_connect_timeout = 5 +# network_timeout = 5 + +## Timeout (in seconds) for acquiring a local database connection (sqlite) +# local_timeout = 5 + +## Set this to true and Atuin will minimize motion in the UI - timers will not update live, etc. +## Alternatively, set env NO_MOTION=true +# prefers_reduced_motion = false + +[stats] +## Set commands where we should consider the subcommand for statistics. Eg, kubectl get vs just kubectl +# common_subcommands = [ +# "apt", +# "cargo", +# "composer", +# "dnf", +# "docker", +# "git", +# "go", +# "ip", +# "kubectl", +# "nix", +# "nmcli", +# "npm", +# "pecl", +# "pnpm", +# "podman", +# "port", +# "systemctl", +# "tmux", +# "yarn", +# ] + +## Set commands that should be totally stripped and ignored from stats +# common_prefix = ["sudo"] + +## Set commands that will be completely ignored from stats +# ignored_commands = [ +# "cd", +# "ls", +# "vi" +# ] + +[keys] +# Defaults to true. If disabled, using the up/down key won't exit the TUI when scrolled past the first/last entry. +# scroll_exits = false + +[sync] +# Enable sync v2 by default +# This ensures that sync v2 is enabled for new installs only +# In a later release it will become the default across the board +records = true + +[preview] +## which preview strategy to use to calculate the preview height (respects max_preview_height). +## possible values: auto, static +## auto: length of the selected command. +## static: length of the longest command stored in the history. +# strategy = "auto" + +[daemon] +## Enables using the daemon to sync. Requires the daemon to be running in the background. Start it with `atuin daemon` +# enabled = false + +## How often the daemon should sync in seconds +# sync_frequency = 300 + +## The path to the unix socket used by the daemon (on unix systems) +## linux/mac: ~/.local/share/atuin/atuin.sock +## windows: Not Supported +# socket_path = "~/.local/share/atuin/atuin.sock" + +## Use systemd socket activation rather than opening the given path (the path must still be correct for the client) +## linux: false +## mac/windows: Not Supported +# systemd_socket = false + +## The port that should be used for TCP on non unix systems +# tcp_port = 8889 diff --git a/.config/awesome/iceys-theme/theme.lua b/.config/awesome/iceys-theme/theme.lua index 1bbefc3..b95b641 100644 --- a/.config/awesome/iceys-theme/theme.lua +++ b/.config/awesome/iceys-theme/theme.lua @@ -80,6 +80,9 @@ theme.taglist_squares_unsel = theme_assets.taglist_squares_unsel( theme.menu_submenu_icon = themes_path.."submenu.png" theme.menu_height = dpi(15) theme.menu_width = dpi(100) +theme.notification_bg = "#222222" +theme.notification_border_color = theme.border_focus +theme.notification_font = "inconsolata regular 15" -- You can add as many variables as -- you wish and access them by using diff --git a/.config/awesome/rc.lua b/.config/awesome/rc.lua index c2c4e1e..d147ebd 100644 --- a/.config/awesome/rc.lua +++ b/.config/awesome/rc.lua @@ -18,8 +18,8 @@ local hotkeys_popup = require("awful.hotkeys_popup") -- when client with a matching name is opened: require("awful.hotkeys_popup.keys") -local HOMEDIR="/home/iceyrazor/" - +local HOMEDIR="/home/iceyrazor" +local mpris=HOMEDIR.."/stuff/scripts/system/mpris_player_control" local show_desktop = false @@ -40,6 +40,7 @@ function show_my_desktop() end --auto switch to tag with clients if no current clients exist in current tag +--[[ client.connect_signal("unmanage", function(c) local t = c.first_tag or awful.screen.focused().selected_tag for _, cl in ipairs(t:clients()) do @@ -54,6 +55,7 @@ client.connect_signal("unmanage", function(c) end end end) +]]-- -- {{{ Error handling @@ -98,6 +100,10 @@ editor_cmd = terminal .. " -e " .. editor -- I suggest you to remap Mod4 to another key using xmodmap or other tools. -- However, you can use another modifier like Mod1, but it may interact with others. modkey = "Mod4" +if awesome.hostname == "DangerNoodle" then + --modkey = "Mod3" +end + -- Table of layouts to cover with awful.layout.inc, order matters. awful.layout.layouts = { @@ -189,7 +195,8 @@ local tasklist_buttons = gears.table.join( end), awful.button({ }, 5, function () awful.client.focus.byidx(-1) - end)) + end) +) local function set_wallpaper(s) -- Wallpaper @@ -212,7 +219,7 @@ awful.screen.connect_for_each_screen(function(s) -- Each screen has its own tag table. --awful.tag({ "1", "2", "3", "4", "5", "6", "7", "8", "9" }, s, awful.layout.layouts[2]) - awful.tag({ "  ", "  ", "  ", "  ", "  ", "  ", "  ", "  ", "  ", "  " }, s, awful.layout.layouts[2]) + awful.tag({ "  ", "  ", "  ", "  ", "  ", "  ", "  ", "  ", "  ", "  " }, s, awful.layout.layouts[2]) -- Create a promptbox for each screen s.mypromptbox = awful.widget.prompt() @@ -242,32 +249,51 @@ awful.screen.connect_for_each_screen(function(s) s.mywibox = awful.wibar({ position = "bottom", screen = s , height = 20}) -- Add widgets to the wibox - s.mywibox:setup { - layout = wibox.layout.align.horizontal, - { -- Left widgets - layout = wibox.layout.fixed.horizontal, - mylauncher, - s.mytaglist, - s.mypromptbox, - }, - s.mytasklist, -- Middle widget - { -- Right widgets - layout = wibox.layout.fixed.horizontal, - mykeyboardlayout, - awful.widget.watch(HOMEDIR..'stuff/scripts/system/stbar/stbar-awesome.sh', 2), - mytextclock, - wibox.widget.systray(), - s.mylayoutbox, - }, - } + if s.index==1 then + s.mywibox:setup { + layout = wibox.layout.align.horizontal, + { -- Left widgets + layout = wibox.layout.fixed.horizontal, + mylauncher, + s.mytaglist, + s.mypromptbox, + }, + s.mytasklist, -- Middle widget + { -- Right widgets + layout = wibox.layout.fixed.horizontal, + mykeyboardlayout, + awful.widget.watch(HOMEDIR..'/stuff/scripts/system/stbar/stbar-awesome.sh', 2), + mytextclock, + wibox.widget.systray(), + s.mylayoutbox, + }, + } + else + s.mywibox:setup { + layout = wibox.layout.align.horizontal, + { -- Left widgets + layout = wibox.layout.fixed.horizontal, + mylauncher, + s.mytaglist, + s.mypromptbox, + }, + s.mytasklist, -- Middle widget + { -- Right widgets + layout = wibox.layout.fixed.horizontal, + mykeyboardlayout, + mytextclock, + wibox.widget.systray(), + s.mylayoutbox, + }, + } + end end) -local month_calendar = awful.widget.calendar_popup.month() +local month_calendar = awful.widget.calendar_popup.month({start_sunday=true}) month_calendar:attach( mytextclock, "br" ) --mytextclock:connect_signal("button::press",function () --end) -screen[2]:fake_resize(1920,0,1790,1006) -- }}} -- {{{ Mouse bindings @@ -381,7 +407,33 @@ globalkeys = gears.table.join( {description = "lua execute prompt", group = "awesome"}), -- Menubar awful.key({ modkey }, "p", function() menubar.show() end, - {description = "show the menubar", group = "launcher"}) + {description = "show the menubar", group = "launcher"}), + + awful.key({ }, "XF86AudioNext", function () awful.util.spawn("mpc next") end), + awful.key({ }, "XF86AudioPrev", function () awful.util.spawn("mpc prev") end), + awful.key({ }, "XF86AudioPlay", function () awful.util.spawn(mpris.." -a PlayPause") end), + awful.key({ }, "XF86AudioStop", function () awful.util.spawn(mpris.." -a pause") end), + --awful.key({ }, "XF86AudioRaiseVolume", function () awful.util.spawn("amixer -D pulse sset Master 2%+", false) end), + awful.key({ }, "XF86AudioRaiseVolume", function () awful.util.spawn("pactl set-sink-volume @DEFAULT_SINK@ +2%", false) end), + awful.key({ }, "XF86AudioLowerVolume", function () awful.util.spawn("pactl set-sink-volume @DEFAULT_SINK@ -2%", false) end), + awful.key({ }, "XF86AudioMute", function () + awful.spawn("pactl set-source-mute @DEFAULT_SOURCE@ toggle", false) + awful.spawn.with_shell("notify-send 'mic' \"$(pactl get-source-mute @DEFAULT_SOURCE@)\"", false) + end), + --also pamixer -i 5 #to increase 5% + --pamixer -d 5 #to decrease 5% + + awful.key({ }, "Print", function() + awful.spawn.with_shell("ffmpeg -f x11grab -framerate 1 -video_size 1920x1200 -i :0.0 -vframes 1 -crf 0 ~/Pictures/Screenshots/$(date '+%m-%d-%Y-%I-%M')_${RANDOM}_screenshot.jpg") + gears.timer.start_new(3, function() + naughty.notify({title="screenshot taken",text="possibly"}) + return false -- Stop the timer after the first iteration + end) + end), + + awful.key({ "Shift" }, "Print", function() + awful.spawn.with_shell("/bin/flameshot screen") + end) ) clientkeys = gears.table.join( @@ -401,6 +453,8 @@ clientkeys = gears.table.join( {description = "move to screen", group = "client"}), awful.key({ modkey, }, "t", function (c) c.ontop = not c.ontop end, {description = "toggle keep on top", group = "client"}), + awful.key({ modkey, "Shift" }, "s", function (c) c.sticky = not c.sticky end, + {description = "toggle sticky mode", group="client"}), awful.key({ modkey, "Shift" }, "n", function (c) -- The client currently has the input focus, so it cannot be @@ -541,6 +595,7 @@ awful.rules.rules = { "MessageWin", -- kalarm. "Sxiv", "Tor Browser", -- Needs a fixed window size to avoid fingerprinting by screen size. + "nheko", "Wpa_gui", "Pcmanfm", "veromix", @@ -550,6 +605,7 @@ awful.rules.rules = { -- and the name shown there might not match defined rules here. name = { "Event Tester", -- xev. + "LinVAM", }, role = { "AlarmWindow", -- Thunderbird's calendar. @@ -563,14 +619,16 @@ awful.rules.rules = { }, properties = { titlebars_enabled = false } }, + --[[ { rule_any = { class = { "Mumble", "Gajim", "vesktop" } }, properties = { floating = true, screen = 2 } }, + --]] { rule_any = { - class = { "steam_app*" } + class = { "steam_app*", "vesktop", "Minecraft*" } }, properties = { border_width = 0 } } @@ -580,6 +638,16 @@ awful.rules.rules = { -- properties = { screen = 1, tag = "2" } }, } -- }}} +if screen[2] then + screen[2]:fake_resize(1986,33,1792,1015) + table.insert(awful.rules.rules, + { rule_any = { + class = { "Mumble", "Gajim", "vesktop" } + }, + properties = { floating = true, screen = 2 } + } +) +end -- {{{ Signals -- Signal function to execute when a new client appears. diff --git a/.config/dwm/autostart.sh b/.config/dwm/autostart.sh index d97e07e..ee62b06 100755 --- a/.config/dwm/autostart.sh +++ b/.config/dwm/autostart.sh @@ -1,9 +1,9 @@ #!/bin/bash extra=0 -if [ "$(cat /etc/hostname)" == "iceynethp1" ]; then +if [ "$(cat /etc/hostname)" == "Kasino" ]; then extra=1 fi -if [ "$(cat /etc/hostname)" == "iceyartixmain" ]; then +if [ "$(cat /etc/hostname)" == "Witchen" ]; then extra=1 fi @@ -19,11 +19,15 @@ xcompmgr & if [ $extra == 1 ]; then if [ -z $(pgrep -f stbar.sh) ]; then - ~/stuff/scripts/system/stbar/stbar.sh & + # ~/stuff/scripts/system/stbar/stbar.sh & + echo hall fi - nohup pipewire & - nohup wireplumber & - nohup pipewire-pulse & + sleep 0.5s + pipewire & + if [ -z $(pgrep wireplumber) ]; then + wireplumber & + fi + pipewire-pulse & fi if [ -z $(pgrep -f newsboat-fetch.sh) ]; then ~/.config/dwm/newsboat-fetch.sh & @@ -31,5 +35,5 @@ fi if [ -z $(pgrep wezterm) ]; then sleep 2 - wezterm -e ~/stuff/scripts/system/task.sh + wezterm -e ~/stuff/scripts/system/task.sh & fi diff --git a/.config/gtk-3.0/settings.ini b/.config/gtk-3.0/settings.ini deleted file mode 100644 index 039e625..0000000 --- a/.config/gtk-3.0/settings.ini +++ /dev/null @@ -1,3 +0,0 @@ -[Settings] -gtk-theme-name = Breeze-dark-gtk - diff --git a/.config/lf/lfrc b/.config/lf/lfrc old mode 100644 new mode 100755 index c12b78d..785fb26 --- a/.config/lf/lfrc +++ b/.config/lf/lfrc @@ -112,7 +112,7 @@ cmd trash ${{ while [ "$files" ]; do file=${files%%;*} - mv "$(basename "$file")" ~/Trash + mv "$(basename "$file")" ~/.trash if [ "$files" = "$file" ]; then files='' else @@ -126,15 +126,20 @@ cmd vim ${{ }} cmd Sxiv ${{ - sxiv $f & disown + nohup sxiv $f > /dev/null 2> /dev/null < /dev/null & disown }} cmd clipf ${{ printf "$f" | xclip -selection clipboard }} +cmd filebrowser ${{ + nohup pcmanfm $f > /dev/null 2> /dev/null < /dev/null & disown +}} + map DD trash map DP delete map V vim map S Sxiv map C clipf +map P filebrowser diff --git a/.config/nvim/.luarc.json b/.config/nvim/.luarc.json old mode 100644 new mode 100755 index 154c5b3..05deadc --- a/.config/nvim/.luarc.json +++ b/.config/nvim/.luarc.json @@ -4,7 +4,8 @@ "lua/?.lua", "lua/?/init.lua" ], - "diagnostics.globals": ["vim"], + "diagnostics.globals": ["vim", + "endclose_tag_on_exit"], "workspace.checkThirdParty": false, "workspace.library": [ "$VIMRUNTIME", diff --git a/.config/nvim/after/plugin/cloak.lua b/.config/nvim/after/plugin/cloak.lua new file mode 100644 index 0000000..ec68fe5 --- /dev/null +++ b/.config/nvim/after/plugin/cloak.lua @@ -0,0 +1,31 @@ +require('yourmom/cloak').setup({ + enabled = true, + cloak_character = '*', + -- The applied highlight group (colors) on the cloaking, see `:h highlight`. + highlight_group = 'Comment', + -- Applies the length of the replacement characters for all matched + -- patterns, defaults to the length of the matched pattern. + cloak_length = nil, -- Provide a number if you want to hide the true length of the value. + -- Whether it should try every pattern to find the best fit or stop after the first. + try_all_patterns = true, + -- Set to true to cloak Telescope preview buffers. (Required feature not in 0.1.x) + cloak_telescope = true, + -- Re-enable cloak when a matched buffer leaves the window. + cloak_on_leave = false, + patterns = { + { + -- Match any file starting with '.env'. + -- This can be a table to match multiple file patterns. + file_pattern = '.env*', + -- Match an equals sign and any character after it. + -- This can also be a table of patterns to cloak, + -- example: cloak_pattern = { ':.+', '-.+' } for yaml files. + cloak_pattern = '=.+', + -- A function, table or string to generate the replacement. + -- The actual replacement will contain the 'cloak_character' + -- where it doesn't cover the original text. + -- If left empty the legacy behavior of keeping the first character is retained. + replace = nil, + } + }, +}) diff --git a/.config/nvim/after/plugin/colorizer.lua b/.config/nvim/after/plugin/colorizer.lua new file mode 100644 index 0000000..4a4590b --- /dev/null +++ b/.config/nvim/after/plugin/colorizer.lua @@ -0,0 +1 @@ +require("colorizer").setup() diff --git a/.config/nvim/after/plugin/hardtime.lua b/.config/nvim/after/plugin/hardtime.lua new file mode 100644 index 0000000..f5ef021 --- /dev/null +++ b/.config/nvim/after/plugin/hardtime.lua @@ -0,0 +1 @@ +require("hardtime").setup() diff --git a/.config/nvim/after/plugin/harpoon.lua b/.config/nvim/after/plugin/harpoon.lua old mode 100644 new mode 100755 index c3facc9..d4d3242 --- a/.config/nvim/after/plugin/harpoon.lua +++ b/.config/nvim/after/plugin/harpoon.lua @@ -5,7 +5,7 @@ vim.keymap.set("n","a", mark.add_file) vim.keymap.set("n","", ui.toggle_quick_menu) -vim.keymap.set("n","", function() ui.nav_file(1) end) +vim.keymap.set("n","", function() ui.nav_file(1) end) vim.keymap.set("n","", function() ui.nav_file(2) end) vim.keymap.set("n","", function() ui.nav_file(3) end) vim.keymap.set("n","", function() ui.nav_file(4) end) diff --git a/.config/nvim/after/plugin/indent-blankline.lua b/.config/nvim/after/plugin/indent-blankline.lua new file mode 100644 index 0000000..b0cb322 --- /dev/null +++ b/.config/nvim/after/plugin/indent-blankline.lua @@ -0,0 +1,30 @@ +local highlight = { + "RainbowRed", +} + +local hooks = require "ibl.hooks" +-- create the highlight groups in the highlight setup hook, so they are reset +-- every time the colorscheme changes +hooks.register(hooks.type.HIGHLIGHT_SETUP, function() + vim.api.nvim_set_hl(0, "RainbowRed", { fg = "#702ec0" }) +end) + +require('ibl').setup { + indent = { + char = '|', + highlight = highlight, + }, + scope = { + show_start = false, + show_end = false, + show_exact_scope = false, + }, + exclude = { + filetypes = { + 'help', + 'packer', + 'undotree', + 'diff', + }, + }, +} diff --git a/.config/nvim/after/plugin/lsp.lua b/.config/nvim/after/plugin/lsp.lua old mode 100644 new mode 100755 index d37197c..0bc44c4 --- a/.config/nvim/after/plugin/lsp.lua +++ b/.config/nvim/after/plugin/lsp.lua @@ -1,3 +1,10 @@ +vim.api.nvim_create_autocmd("FileType", { + pattern = "src", + callback = function() + print("LSP should now be active for src files") + end, +}) + local lsp = require("lsp-zero") lsp.preset("recommended") @@ -32,14 +39,33 @@ lsp.on_attach(function(client, bufnr) vim.keymap.set("i", "", function() vim.lsp.buf.signature_help() end, opts) end) + +local lsp_configurations = require('lspconfig.configs') + +if not lsp_configurations.greybel then + lsp_configurations.greybel = { + default_config = { + cmd = { "/bin/greybel-languageserver", "--stdio" }, + filetypes = { "greyscript" }, + root_dir = require('lspconfig.util').root_pattern(".git", vim.fn.getcwd()), + settings = {}, + } + } +end + -- to learn how to use mason.nvim with lsp-zero -- read this: https://github.com/VonHeikemen/lsp-zero.nvim/blob/v3.x/doc/md/guides/integrate-with-mason-nvim.md -require('mason').setup({}) +require('mason').setup({ + registries = { + "github:mason-org/mason-registry", + }, +}) require('mason-lspconfig').setup({ - ensure_installed = {}, + ensure_installed = { }, handlers = { lsp.default_setup, }, }) +require('lspconfig').greybel.setup({}) lsp.setup() diff --git a/.config/nvim/after/plugin/lualine.lua b/.config/nvim/after/plugin/lualine.lua new file mode 100644 index 0000000..4abfa26 --- /dev/null +++ b/.config/nvim/after/plugin/lualine.lua @@ -0,0 +1,46 @@ +require('lualine').setup() + +local custom_gruvbox = require'lualine.themes.base16' + +-- Change the background of lualine_c section for normal mode +custom_gruvbox.normal.c.bg = '#222222' + +local hide_in_width = function() + return vim.fn.winwidth(0) > 80 +end + +local diagnostics = { + 'diagnostics', + sources = { 'nvim_diagnostic' }, + sections = { 'error' , 'warn' }, + symbols = { error = ' ', warn = ' ', info = ' ', hint = ' ' }, + update_in_insert = false, + allways_visible = false, + cond = hide_in_width, +} + +require('lualine').setup { + options = { + theme = custom_gruvbox, + icons_enabled = true, + disabled_filetypes = {'undotree', 'diff'}, + }, + sections = { + lualine_a = {{ + 'mode', + fmt = function(str) + return ' ' .. str + end, + }}, + lualine_b = {'branch', 'diff', diagnostics}, + lualine_c = {{ + 'filename', + file_status = true, + path = 0, + }}, + --lualine_x = {'encoding', 'fileformat', 'filetype'}, + lualine_x = {{'encoding', cond=hide_in_width}, {'filetype',cond=hide_in_width}}, + lualine_y = {'progress'}, + lualine_z = {'location'} + } +} diff --git a/.config/nvim/after/plugin/notify.lua b/.config/nvim/after/plugin/notify.lua new file mode 100644 index 0000000..19c7362 --- /dev/null +++ b/.config/nvim/after/plugin/notify.lua @@ -0,0 +1,4 @@ +vim.notify = require("notify") +require("notify").setup({ + background_colour="#000000" +}) diff --git a/.config/nvim/after/plugin/telescope.lua b/.config/nvim/after/plugin/telescope.lua old mode 100644 new mode 100755 index 2eae882..a709d9b --- a/.config/nvim/after/plugin/telescope.lua +++ b/.config/nvim/after/plugin/telescope.lua @@ -1,5 +1,8 @@ local builtin = require('telescope.builtin') vim.keymap.set('n', 'pf', builtin.find_files, {}) +vim.keymap.set('n', 'pg', builtin.live_grep, {}) +vim.keymap.set('n', 'pb', builtin.buffers, {}) +vim.keymap.set('n', 'ph', builtin.help_tags, {}) vim.keymap.set('n', 'ps', function() builtin.grep_string({ search = vim.fn.input("Grep > ") }); end) diff --git a/.config/nvim/custom-lsp/.luarc.json b/.config/nvim/custom-lsp/.luarc.json old mode 100644 new mode 100755 diff --git a/.config/nvim/init.lua b/.config/nvim/init.lua old mode 100644 new mode 100755 diff --git a/.config/nvim/lua/yourmom/cloak.lua b/.config/nvim/lua/yourmom/cloak.lua new file mode 100644 index 0000000..5a13953 --- /dev/null +++ b/.config/nvim/lua/yourmom/cloak.lua @@ -0,0 +1,293 @@ +local group = vim.api.nvim_create_augroup('cloak', {}) +local namespace = vim.api.nvim_create_namespace('cloak') + +-- In case cmp is lazy loaded, we check :CmpStatus instead of a pcall to require +-- so we maintain the lazy load. +local has_cmp = function() + return vim.fn.exists(':CmpStatus') > 0 +end + +local M = {} + +M.opts = { + enabled = true, + cloak_character = '*', + cloak_length = nil, + highlight_group = 'Comment', + try_all_patterns = true, + patterns = { { file_pattern = '.env*', cloak_pattern = '=.+' } }, + cloak_telescope = true, + uncloaked_line_num = nil, + cloak_on_leave = false, +} + +M.setup = function(opts) + M.opts = vim.tbl_deep_extend('force', M.opts, opts or {}) + vim.b.cloak_enabled = M.opts.enabled + + for _, pattern in ipairs(M.opts.patterns) do + if type(pattern.cloak_pattern) == 'string' then + pattern.cloak_pattern = { { pattern.cloak_pattern, replace = pattern.replace } } + else + for i, inner_pattern in ipairs(pattern.cloak_pattern) do + pattern.cloak_pattern[i] = + type(inner_pattern) == 'string' + and { inner_pattern, replace = pattern.cloak_pattern.replace or pattern.replace } + or inner_pattern + end + end + + vim.api.nvim_create_autocmd( + { 'BufEnter', 'TextChanged', 'TextChangedI', 'TextChangedP' }, { + pattern = pattern.file_pattern, + callback = function() + if M.opts.enabled then + M.cloak(pattern) + else + M.uncloak() + end + end, + group = group, + } + ) + + if M.opts.cloak_on_leave then + vim.api.nvim_create_autocmd( + 'BufWinLeave', { + pattern = pattern.file_pattern, + callback = function() + M.enable() + end, + group = group, + } + ) + end + end + + if M.opts.cloak_telescope then + vim.api.nvim_create_autocmd( + 'User', { + pattern = 'TelescopePreviewerLoaded', + callback = function(args) + -- Feature not in 0.1.x + if not M.opts.enabled or args.data == nil then + return + end + + local buffer = require('telescope.state').get_existing_prompt_bufnrs()[1] + local picker = require('telescope.actions.state').get_current_picker( + buffer + ) + + -- If our state variable is set, meaning we have just refreshed after cloaking a buffer, + -- set the selection to that row again. + if picker.__cloak_selection then + picker:set_selection(picker.__cloak_selection) + picker.__cloak_selection = nil + vim.schedule( + function() + picker:refresh_previewer() + end + ) + return + end + + local is_cloaked, _ = pcall( + vim.api.nvim_buf_get_var, args.buf, 'cloaked' + ) + + -- Check the buffer agains all configured patterns, + -- if matched, set a variable on the picker to know where we left off, + -- set a buffer variable to know we already cloaked it later, and refresh. + -- a refresh will result in the cloak being visible, and will make this + -- aucmd be called again right away with the first result, which we will then + -- set to what we have stored in the code above. + if M.recloak_file(args.data.bufname) then + vim.api.nvim_buf_set_var(args.buf, 'cloaked', true) + if is_cloaked then + return + end + + local row = picker:get_selection_row() + picker.__cloak_selection = row + picker:refresh() + return + end + end, + group = group, + } + ) + end + -- Handle cloaking the Telescope preview. + + vim.api.nvim_create_user_command('CloakEnable', M.enable, {}) + vim.api.nvim_create_user_command('CloakDisable', M.disable, {}) + vim.api.nvim_create_user_command('CloakToggle', M.toggle, {}) + vim.api.nvim_create_user_command('CloakPreviewLine', M.uncloak_line, {}) +end + +M.uncloak = function() + vim.api.nvim_buf_clear_namespace(0, namespace, 0, -1) +end + +M.uncloak_line = function() + if not M.opts.enabled then + return + end + + local buf = vim.api.nvim_win_get_buf(0) + local cursor = vim.api.nvim_win_get_cursor(0) + M.opts.uncloaked_line_num = cursor[1] + + vim.api.nvim_create_autocmd( + { 'CursorMoved', 'CursorMovedI', 'BufLeave' }, { + buffer = buf, + callback = function(args) + if not M.opts.enabled then + M.opts.uncloaked_line_num = nil + return true + end + + if args.event == 'BufLeave' then + M.opts.uncloaked_line_num = nil + M.recloak_file(vim.api.nvim_buf_get_name(buf)) + return true + end + + local ncursor = vim.api.nvim_win_get_cursor(0) + if ncursor[1] == M.opts.uncloaked_line_num then + return + end + + M.opts.uncloaked_line_num = nil + M.recloak_file(vim.api.nvim_buf_get_name(buf)) + + -- deletes the auto command + return true + end, + group = group, + } + ) + + M.recloak_file(vim.api.nvim_buf_get_name(buf)) +end + +M.cloak = function(pattern) + M.uncloak() + + if has_cmp() then + require('cmp').setup.buffer({ enabled = false }) + end + + local function determine_replacement(length, prefix) + local cloak_str = prefix + .. M.opts.cloak_character:rep( + tonumber(M.opts.cloak_length) + or length - vim.fn.strchars(prefix)) + local remaining_length = length - vim.fn.strchars(cloak_str) + -- Fixme: + -- - When cloak_length is longer than the text underlying it, + -- it results in overlaying of extra text + -- => Possiblie solutions would could be implemented using inline virtual text + -- (https://github.com/neovim/neovim/pull/20130) + return cloak_str -- :sub(1, math.min(remaining_length - 1, -1)) + .. (' '):rep(remaining_length) + end + + local found_pattern = false + local lines = vim.api.nvim_buf_get_lines(0, 0, -1, false) + for i, line in ipairs(lines) do + -- Find all matches for the current line + local searchStartIndex = 1 + while searchStartIndex < #line and + -- if the line is uncloaked skip + i ~= M.opts.uncloaked_line_num do + + -- Find best pattern based on starting position and tiebreak with length + local first, last, matching_pattern, has_groups = -1, 1, nil, false + for _, inner_pattern in ipairs(pattern.cloak_pattern) do + local current_first, current_last, capture_group = + line:find(inner_pattern[1], searchStartIndex) + if current_first ~= nil + and (first < 0 + or current_first < first + or (current_first == first and current_last > last)) then + first, last, matching_pattern, has_groups = + current_first, current_last, inner_pattern, capture_group ~= nil + if M.opts.try_all_patterns == false then break end + end + end + if first >= 0 then + found_pattern = true + local prefix = line:sub(first,first) + if has_groups and matching_pattern.replace ~= nil then + prefix = line:sub(first,last) + :gsub(matching_pattern[1], matching_pattern.replace, 1) + end + local last_of_prefix = first + vim.fn.strchars(prefix) - 1 + if prefix == line:sub(first, last_of_prefix) then + first, prefix = last_of_prefix + 1, '' + end + vim.api.nvim_buf_set_extmark( + 0, namespace, i - 1, first-1, { + hl_mode = 'combine', + virt_text = { + { + determine_replacement(last - first + 1, prefix), + M.opts.highlight_group, + }, + }, + virt_text_pos = 'overlay', + } + ) + else break end + searchStartIndex = last + end + end + if found_pattern then + vim.opt_local.wrap = false + end +end + +M.recloak_file = function(filename) + local base_name = vim.fn.fnamemodify(filename, ':t') + for _, pattern in ipairs(M.opts.patterns) do + -- Could be a string or a table of patterns. + local file_patterns = pattern.file_pattern + if type(file_patterns) == 'string' then + file_patterns = { file_patterns } + end + + for _, file_pattern in ipairs(file_patterns) do + if base_name ~= nil and + vim.fn.match(base_name, vim.fn.glob2regpat(file_pattern)) ~= -1 then + M.cloak(pattern) + return true + end + end + end + + return false +end + +M.disable = function() + M.uncloak() + M.opts.enabled = false + vim.b.cloak_enabled = false +end + +M.enable = function() + M.opts.enabled = true + vim.b.cloak_enabled = true + vim.cmd('doautocmd TextChanged') +end + +M.toggle = function() + if M.opts.enabled then + M.disable() + else + M.enable() + end +end + +return M diff --git a/.config/nvim/lua/yourmom/init.lua b/.config/nvim/lua/yourmom/init.lua index 393115e..c9642cf 100755 --- a/.config/nvim/lua/yourmom/init.lua +++ b/.config/nvim/lua/yourmom/init.lua @@ -12,11 +12,13 @@ vim.opt.expandtab = true vim.opt.smartindent=true -vim.opt.wrap = false +vim.opt.wrap = true vim.opt.hlsearch = false vim.opt.incsearch = true +vim.o.ignorecase = true + vim.opt.updatetime = 50 --vim.opt.colorcolumn = "80" --vim.cmd('colorscheme vim') @@ -37,3 +39,10 @@ vim.cmd('hi StatusLine cterm=reverse') --allows highlighint in comments --vim.api.nvim_set_hl(0, '@lsp.type.comment.cpp', {}) + + +vim.filetype.add({ + extension = { + src = "greyscript" + } +}) diff --git a/.config/nvim/lua/yourmom/packer.lua b/.config/nvim/lua/yourmom/packer.lua index 009a1d0..6428021 100755 --- a/.config/nvim/lua/yourmom/packer.lua +++ b/.config/nvim/lua/yourmom/packer.lua @@ -10,6 +10,10 @@ return require('packer').startup(function(use) use 'ThePrimeagen/vim-be-good' use 'ThePrimeagen/harpoon' + use 'm4xshen/hardtime.nvim' + + use 'rcarriga/nvim-notify' + use { "rose-pine/neovim", as = "rose-pine" } use { @@ -20,6 +24,17 @@ return require('packer').startup(function(use) use("mbbill/undotree") + use "lukas-reineke/indent-blankline.nvim" + + use({ "NStefan002/screenkey.nvim", tag = "*" }) + + use("catgoose/nvim-colorizer.lua") + + use { + 'nvim-lualine/lualine.nvim', + --requires = { 'nvim-tree/nvim-web-devicons', opt = true } + } + --[[ use('nvim-treesitter/nvim-treesitter', {run = ':TSUpdate', config = function() @@ -50,6 +65,4 @@ return require('packer').startup(function(use) {'L3MON4D3/LuaSnip'}, } } - - end) diff --git a/.config/nvim/lua/yourmom/remap.lua b/.config/nvim/lua/yourmom/remap.lua index aa3a488..dfa1b95 100755 --- a/.config/nvim/lua/yourmom/remap.lua +++ b/.config/nvim/lua/yourmom/remap.lua @@ -1,13 +1,6 @@ vim.g.mapleader=" " -vim.keymap.set("n", "pv", vim.cmd.Ex) - - ---[[ -vim.keymap.set("n","","h") -vim.keymap.set("n","","j") -vim.keymap.set("n","","l") -vim.keymap.set("n","","k") -]]-- +vim.g.maplocalleader=" " +vim.keymap.set("n", "pv", vim.cmd.Ex) --[[vim.cmd[[ @@ -25,15 +18,52 @@ vim.keymap.set("n", "J", "mzJ`z") --keeps cursur in middle with up down vim.keymap.set("n", "", "zz") vim.keymap.set("n", "", "zz") +vim.keymap.set("n", "n", "nzzzv") +vim.keymap.set("n", "N", "Nzzzv") --sets leader y to put in sys clipboard vim.keymap.set("n", "y", "\"+y") vim.keymap.set("v", "y", "\"+y") vim.keymap.set("n", "Y", "\"+Y") +--paste but dont overwrite current register with selection +vim.keymap.set("v", "p", "\"_dP") --nnoremap S :%s//g vim.keymap.set("n", "S", [[:%s//]]) + +vim.keymap.set('n', 'to', ':tabnew') +vim.keymap.set('n', 'tx', ':tabclose') +vim.keymap.set('n', 'tn', ':tabn') +vim.keymap.set('n', 'tp', ':tabp') + +vim.keymap.set('n', 'lw', ':set wrap!') + +--stay in indent mode +vim.keymap.set('v', '<', '', '>gv', {noremap = true}) + + +--reize with arrows +vim.keymap.set('n', '', ':resize -2') +vim.keymap.set('n', '', ':resize +2') +vim.keymap.set('n', '', ':vertical resize -2') +vim.keymap.set('n', '', ':vertical resize +2') + +-- window management +vim.keymap.set('n', 'v', 'v') +vim.keymap.set('n', 'h', 's') +vim.keymap.set('n', 'se', '=') +vim.keymap.set('n', 'xs', ':close') + +-- navigate splits +vim.keymap.set("n","","h") +vim.keymap.set("n","","j") +vim.keymap.set("n","","l") +vim.keymap.set("n","","k") + + + vim.keymap.set("n", "ee", "oif err != nil {}Oreturn err") --per file type log quick binds @@ -46,10 +76,40 @@ elseif string.find(filename,".*%.lua$") then cc_command="oterm.print()V=$i" elseif string.find(filename,".*%.c$") then cc_command="oprintf(\"debug: %i\",);V=$hi" +elseif string.find(filename,".*%.rs$") then + cc_command="oprintln!(\"debug: {}\",);V=$hi" end vim.keymap.set("n", "cc", cc_command) +local auto_close=false +local function toggle_auto_close() + if auto_close==false then + vim.keymap.set("i", "{", "{}ko"); + vim.keymap.set("i", "(", "()i"); + if string.find(filename,".*%.html$") then + vim.keymap.set("i", "<", "<"); + vim.keymap.set("i", ">", ">TahpFi"); + vim.keymap.set("i", ">", ">"); + end + vim.keymap.set("i", "[", "[]i"); + vim.keymap.set("i", "\"", "\"\"i"); + vim.keymap.set("i", "'", "''i"); + auto_close=true + else + vim.keymap.set("i", "{", "{"); + vim.keymap.set("i", "(", "("); + vim.keymap.set("i", "<", "<"); + vim.keymap.set("i", ">", ">"); + vim.keymap.set("i", "[", "["); + auto_close=false + end +end +toggle_auto_close() + +vim.keymap.set("n", "k", toggle_auto_close) --[[ vim.keymap("i","", function() diff --git a/.config/picom.conf b/.config/picom.conf old mode 100644 new mode 100755 index 5c2cb09..31ecf09 --- a/.config/picom.conf +++ b/.config/picom.conf @@ -78,11 +78,11 @@ fading = true; # Opacity change between steps while fading in. (0.01 - 1.0, defaults to 0.028) # fade-in-step = 0.028 -fade-in-step = 0.03; +fade-in-step = 0.6; # Opacity change between steps while fading out. (0.01 - 1.0, defaults to 0.03) # fade-out-step = 0.03 -fade-out-step = 0.03; +fade-out-step = 0.06; # The time between steps in fade step, in milliseconds. (> 0, defaults to 10) # fade-delta = 10 @@ -104,7 +104,7 @@ fade-out-step = 0.03; # Opacity of inactive windows. (0.1 - 1.0, defaults to 1.0) # inactive-opacity = 1 -inactive-opacity = 0.8; +inactive-opacity = 1; # Opacity of window titlebars and borders. (0.1 - 1.0, disabled by default) # frame-opacity = 1.0 @@ -138,12 +138,13 @@ focus-exclude = [ "class_g = 'Cairo-clock'" ]; # opacity-rule = [ - "90:name *= 'Firefox'", - "95:name *= 'Discord'", + #"95:name *= 'Firefox'", + #"80:name *= 'Discord'", "90:name *= 'OBS'", "90:name *= 'urxvt'", - "80:class_g = 'steam'", + #"80:class_g = 'steam'", "70:class_g *= 'screen-recorder-gtk'", + "80:class_g *= 'simplex'", ]; @@ -154,7 +155,7 @@ opacity-rule = [ # Sets the radius of rounded window corners. When > 0, the compositor will # round the corners of windows. Does not interact well with # `transparent-clipping`. -corner-radius = 15 +corner-radius = 0 # Exclude conditions for rounded corners. rounded-corners-exclude = [ @@ -172,12 +173,12 @@ rounded-corners-exclude = [ # Parameters for background blurring, see the *BLUR* section for more information. -# blur-method = -# blur-size = 12 -# -# blur-deviation = false -# -# blur-strength = 5 +blur-method = "box" +blur-size = 5 + +blur-deviation = false + +blur-strength = 3 # Blur background of semi-transparent / ARGB windows. # Bad in performance, with driver-dependent behavior. @@ -227,7 +228,7 @@ blur-background-exclude = [ # `xrender` is the default one. # # backend = "glx" -backend = "xrender"; +backend = "glx"; # Use higher precision during rendering, and apply dither when presenting the # rendered screen. Reduces banding artifacts, but might cause performance @@ -236,7 +237,7 @@ dithered-present = false; # Enable/disable VSync. # vsync = false -vsync = false; +vsync = true; # Try to detect WM windows (a non-override-redirect window with no # child that has 'WM_STATE') and mark them as active. diff --git a/.config/rofi/config.rasi b/.config/rofi/config.rasi index 5191111..36ed3a8 100644 --- a/.config/rofi/config.rasi +++ b/.config/rofi/config.rasi @@ -1,5 +1,14 @@ @theme "Arc-Dark" +//background: #30303050; *{ - background: #30303050; + background: #201f5060; + alternate-normal-background: #4030B060; + foreground: #F0C3F0; + border-color: #5030D0; + selected-normal-background: #20202060; +} + +window, mainbox{ + //border-radius: 20px; } diff --git a/.config/screenkey.json b/.config/screenkey.json old mode 100644 new mode 100755 index 4e01f42..6e886a6 --- a/.config/screenkey.json +++ b/.config/screenkey.json @@ -20,10 +20,10 @@ "vis_shift": false, "vis_space": true, "geometry": [ - 1303, - 180, - 611, - 103 + 1191, + 152, + 720, + 81 ], "screen": 0, "start_disabled": false, diff --git a/.gtkrc-2.0 b/.gtkrc-2.0 index 92e5350..8b780c2 100644 --- a/.gtkrc-2.0 +++ b/.gtkrc-2.0 @@ -1,13 +1,17 @@ -gtk-enable-event-sounds=1 -gtk-enable-animations=1 -gtk-theme-name="Breeze-Dark" -gtk-primary-button-warps-slider=1 -gtk-toolbar-style=3 -gtk-menu-images=1 -gtk-button-images=1 -gtk-cursor-theme-size=24 -gtk-cursor-theme-name="breeze_cursors" -gtk-sound-theme-name="freedesktop" -gtk-icon-theme-name="breeze-dark" -gtk-font-name="Noto Sans, 10" +# DO NOT EDIT! This file will be overwritten by LXAppearance. +# Any customization should be done in ~/.gtkrc-2.0.mine instead. +include "/home/iceyrazor/.gtkrc-2.0.mine" +gtk-theme-name="Breeze-dark-gtk" +gtk-icon-theme-name="Adwaita" +gtk-font-name="Cantarell 11" +gtk-cursor-theme-size=0 +gtk-toolbar-style=GTK_TOOLBAR_BOTH +gtk-toolbar-icon-size=GTK_ICON_SIZE_LARGE_TOOLBAR +gtk-button-images=1 +gtk-menu-images=1 +gtk-enable-event-sounds=1 +gtk-enable-input-feedback-sounds=1 +gtk-xft-antialias=1 +gtk-xft-hinting=1 +gtk-xft-hintstyle="hintfull" diff --git a/.p10k.zsh b/.p10k.zsh new file mode 100644 index 0000000..0641dde --- /dev/null +++ b/.p10k.zsh @@ -0,0 +1,1739 @@ +# Generated by Powerlevel10k configuration wizard on 2025-01-08 at 03:10 CST. +# Based on romkatv/powerlevel10k/config/p10k-classic.zsh, checksum 13396. +# Wizard options: nerdfont-v3 + powerline, small icons, classic, unicode, dark, +# angled separators, sharp heads, slanted tails, 1 line, sparse, few icons, concise, +# transient_prompt, instant_prompt=verbose. +# Type `p10k configure` to generate another config. +# +# Config for Powerlevel10k with classic powerline prompt style. Type `p10k configure` to generate +# your own config based on it. +# +# Tip: Looking for a nice color? Here's a one-liner to print colormap. +# +# for i in {0..255}; do print -Pn "%K{$i} %k%F{$i}${(l:3::0:)i}%f " ${${(M)$((i%6)):#3}:+$'\n'}; done + +# Temporarily change options. +'builtin' 'local' '-a' 'p10k_config_opts' +[[ ! -o 'aliases' ]] || p10k_config_opts+=('aliases') +[[ ! -o 'sh_glob' ]] || p10k_config_opts+=('sh_glob') +[[ ! -o 'no_brace_expand' ]] || p10k_config_opts+=('no_brace_expand') +'builtin' 'setopt' 'no_aliases' 'no_sh_glob' 'brace_expand' + +() { + emulate -L zsh -o extended_glob + + # Unset all configuration options. This allows you to apply configuration changes without + # restarting zsh. Edit ~/.p10k.zsh and type `source ~/.p10k.zsh`. + unset -m '(POWERLEVEL9K_*|DEFAULT_USER)~POWERLEVEL9K_GITSTATUS_DIR' + + # Zsh >= 5.1 is required. + [[ $ZSH_VERSION == (5.<1->*|<6->.*) ]] || return + + # The list of segments shown on the left. Fill it with the most important segments. + typeset -g POWERLEVEL9K_LEFT_PROMPT_ELEMENTS=( + os_icon # os identifier + dir # current directory + vcs # git status + #prompt_char # prompt symbol + ) + + # The list of segments shown on the right. Fill it with less important segments. + # Right prompt on the last prompt line (where you are typing your commands) gets + # automatically hidden when the input line reaches it. Right prompt above the + # last prompt line gets hidden if it would overlap with left prompt. + typeset -g POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS=( + status # exit code of the last command + command_execution_time # duration of the last command + background_jobs # presence of background jobs + direnv # direnv status (https://direnv.net/) + asdf # asdf version manager (https://github.com/asdf-vm/asdf) + virtualenv # python virtual environment (https://docs.python.org/3/library/venv.html) + anaconda # conda environment (https://conda.io/) + pyenv # python environment (https://github.com/pyenv/pyenv) + goenv # go environment (https://github.com/syndbg/goenv) + nodenv # node.js version from nodenv (https://github.com/nodenv/nodenv) + nvm # node.js version from nvm (https://github.com/nvm-sh/nvm) + nodeenv # node.js environment (https://github.com/ekalinin/nodeenv) + # node_version # node.js version + # go_version # go version (https://golang.org) + # rust_version # rustc version (https://www.rust-lang.org) + # dotnet_version # .NET version (https://dotnet.microsoft.com) + # php_version # php version (https://www.php.net/) + # laravel_version # laravel php framework version (https://laravel.com/) + # java_version # java version (https://www.java.com/) + # package # name@version from package.json (https://docs.npmjs.com/files/package.json) + rbenv # ruby version from rbenv (https://github.com/rbenv/rbenv) + rvm # ruby version from rvm (https://rvm.io) + fvm # flutter version management (https://github.com/leoafarias/fvm) + luaenv # lua version from luaenv (https://github.com/cehoffman/luaenv) + jenv # java version from jenv (https://github.com/jenv/jenv) + plenv # perl version from plenv (https://github.com/tokuhirom/plenv) + perlbrew # perl version from perlbrew (https://github.com/gugod/App-perlbrew) + phpenv # php version from phpenv (https://github.com/phpenv/phpenv) + scalaenv # scala version from scalaenv (https://github.com/scalaenv/scalaenv) + haskell_stack # haskell version from stack (https://haskellstack.org/) + kubecontext # current kubernetes context (https://kubernetes.io/) + terraform # terraform workspace (https://www.terraform.io) + # terraform_version # terraform version (https://www.terraform.io) + aws # aws profile (https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-profiles.html) + aws_eb_env # aws elastic beanstalk environment (https://aws.amazon.com/elasticbeanstalk/) + azure # azure account name (https://docs.microsoft.com/en-us/cli/azure) + gcloud # google cloud cli account and project (https://cloud.google.com/) + google_app_cred # google application credentials (https://cloud.google.com/docs/authentication/production) + toolbox # toolbox name (https://github.com/containers/toolbox) + context # user@hostname + nordvpn # nordvpn connection status, linux only (https://nordvpn.com/) + ranger # ranger shell (https://github.com/ranger/ranger) + yazi # yazi shell (https://github.com/sxyazi/yazi) + nnn # nnn shell (https://github.com/jarun/nnn) + lf # lf shell (https://github.com/gokcehan/lf) + xplr # xplr shell (https://github.com/sayanarijit/xplr) + vim_shell # vim shell indicator (:sh) + midnight_commander # midnight commander shell (https://midnight-commander.org/) + nix_shell # nix shell (https://nixos.org/nixos/nix-pills/developing-with-nix-shell.html) + chezmoi_shell # chezmoi shell (https://www.chezmoi.io/) + vi_mode # vi mode (you don't need this if you've enabled prompt_char) + # vpn_ip # virtual private network indicator + # load # CPU load + # disk_usage # disk usage + # ram # free RAM + # swap # used swap + todo # todo items (https://github.com/todotxt/todo.txt-cli) + timewarrior # timewarrior tracking status (https://timewarrior.net/) + taskwarrior # taskwarrior task count (https://taskwarrior.org/) + per_directory_history # Oh My Zsh per-directory-history local/global indicator + # cpu_arch # CPU architecture + # time # current time + # ip # ip address and bandwidth usage for a specified network interface + # public_ip # public IP address + # proxy # system-wide http/https/ftp proxy + # battery # internal battery + # wifi # wifi speed + # example # example user-defined segment (see prompt_example function below) + ) + + # Defines character set used by powerlevel10k. It's best to let `p10k configure` set it for you. + typeset -g POWERLEVEL9K_MODE=nerdfont-v3 + # When set to `moderate`, some icons will have an extra space after them. This is meant to avoid + # icon overlap when using non-monospace fonts. When set to `none`, spaces are not added. + typeset -g POWERLEVEL9K_ICON_PADDING=none + + # When set to true, icons appear before content on both sides of the prompt. When set + # to false, icons go after content. If empty or not set, icons go before content in the left + # prompt and after content in the right prompt. + # + # You can also override it for a specific segment: + # + # POWERLEVEL9K_STATUS_ICON_BEFORE_CONTENT=false + # + # Or for a specific segment in specific state: + # + # POWERLEVEL9K_DIR_NOT_WRITABLE_ICON_BEFORE_CONTENT=false + typeset -g POWERLEVEL9K_ICON_BEFORE_CONTENT= + + # Add an empty line before each prompt. + typeset -g POWERLEVEL9K_PROMPT_ADD_NEWLINE=true + + # Connect left prompt lines with these symbols. You'll probably want to use the same color + # as POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_FOREGROUND below. + typeset -g POWERLEVEL9K_MULTILINE_FIRST_PROMPT_PREFIX='%240F╭─' + typeset -g POWERLEVEL9K_MULTILINE_NEWLINE_PROMPT_PREFIX='%240F├─' + typeset -g POWERLEVEL9K_MULTILINE_LAST_PROMPT_PREFIX='%240F╰─' + # Connect right prompt lines with these symbols. + typeset -g POWERLEVEL9K_MULTILINE_FIRST_PROMPT_SUFFIX='%240F─╮' + typeset -g POWERLEVEL9K_MULTILINE_NEWLINE_PROMPT_SUFFIX='%240F─┤' + typeset -g POWERLEVEL9K_MULTILINE_LAST_PROMPT_SUFFIX='%240F─╯' + + # Filler between left and right prompt on the first prompt line. You can set it to ' ', '·' or + # '─'. The last two make it easier to see the alignment between left and right prompt and to + # separate prompt from command output. You might want to set POWERLEVEL9K_PROMPT_ADD_NEWLINE=false + # for more compact prompt if using this option. + typeset -g POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_CHAR=' ' + typeset -g POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_BACKGROUND= + typeset -g POWERLEVEL9K_MULTILINE_NEWLINE_PROMPT_GAP_BACKGROUND= + if [[ $POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_CHAR != ' ' ]]; then + # The color of the filler. You'll probably want to match the color of POWERLEVEL9K_MULTILINE + # ornaments defined above. + typeset -g POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_FOREGROUND=240 + # Start filler from the edge of the screen if there are no left segments on the first line. + typeset -g POWERLEVEL9K_EMPTY_LINE_LEFT_PROMPT_FIRST_SEGMENT_END_SYMBOL='%{%}' + # End filler on the edge of the screen if there are no right segments on the first line. + typeset -g POWERLEVEL9K_EMPTY_LINE_RIGHT_PROMPT_FIRST_SEGMENT_START_SYMBOL='%{%}' + fi + + # Default background color. + typeset -g POWERLEVEL9K_BACKGROUND=236 + + # Separator between same-color segments on the left. + typeset -g POWERLEVEL9K_LEFT_SUBSEGMENT_SEPARATOR='%244F\uE0B1' + # Separator between same-color segments on the right. + typeset -g POWERLEVEL9K_RIGHT_SUBSEGMENT_SEPARATOR='%244F\uE0B3' + # Separator between different-color segments on the left. + typeset -g POWERLEVEL9K_LEFT_SEGMENT_SEPARATOR='\uE0B0' + # Separator between different-color segments on the right. + typeset -g POWERLEVEL9K_RIGHT_SEGMENT_SEPARATOR='\uE0B2' + # To remove a separator between two segments, add "_joined" to the second segment name. + # For example: POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS=(os_icon context_joined) + + # The right end of left prompt. + typeset -g POWERLEVEL9K_LEFT_PROMPT_LAST_SEGMENT_END_SYMBOL='\uE0B0' + # The left end of right prompt. + typeset -g POWERLEVEL9K_RIGHT_PROMPT_FIRST_SEGMENT_START_SYMBOL='\uE0B2' + # The left end of left prompt. + typeset -g POWERLEVEL9K_LEFT_PROMPT_FIRST_SEGMENT_START_SYMBOL='\uE0BA' + # The right end of right prompt. + typeset -g POWERLEVEL9K_RIGHT_PROMPT_LAST_SEGMENT_END_SYMBOL='\uE0BC' + # Left prompt terminator for lines without any segments. + typeset -g POWERLEVEL9K_EMPTY_LINE_LEFT_PROMPT_LAST_SEGMENT_END_SYMBOL= + + #################################[ os_icon: os identifier ]################################## + # OS identifier color. + typeset -g POWERLEVEL9K_OS_ICON_FOREGROUND=255 + # Custom icon. + # typeset -g POWERLEVEL9K_OS_ICON_CONTENT_EXPANSION='⭐' + + ################################[ prompt_char: prompt symbol ]################################ + # Transparent background. + typeset -g POWERLEVEL9K_PROMPT_CHAR_BACKGROUND= + # Green prompt symbol if the last command succeeded. + typeset -g POWERLEVEL9K_PROMPT_CHAR_OK_{VIINS,VICMD,VIVIS,VIOWR}_FOREGROUND=76 + # Red prompt symbol if the last command failed. + typeset -g POWERLEVEL9K_PROMPT_CHAR_ERROR_{VIINS,VICMD,VIVIS,VIOWR}_FOREGROUND=196 + # Default prompt symbol. + typeset -g POWERLEVEL9K_PROMPT_CHAR_{OK,ERROR}_VIINS_CONTENT_EXPANSION='❯' + # Prompt symbol in command vi mode. + typeset -g POWERLEVEL9K_PROMPT_CHAR_{OK,ERROR}_VICMD_CONTENT_EXPANSION='❮' + # Prompt symbol in visual vi mode. + typeset -g POWERLEVEL9K_PROMPT_CHAR_{OK,ERROR}_VIVIS_CONTENT_EXPANSION='V' + # Prompt symbol in overwrite vi mode. + typeset -g POWERLEVEL9K_PROMPT_CHAR_{OK,ERROR}_VIOWR_CONTENT_EXPANSION='▶' + typeset -g POWERLEVEL9K_PROMPT_CHAR_OVERWRITE_STATE=true + # No line terminator if prompt_char is the last segment. + typeset -g POWERLEVEL9K_PROMPT_CHAR_LEFT_PROMPT_LAST_SEGMENT_END_SYMBOL= + # No line introducer if prompt_char is the first segment. + typeset -g POWERLEVEL9K_PROMPT_CHAR_LEFT_PROMPT_FIRST_SEGMENT_START_SYMBOL= + # No surrounding whitespace. + typeset -g POWERLEVEL9K_PROMPT_CHAR_LEFT_{LEFT,RIGHT}_WHITESPACE= + + ##################################[ dir: current directory ]################################## + # Default current directory color. + typeset -g POWERLEVEL9K_DIR_FOREGROUND=31 + # If directory is too long, shorten some of its segments to the shortest possible unique + # prefix. The shortened directory can be tab-completed to the original. + typeset -g POWERLEVEL9K_SHORTEN_STRATEGY=truncate_to_unique + # Replace removed segment suffixes with this symbol. + typeset -g POWERLEVEL9K_SHORTEN_DELIMITER= + # Color of the shortened directory segments. + typeset -g POWERLEVEL9K_DIR_SHORTENED_FOREGROUND=103 + # Color of the anchor directory segments. Anchor segments are never shortened. The first + # segment is always an anchor. + typeset -g POWERLEVEL9K_DIR_ANCHOR_FOREGROUND=39 + # Display anchor directory segments in bold. + typeset -g POWERLEVEL9K_DIR_ANCHOR_BOLD=true + # Don't shorten directories that contain any of these files. They are anchors. + local anchor_files=( + .bzr + .citc + .git + .hg + .node-version + .python-version + .go-version + .ruby-version + .lua-version + .java-version + .perl-version + .php-version + .tool-versions + .mise.toml + .shorten_folder_marker + .svn + .terraform + CVS + Cargo.toml + composer.json + go.mod + package.json + stack.yaml + ) + typeset -g POWERLEVEL9K_SHORTEN_FOLDER_MARKER="(${(j:|:)anchor_files})" + # If set to "first" ("last"), remove everything before the first (last) subdirectory that contains + # files matching $POWERLEVEL9K_SHORTEN_FOLDER_MARKER. For example, when the current directory is + # /foo/bar/git_repo/nested_git_repo/baz, prompt will display git_repo/nested_git_repo/baz (first) + # or nested_git_repo/baz (last). This assumes that git_repo and nested_git_repo contain markers + # and other directories don't. + # + # Optionally, "first" and "last" can be followed by ":" where is an integer. + # This moves the truncation point to the right (positive offset) or to the left (negative offset) + # relative to the marker. Plain "first" and "last" are equivalent to "first:0" and "last:0" + # respectively. + typeset -g POWERLEVEL9K_DIR_TRUNCATE_BEFORE_MARKER=false + # Don't shorten this many last directory segments. They are anchors. + typeset -g POWERLEVEL9K_SHORTEN_DIR_LENGTH=1 + # Shorten directory if it's longer than this even if there is space for it. The value can + # be either absolute (e.g., '80') or a percentage of terminal width (e.g, '50%'). If empty, + # directory will be shortened only when prompt doesn't fit or when other parameters demand it + # (see POWERLEVEL9K_DIR_MIN_COMMAND_COLUMNS and POWERLEVEL9K_DIR_MIN_COMMAND_COLUMNS_PCT below). + # If set to `0`, directory will always be shortened to its minimum length. + typeset -g POWERLEVEL9K_DIR_MAX_LENGTH=80 + # When `dir` segment is on the last prompt line, try to shorten it enough to leave at least this + # many columns for typing commands. + typeset -g POWERLEVEL9K_DIR_MIN_COMMAND_COLUMNS=40 + # When `dir` segment is on the last prompt line, try to shorten it enough to leave at least + # COLUMNS * POWERLEVEL9K_DIR_MIN_COMMAND_COLUMNS_PCT * 0.01 columns for typing commands. + typeset -g POWERLEVEL9K_DIR_MIN_COMMAND_COLUMNS_PCT=50 + # If set to true, embed a hyperlink into the directory. Useful for quickly + # opening a directory in the file manager simply by clicking the link. + # Can also be handy when the directory is shortened, as it allows you to see + # the full directory that was used in previous commands. + typeset -g POWERLEVEL9K_DIR_HYPERLINK=false + + # Enable special styling for non-writable and non-existent directories. See POWERLEVEL9K_LOCK_ICON + # and POWERLEVEL9K_DIR_CLASSES below. + typeset -g POWERLEVEL9K_DIR_SHOW_WRITABLE=v3 + + # The default icon shown next to non-writable and non-existent directories when + # POWERLEVEL9K_DIR_SHOW_WRITABLE is set to v3. + # typeset -g POWERLEVEL9K_LOCK_ICON='⭐' + + # POWERLEVEL9K_DIR_CLASSES allows you to specify custom icons and colors for different + # directories. It must be an array with 3 * N elements. Each triplet consists of: + # + # 1. A pattern against which the current directory ($PWD) is matched. Matching is done with + # extended_glob option enabled. + # 2. Directory class for the purpose of styling. + # 3. An empty string. + # + # Triplets are tried in order. The first triplet whose pattern matches $PWD wins. + # + # If POWERLEVEL9K_DIR_SHOW_WRITABLE is set to v3, non-writable and non-existent directories + # acquire class suffix _NOT_WRITABLE and NON_EXISTENT respectively. + # + # For example, given these settings: + # + # typeset -g POWERLEVEL9K_DIR_CLASSES=( + # '~/work(|/*)' WORK '' + # '~(|/*)' HOME '' + # '*' DEFAULT '') + # + # Whenever the current directory is ~/work or a subdirectory of ~/work, it gets styled with one + # of the following classes depending on its writability and existence: WORK, WORK_NOT_WRITABLE or + # WORK_NON_EXISTENT. + # + # Simply assigning classes to directories doesn't have any visible effects. It merely gives you an + # option to define custom colors and icons for different directory classes. + # + # # Styling for WORK. + # typeset -g POWERLEVEL9K_DIR_WORK_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_DIR_WORK_FOREGROUND=31 + # typeset -g POWERLEVEL9K_DIR_WORK_SHORTENED_FOREGROUND=103 + # typeset -g POWERLEVEL9K_DIR_WORK_ANCHOR_FOREGROUND=39 + # + # # Styling for WORK_NOT_WRITABLE. + # typeset -g POWERLEVEL9K_DIR_WORK_NOT_WRITABLE_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_DIR_WORK_NOT_WRITABLE_FOREGROUND=31 + # typeset -g POWERLEVEL9K_DIR_WORK_NOT_WRITABLE_SHORTENED_FOREGROUND=103 + # typeset -g POWERLEVEL9K_DIR_WORK_NOT_WRITABLE_ANCHOR_FOREGROUND=39 + # + # # Styling for WORK_NON_EXISTENT. + # typeset -g POWERLEVEL9K_DIR_WORK_NON_EXISTENT_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_DIR_WORK_NON_EXISTENT_FOREGROUND=31 + # typeset -g POWERLEVEL9K_DIR_WORK_NON_EXISTENT_SHORTENED_FOREGROUND=103 + # typeset -g POWERLEVEL9K_DIR_WORK_NON_EXISTENT_ANCHOR_FOREGROUND=39 + # + # If a styling parameter isn't explicitly defined for some class, it falls back to the classless + # parameter. For example, if POWERLEVEL9K_DIR_WORK_NOT_WRITABLE_FOREGROUND is not set, it falls + # back to POWERLEVEL9K_DIR_FOREGROUND. + # + typeset -g POWERLEVEL9K_DIR_CLASSES=() + + # Custom prefix. + # typeset -g POWERLEVEL9K_DIR_PREFIX='%246Fin ' + + #####################################[ vcs: git status ]###################################### + # Branch icon. Set this parameter to '\UE0A0 ' for the popular Powerline branch icon. + typeset -g POWERLEVEL9K_VCS_BRANCH_ICON= + + # Untracked files icon. It's really a question mark, your font isn't broken. + # Change the value of this parameter to show a different icon. + typeset -g POWERLEVEL9K_VCS_UNTRACKED_ICON='?' + + # Formatter for Git status. + # + # Example output: master wip ⇣42⇡42 *42 merge ~42 +42 !42 ?42. + # + # You can edit the function to customize how Git status looks. + # + # VCS_STATUS_* parameters are set by gitstatus plugin. See reference: + # https://github.com/romkatv/gitstatus/blob/master/gitstatus.plugin.zsh. + function my_git_formatter() { + emulate -L zsh + + if [[ -n $P9K_CONTENT ]]; then + # If P9K_CONTENT is not empty, use it. It's either "loading" or from vcs_info (not from + # gitstatus plugin). VCS_STATUS_* parameters are not available in this case. + typeset -g my_git_format=$P9K_CONTENT + return + fi + + if (( $1 )); then + # Styling for up-to-date Git status. + local meta='%246F' # grey foreground + local clean='%76F' # green foreground + local modified='%178F' # yellow foreground + local untracked='%39F' # blue foreground + local conflicted='%196F' # red foreground + else + # Styling for incomplete and stale Git status. + local meta='%244F' # grey foreground + local clean='%244F' # grey foreground + local modified='%244F' # grey foreground + local untracked='%244F' # grey foreground + local conflicted='%244F' # grey foreground + fi + + local res + + if [[ -n $VCS_STATUS_LOCAL_BRANCH ]]; then + local branch=${(V)VCS_STATUS_LOCAL_BRANCH} + # If local branch name is at most 32 characters long, show it in full. + # Otherwise show the first 12 … the last 12. + # Tip: To always show local branch name in full without truncation, delete the next line. + (( $#branch > 32 )) && branch[13,-13]="…" # <-- this line + res+="${clean}${(g::)POWERLEVEL9K_VCS_BRANCH_ICON}${branch//\%/%%}" + fi + + if [[ -n $VCS_STATUS_TAG + # Show tag only if not on a branch. + # Tip: To always show tag, delete the next line. + && -z $VCS_STATUS_LOCAL_BRANCH # <-- this line + ]]; then + local tag=${(V)VCS_STATUS_TAG} + # If tag name is at most 32 characters long, show it in full. + # Otherwise show the first 12 … the last 12. + # Tip: To always show tag name in full without truncation, delete the next line. + (( $#tag > 32 )) && tag[13,-13]="…" # <-- this line + res+="${meta}#${clean}${tag//\%/%%}" + fi + + # Display the current Git commit if there is no branch and no tag. + # Tip: To always display the current Git commit, delete the next line. + [[ -z $VCS_STATUS_LOCAL_BRANCH && -z $VCS_STATUS_TAG ]] && # <-- this line + res+="${meta}@${clean}${VCS_STATUS_COMMIT[1,8]}" + + # Show tracking branch name if it differs from local branch. + if [[ -n ${VCS_STATUS_REMOTE_BRANCH:#$VCS_STATUS_LOCAL_BRANCH} ]]; then + res+="${meta}:${clean}${(V)VCS_STATUS_REMOTE_BRANCH//\%/%%}" + fi + + # Display "wip" if the latest commit's summary contains "wip" or "WIP". + if [[ $VCS_STATUS_COMMIT_SUMMARY == (|*[^[:alnum:]])(wip|WIP)(|[^[:alnum:]]*) ]]; then + res+=" ${modified}wip" + fi + + if (( VCS_STATUS_COMMITS_AHEAD || VCS_STATUS_COMMITS_BEHIND )); then + # ⇣42 if behind the remote. + (( VCS_STATUS_COMMITS_BEHIND )) && res+=" ${clean}⇣${VCS_STATUS_COMMITS_BEHIND}" + # ⇡42 if ahead of the remote; no leading space if also behind the remote: ⇣42⇡42. + (( VCS_STATUS_COMMITS_AHEAD && !VCS_STATUS_COMMITS_BEHIND )) && res+=" " + (( VCS_STATUS_COMMITS_AHEAD )) && res+="${clean}⇡${VCS_STATUS_COMMITS_AHEAD}" + elif [[ -n $VCS_STATUS_REMOTE_BRANCH ]]; then + # Tip: Uncomment the next line to display '=' if up to date with the remote. + # res+=" ${clean}=" + fi + + # ⇠42 if behind the push remote. + (( VCS_STATUS_PUSH_COMMITS_BEHIND )) && res+=" ${clean}⇠${VCS_STATUS_PUSH_COMMITS_BEHIND}" + (( VCS_STATUS_PUSH_COMMITS_AHEAD && !VCS_STATUS_PUSH_COMMITS_BEHIND )) && res+=" " + # ⇢42 if ahead of the push remote; no leading space if also behind: ⇠42⇢42. + (( VCS_STATUS_PUSH_COMMITS_AHEAD )) && res+="${clean}⇢${VCS_STATUS_PUSH_COMMITS_AHEAD}" + # *42 if have stashes. + (( VCS_STATUS_STASHES )) && res+=" ${clean}*${VCS_STATUS_STASHES}" + # 'merge' if the repo is in an unusual state. + [[ -n $VCS_STATUS_ACTION ]] && res+=" ${conflicted}${VCS_STATUS_ACTION}" + # ~42 if have merge conflicts. + (( VCS_STATUS_NUM_CONFLICTED )) && res+=" ${conflicted}~${VCS_STATUS_NUM_CONFLICTED}" + # +42 if have staged changes. + (( VCS_STATUS_NUM_STAGED )) && res+=" ${modified}+${VCS_STATUS_NUM_STAGED}" + # !42 if have unstaged changes. + (( VCS_STATUS_NUM_UNSTAGED )) && res+=" ${modified}!${VCS_STATUS_NUM_UNSTAGED}" + # ?42 if have untracked files. It's really a question mark, your font isn't broken. + # See POWERLEVEL9K_VCS_UNTRACKED_ICON above if you want to use a different icon. + # Remove the next line if you don't want to see untracked files at all. + (( VCS_STATUS_NUM_UNTRACKED )) && res+=" ${untracked}${(g::)POWERLEVEL9K_VCS_UNTRACKED_ICON}${VCS_STATUS_NUM_UNTRACKED}" + # "─" if the number of unstaged files is unknown. This can happen due to + # POWERLEVEL9K_VCS_MAX_INDEX_SIZE_DIRTY (see below) being set to a non-negative number lower + # than the number of files in the Git index, or due to bash.showDirtyState being set to false + # in the repository config. The number of staged and untracked files may also be unknown + # in this case. + (( VCS_STATUS_HAS_UNSTAGED == -1 )) && res+=" ${modified}─" + + typeset -g my_git_format=$res + } + functions -M my_git_formatter 2>/dev/null + + # Don't count the number of unstaged, untracked and conflicted files in Git repositories with + # more than this many files in the index. Negative value means infinity. + # + # If you are working in Git repositories with tens of millions of files and seeing performance + # sagging, try setting POWERLEVEL9K_VCS_MAX_INDEX_SIZE_DIRTY to a number lower than the output + # of `git ls-files | wc -l`. Alternatively, add `bash.showDirtyState = false` to the repository's + # config: `git config bash.showDirtyState false`. + typeset -g POWERLEVEL9K_VCS_MAX_INDEX_SIZE_DIRTY=-1 + + # Don't show Git status in prompt for repositories whose workdir matches this pattern. + # For example, if set to '~', the Git repository at $HOME/.git will be ignored. + # Multiple patterns can be combined with '|': '~(|/foo)|/bar/baz/*'. + typeset -g POWERLEVEL9K_VCS_DISABLED_WORKDIR_PATTERN='~' + + # Disable the default Git status formatting. + typeset -g POWERLEVEL9K_VCS_DISABLE_GITSTATUS_FORMATTING=true + # Install our own Git status formatter. + typeset -g POWERLEVEL9K_VCS_CONTENT_EXPANSION='${$((my_git_formatter(1)))+${my_git_format}}' + typeset -g POWERLEVEL9K_VCS_LOADING_CONTENT_EXPANSION='${$((my_git_formatter(0)))+${my_git_format}}' + # Enable counters for staged, unstaged, etc. + typeset -g POWERLEVEL9K_VCS_{STAGED,UNSTAGED,UNTRACKED,CONFLICTED,COMMITS_AHEAD,COMMITS_BEHIND}_MAX_NUM=-1 + + # Icon color. + typeset -g POWERLEVEL9K_VCS_VISUAL_IDENTIFIER_COLOR=76 + typeset -g POWERLEVEL9K_VCS_LOADING_VISUAL_IDENTIFIER_COLOR=244 + # Custom icon. + typeset -g POWERLEVEL9K_VCS_VISUAL_IDENTIFIER_EXPANSION= + # Custom prefix. + # typeset -g POWERLEVEL9K_VCS_PREFIX='%246Fon ' + + # Show status of repositories of these types. You can add svn and/or hg if you are + # using them. If you do, your prompt may become slow even when your current directory + # isn't in an svn or hg reposotiry. + typeset -g POWERLEVEL9K_VCS_BACKENDS=(git) + + # These settings are used for repositories other than Git or when gitstatusd fails and + # Powerlevel10k has to fall back to using vcs_info. + typeset -g POWERLEVEL9K_VCS_CLEAN_FOREGROUND=76 + typeset -g POWERLEVEL9K_VCS_UNTRACKED_FOREGROUND=76 + typeset -g POWERLEVEL9K_VCS_MODIFIED_FOREGROUND=178 + + ##########################[ status: exit code of the last command ]########################### + # Enable OK_PIPE, ERROR_PIPE and ERROR_SIGNAL status states to allow us to enable, disable and + # style them independently from the regular OK and ERROR state. + typeset -g POWERLEVEL9K_STATUS_EXTENDED_STATES=true + + # Status on success. No content, just an icon. No need to show it if prompt_char is enabled as + # it will signify success by turning green. + typeset -g POWERLEVEL9K_STATUS_OK=true + typeset -g POWERLEVEL9K_STATUS_OK_FOREGROUND=70 + typeset -g POWERLEVEL9K_STATUS_OK_VISUAL_IDENTIFIER_EXPANSION='✔' + + # Status when some part of a pipe command fails but the overall exit status is zero. It may look + # like this: 1|0. + typeset -g POWERLEVEL9K_STATUS_OK_PIPE=true + typeset -g POWERLEVEL9K_STATUS_OK_PIPE_FOREGROUND=70 + typeset -g POWERLEVEL9K_STATUS_OK_PIPE_VISUAL_IDENTIFIER_EXPANSION='✔' + + # Status when it's just an error code (e.g., '1'). No need to show it if prompt_char is enabled as + # it will signify error by turning red. + typeset -g POWERLEVEL9K_STATUS_ERROR=true + typeset -g POWERLEVEL9K_STATUS_ERROR_FOREGROUND=160 + typeset -g POWERLEVEL9K_STATUS_ERROR_VISUAL_IDENTIFIER_EXPANSION='✘' + + # Status when the last command was terminated by a signal. + typeset -g POWERLEVEL9K_STATUS_ERROR_SIGNAL=true + typeset -g POWERLEVEL9K_STATUS_ERROR_SIGNAL_FOREGROUND=160 + # Use terse signal names: "INT" instead of "SIGINT(2)". + typeset -g POWERLEVEL9K_STATUS_VERBOSE_SIGNAME=false + typeset -g POWERLEVEL9K_STATUS_ERROR_SIGNAL_VISUAL_IDENTIFIER_EXPANSION='✘' + + # Status when some part of a pipe command fails and the overall exit status is also non-zero. + # It may look like this: 1|0. + typeset -g POWERLEVEL9K_STATUS_ERROR_PIPE=true + typeset -g POWERLEVEL9K_STATUS_ERROR_PIPE_FOREGROUND=160 + typeset -g POWERLEVEL9K_STATUS_ERROR_PIPE_VISUAL_IDENTIFIER_EXPANSION='✘' + + ###################[ command_execution_time: duration of the last command ]################### + # Show duration of the last command if takes at least this many seconds. + typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_THRESHOLD=3 + # Show this many fractional digits. Zero means round to seconds. + typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_PRECISION=0 + # Execution time color. + typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_FOREGROUND=248 + # Duration format: 1d 2h 3m 4s. + typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_FORMAT='d h m s' + # Custom icon. + typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_VISUAL_IDENTIFIER_EXPANSION= + # Custom prefix. + # typeset -g POWERLEVEL9K_COMMAND_EXECUTION_TIME_PREFIX='%246Ftook ' + + #######################[ background_jobs: presence of background jobs ]####################### + # Don't show the number of background jobs. + typeset -g POWERLEVEL9K_BACKGROUND_JOBS_VERBOSE=false + # Background jobs color. + typeset -g POWERLEVEL9K_BACKGROUND_JOBS_FOREGROUND=37 + # Custom icon. + # typeset -g POWERLEVEL9K_BACKGROUND_JOBS_VISUAL_IDENTIFIER_EXPANSION='⭐' + + #######################[ direnv: direnv status (https://direnv.net/) ]######################## + # Direnv color. + typeset -g POWERLEVEL9K_DIRENV_FOREGROUND=178 + # Custom icon. + # typeset -g POWERLEVEL9K_DIRENV_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ###############[ asdf: asdf version manager (https://github.com/asdf-vm/asdf) ]############### + # Default asdf color. Only used to display tools for which there is no color override (see below). + # Tip: Override this parameter for ${TOOL} with POWERLEVEL9K_ASDF_${TOOL}_FOREGROUND. + typeset -g POWERLEVEL9K_ASDF_FOREGROUND=66 + + # There are four parameters that can be used to hide asdf tools. Each parameter describes + # conditions under which a tool gets hidden. Parameters can hide tools but not unhide them. If at + # least one parameter decides to hide a tool, that tool gets hidden. If no parameter decides to + # hide a tool, it gets shown. + # + # Special note on the difference between POWERLEVEL9K_ASDF_SOURCES and + # POWERLEVEL9K_ASDF_PROMPT_ALWAYS_SHOW. Consider the effect of the following commands: + # + # asdf local python 3.8.1 + # asdf global python 3.8.1 + # + # After running both commands the current python version is 3.8.1 and its source is "local" as + # it takes precedence over "global". If POWERLEVEL9K_ASDF_PROMPT_ALWAYS_SHOW is set to false, + # it'll hide python version in this case because 3.8.1 is the same as the global version. + # POWERLEVEL9K_ASDF_SOURCES will hide python version only if the value of this parameter doesn't + # contain "local". + + # Hide tool versions that don't come from one of these sources. + # + # Available sources: + # + # - shell `asdf current` says "set by ASDF_${TOOL}_VERSION environment variable" + # - local `asdf current` says "set by /some/not/home/directory/file" + # - global `asdf current` says "set by /home/username/file" + # + # Note: If this parameter is set to (shell local global), it won't hide tools. + # Tip: Override this parameter for ${TOOL} with POWERLEVEL9K_ASDF_${TOOL}_SOURCES. + typeset -g POWERLEVEL9K_ASDF_SOURCES=(shell local global) + + # If set to false, hide tool versions that are the same as global. + # + # Note: The name of this parameter doesn't reflect its meaning at all. + # Note: If this parameter is set to true, it won't hide tools. + # Tip: Override this parameter for ${TOOL} with POWERLEVEL9K_ASDF_${TOOL}_PROMPT_ALWAYS_SHOW. + typeset -g POWERLEVEL9K_ASDF_PROMPT_ALWAYS_SHOW=false + + # If set to false, hide tool versions that are equal to "system". + # + # Note: If this parameter is set to true, it won't hide tools. + # Tip: Override this parameter for ${TOOL} with POWERLEVEL9K_ASDF_${TOOL}_SHOW_SYSTEM. + typeset -g POWERLEVEL9K_ASDF_SHOW_SYSTEM=true + + # If set to non-empty value, hide tools unless there is a file matching the specified file pattern + # in the current directory, or its parent directory, or its grandparent directory, and so on. + # + # Note: If this parameter is set to empty value, it won't hide tools. + # Note: SHOW_ON_UPGLOB isn't specific to asdf. It works with all prompt segments. + # Tip: Override this parameter for ${TOOL} with POWERLEVEL9K_ASDF_${TOOL}_SHOW_ON_UPGLOB. + # + # Example: Hide nodejs version when there is no package.json and no *.js files in the current + # directory, in `..`, in `../..` and so on. + # + # typeset -g POWERLEVEL9K_ASDF_NODEJS_SHOW_ON_UPGLOB='*.js|package.json' + typeset -g POWERLEVEL9K_ASDF_SHOW_ON_UPGLOB= + + # Ruby version from asdf. + typeset -g POWERLEVEL9K_ASDF_RUBY_FOREGROUND=168 + # typeset -g POWERLEVEL9K_ASDF_RUBY_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_ASDF_RUBY_SHOW_ON_UPGLOB='*.foo|*.bar' + + # Python version from asdf. + typeset -g POWERLEVEL9K_ASDF_PYTHON_FOREGROUND=37 + # typeset -g POWERLEVEL9K_ASDF_PYTHON_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_ASDF_PYTHON_SHOW_ON_UPGLOB='*.foo|*.bar' + + # Go version from asdf. + typeset -g POWERLEVEL9K_ASDF_GOLANG_FOREGROUND=37 + # typeset -g POWERLEVEL9K_ASDF_GOLANG_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_ASDF_GOLANG_SHOW_ON_UPGLOB='*.foo|*.bar' + + # Node.js version from asdf. + typeset -g POWERLEVEL9K_ASDF_NODEJS_FOREGROUND=70 + # typeset -g POWERLEVEL9K_ASDF_NODEJS_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_ASDF_NODEJS_SHOW_ON_UPGLOB='*.foo|*.bar' + + # Rust version from asdf. + typeset -g POWERLEVEL9K_ASDF_RUST_FOREGROUND=37 + # typeset -g POWERLEVEL9K_ASDF_RUST_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_ASDF_RUST_SHOW_ON_UPGLOB='*.foo|*.bar' + + # .NET Core version from asdf. + typeset -g POWERLEVEL9K_ASDF_DOTNET_CORE_FOREGROUND=134 + # typeset -g POWERLEVEL9K_ASDF_DOTNET_CORE_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_ASDF_DOTNET_CORE_SHOW_ON_UPGLOB='*.foo|*.bar' + + # Flutter version from asdf. + typeset -g POWERLEVEL9K_ASDF_FLUTTER_FOREGROUND=38 + # typeset -g POWERLEVEL9K_ASDF_FLUTTER_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_ASDF_FLUTTER_SHOW_ON_UPGLOB='*.foo|*.bar' + + # Lua version from asdf. + typeset -g POWERLEVEL9K_ASDF_LUA_FOREGROUND=32 + # typeset -g POWERLEVEL9K_ASDF_LUA_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_ASDF_LUA_SHOW_ON_UPGLOB='*.foo|*.bar' + + # Java version from asdf. + typeset -g POWERLEVEL9K_ASDF_JAVA_FOREGROUND=32 + # typeset -g POWERLEVEL9K_ASDF_JAVA_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_ASDF_JAVA_SHOW_ON_UPGLOB='*.foo|*.bar' + + # Perl version from asdf. + typeset -g POWERLEVEL9K_ASDF_PERL_FOREGROUND=67 + # typeset -g POWERLEVEL9K_ASDF_PERL_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_ASDF_PERL_SHOW_ON_UPGLOB='*.foo|*.bar' + + # Erlang version from asdf. + typeset -g POWERLEVEL9K_ASDF_ERLANG_FOREGROUND=125 + # typeset -g POWERLEVEL9K_ASDF_ERLANG_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_ASDF_ERLANG_SHOW_ON_UPGLOB='*.foo|*.bar' + + # Elixir version from asdf. + typeset -g POWERLEVEL9K_ASDF_ELIXIR_FOREGROUND=129 + # typeset -g POWERLEVEL9K_ASDF_ELIXIR_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_ASDF_ELIXIR_SHOW_ON_UPGLOB='*.foo|*.bar' + + # Postgres version from asdf. + typeset -g POWERLEVEL9K_ASDF_POSTGRES_FOREGROUND=31 + # typeset -g POWERLEVEL9K_ASDF_POSTGRES_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_ASDF_POSTGRES_SHOW_ON_UPGLOB='*.foo|*.bar' + + # PHP version from asdf. + typeset -g POWERLEVEL9K_ASDF_PHP_FOREGROUND=99 + # typeset -g POWERLEVEL9K_ASDF_PHP_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_ASDF_PHP_SHOW_ON_UPGLOB='*.foo|*.bar' + + # Haskell version from asdf. + typeset -g POWERLEVEL9K_ASDF_HASKELL_FOREGROUND=172 + # typeset -g POWERLEVEL9K_ASDF_HASKELL_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_ASDF_HASKELL_SHOW_ON_UPGLOB='*.foo|*.bar' + + # Julia version from asdf. + typeset -g POWERLEVEL9K_ASDF_JULIA_FOREGROUND=70 + # typeset -g POWERLEVEL9K_ASDF_JULIA_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_ASDF_JULIA_SHOW_ON_UPGLOB='*.foo|*.bar' + + ##########[ nordvpn: nordvpn connection status, linux only (https://nordvpn.com/) ]########### + # NordVPN connection indicator color. + typeset -g POWERLEVEL9K_NORDVPN_FOREGROUND=39 + # Hide NordVPN connection indicator when not connected. + typeset -g POWERLEVEL9K_NORDVPN_{DISCONNECTED,CONNECTING,DISCONNECTING}_CONTENT_EXPANSION= + typeset -g POWERLEVEL9K_NORDVPN_{DISCONNECTED,CONNECTING,DISCONNECTING}_VISUAL_IDENTIFIER_EXPANSION= + # Custom icon. + # typeset -g POWERLEVEL9K_NORDVPN_VISUAL_IDENTIFIER_EXPANSION='⭐' + + #################[ ranger: ranger shell (https://github.com/ranger/ranger) ]################## + # Ranger shell color. + typeset -g POWERLEVEL9K_RANGER_FOREGROUND=178 + # Custom icon. + # typeset -g POWERLEVEL9K_RANGER_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ####################[ yazi: yazi shell (https://github.com/sxyazi/yazi) ]##################### + # Yazi shell color. + typeset -g POWERLEVEL9K_YAZI_FOREGROUND=178 + # Custom icon. + # typeset -g POWERLEVEL9K_YAZI_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ######################[ nnn: nnn shell (https://github.com/jarun/nnn) ]####################### + # Nnn shell color. + typeset -g POWERLEVEL9K_NNN_FOREGROUND=72 + # Custom icon. + # typeset -g POWERLEVEL9K_NNN_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ######################[ lf: lf shell (https://github.com/gokcehan/lf) ]####################### + # lf shell color. + typeset -g POWERLEVEL9K_LF_FOREGROUND=72 + # Custom icon. + # typeset -g POWERLEVEL9K_LF_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ##################[ xplr: xplr shell (https://github.com/sayanarijit/xplr) ]################## + # xplr shell color. + typeset -g POWERLEVEL9K_XPLR_FOREGROUND=72 + # Custom icon. + # typeset -g POWERLEVEL9K_XPLR_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ###########################[ vim_shell: vim shell indicator (:sh) ]########################### + # Vim shell indicator color. + typeset -g POWERLEVEL9K_VIM_SHELL_FOREGROUND=34 + # Custom icon. + # typeset -g POWERLEVEL9K_VIM_SHELL_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ######[ midnight_commander: midnight commander shell (https://midnight-commander.org/) ]###### + # Midnight Commander shell color. + typeset -g POWERLEVEL9K_MIDNIGHT_COMMANDER_FOREGROUND=178 + # Custom icon. + # typeset -g POWERLEVEL9K_MIDNIGHT_COMMANDER_VISUAL_IDENTIFIER_EXPANSION='⭐' + + #[ nix_shell: nix shell (https://nixos.org/nixos/nix-pills/developing-with-nix-shell.html) ]## + # Nix shell color. + typeset -g POWERLEVEL9K_NIX_SHELL_FOREGROUND=74 + + # Display the icon of nix_shell if PATH contains a subdirectory of /nix/store. + # typeset -g POWERLEVEL9K_NIX_SHELL_INFER_FROM_PATH=false + + # Tip: If you want to see just the icon without "pure" and "impure", uncomment the next line. + # typeset -g POWERLEVEL9K_NIX_SHELL_CONTENT_EXPANSION= + + # Custom icon. + # typeset -g POWERLEVEL9K_NIX_SHELL_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ##################[ chezmoi_shell: chezmoi shell (https://www.chezmoi.io/) ]################## + # chezmoi shell color. + typeset -g POWERLEVEL9K_CHEZMOI_SHELL_FOREGROUND=33 + # Custom icon. + # typeset -g POWERLEVEL9K_CHEZMOI_SHELL_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ##################################[ disk_usage: disk usage ]################################## + # Colors for different levels of disk usage. + typeset -g POWERLEVEL9K_DISK_USAGE_NORMAL_FOREGROUND=35 + typeset -g POWERLEVEL9K_DISK_USAGE_WARNING_FOREGROUND=220 + typeset -g POWERLEVEL9K_DISK_USAGE_CRITICAL_FOREGROUND=160 + # Thresholds for different levels of disk usage (percentage points). + typeset -g POWERLEVEL9K_DISK_USAGE_WARNING_LEVEL=90 + typeset -g POWERLEVEL9K_DISK_USAGE_CRITICAL_LEVEL=95 + # If set to true, hide disk usage when below $POWERLEVEL9K_DISK_USAGE_WARNING_LEVEL percent. + typeset -g POWERLEVEL9K_DISK_USAGE_ONLY_WARNING=false + # Custom icon. + # typeset -g POWERLEVEL9K_DISK_USAGE_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ###########[ vi_mode: vi mode (you don't need this if you've enabled prompt_char) ]########### + # Text and color for normal (a.k.a. command) vi mode. + typeset -g POWERLEVEL9K_VI_COMMAND_MODE_STRING=NORMAL + typeset -g POWERLEVEL9K_VI_MODE_NORMAL_FOREGROUND=106 + # Text and color for visual vi mode. + typeset -g POWERLEVEL9K_VI_VISUAL_MODE_STRING=VISUAL + typeset -g POWERLEVEL9K_VI_MODE_VISUAL_FOREGROUND=68 + # Text and color for overtype (a.k.a. overwrite and replace) vi mode. + typeset -g POWERLEVEL9K_VI_OVERWRITE_MODE_STRING=OVERTYPE + typeset -g POWERLEVEL9K_VI_MODE_OVERWRITE_FOREGROUND=172 + # Text and color for insert vi mode. + typeset -g POWERLEVEL9K_VI_INSERT_MODE_STRING= + typeset -g POWERLEVEL9K_VI_MODE_INSERT_FOREGROUND=66 + # Custom icon. + # typeset -g POWERLEVEL9K_VI_MODE_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ######################################[ ram: free RAM ]####################################### + # RAM color. + typeset -g POWERLEVEL9K_RAM_FOREGROUND=66 + # Custom icon. + # typeset -g POWERLEVEL9K_RAM_VISUAL_IDENTIFIER_EXPANSION='⭐' + + #####################################[ swap: used swap ]###################################### + # Swap color. + typeset -g POWERLEVEL9K_SWAP_FOREGROUND=96 + # Custom icon. + # typeset -g POWERLEVEL9K_SWAP_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ######################################[ load: CPU load ]###################################### + # Show average CPU load over this many last minutes. Valid values are 1, 5 and 15. + typeset -g POWERLEVEL9K_LOAD_WHICH=5 + # Load color when load is under 50%. + typeset -g POWERLEVEL9K_LOAD_NORMAL_FOREGROUND=66 + # Load color when load is between 50% and 70%. + typeset -g POWERLEVEL9K_LOAD_WARNING_FOREGROUND=178 + # Load color when load is over 70%. + typeset -g POWERLEVEL9K_LOAD_CRITICAL_FOREGROUND=166 + # Custom icon. + # typeset -g POWERLEVEL9K_LOAD_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ################[ todo: todo items (https://github.com/todotxt/todo.txt-cli) ]################ + # Todo color. + typeset -g POWERLEVEL9K_TODO_FOREGROUND=110 + # Hide todo when the total number of tasks is zero. + typeset -g POWERLEVEL9K_TODO_HIDE_ZERO_TOTAL=true + # Hide todo when the number of tasks after filtering is zero. + typeset -g POWERLEVEL9K_TODO_HIDE_ZERO_FILTERED=false + + # Todo format. The following parameters are available within the expansion. + # + # - P9K_TODO_TOTAL_TASK_COUNT The total number of tasks. + # - P9K_TODO_FILTERED_TASK_COUNT The number of tasks after filtering. + # + # These variables correspond to the last line of the output of `todo.sh -p ls`: + # + # TODO: 24 of 42 tasks shown + # + # Here 24 is P9K_TODO_FILTERED_TASK_COUNT and 42 is P9K_TODO_TOTAL_TASK_COUNT. + # + # typeset -g POWERLEVEL9K_TODO_CONTENT_EXPANSION='$P9K_TODO_FILTERED_TASK_COUNT' + + # Custom icon. + # typeset -g POWERLEVEL9K_TODO_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ###########[ timewarrior: timewarrior tracking status (https://timewarrior.net/) ]############ + # Timewarrior color. + typeset -g POWERLEVEL9K_TIMEWARRIOR_FOREGROUND=110 + # If the tracked task is longer than 24 characters, truncate and append "…". + # Tip: To always display tasks without truncation, delete the following parameter. + # Tip: To hide task names and display just the icon when time tracking is enabled, set the + # value of the following parameter to "". + typeset -g POWERLEVEL9K_TIMEWARRIOR_CONTENT_EXPANSION='${P9K_CONTENT:0:24}${${P9K_CONTENT:24}:+…}' + + # Custom icon. + # typeset -g POWERLEVEL9K_TIMEWARRIOR_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ##############[ taskwarrior: taskwarrior task count (https://taskwarrior.org/) ]############## + # Taskwarrior color. + typeset -g POWERLEVEL9K_TASKWARRIOR_FOREGROUND=74 + + # Taskwarrior segment format. The following parameters are available within the expansion. + # + # - P9K_TASKWARRIOR_PENDING_COUNT The number of pending tasks: `task +PENDING count`. + # - P9K_TASKWARRIOR_OVERDUE_COUNT The number of overdue tasks: `task +OVERDUE count`. + # + # Zero values are represented as empty parameters. + # + # The default format: + # + # '${P9K_TASKWARRIOR_OVERDUE_COUNT:+"!$P9K_TASKWARRIOR_OVERDUE_COUNT/"}$P9K_TASKWARRIOR_PENDING_COUNT' + # + # typeset -g POWERLEVEL9K_TASKWARRIOR_CONTENT_EXPANSION='$P9K_TASKWARRIOR_PENDING_COUNT' + + # Custom icon. + # typeset -g POWERLEVEL9K_TASKWARRIOR_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ######[ per_directory_history: Oh My Zsh per-directory-history local/global indicator ]####### + # Color when using local/global history. + typeset -g POWERLEVEL9K_PER_DIRECTORY_HISTORY_LOCAL_FOREGROUND=135 + typeset -g POWERLEVEL9K_PER_DIRECTORY_HISTORY_GLOBAL_FOREGROUND=130 + + # Tip: Uncomment the next two lines to hide "local"/"global" text and leave just the icon. + # typeset -g POWERLEVEL9K_PER_DIRECTORY_HISTORY_LOCAL_CONTENT_EXPANSION='' + # typeset -g POWERLEVEL9K_PER_DIRECTORY_HISTORY_GLOBAL_CONTENT_EXPANSION='' + + # Custom icon. + # typeset -g POWERLEVEL9K_PER_DIRECTORY_HISTORY_LOCAL_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_PER_DIRECTORY_HISTORY_GLOBAL_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ################################[ cpu_arch: CPU architecture ]################################ + # CPU architecture color. + typeset -g POWERLEVEL9K_CPU_ARCH_FOREGROUND=172 + + # Hide the segment when on a specific CPU architecture. + # typeset -g POWERLEVEL9K_CPU_ARCH_X86_64_CONTENT_EXPANSION= + # typeset -g POWERLEVEL9K_CPU_ARCH_X86_64_VISUAL_IDENTIFIER_EXPANSION= + + # Custom icon. + # typeset -g POWERLEVEL9K_CPU_ARCH_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ##################################[ context: user@hostname ]################################## + # Context color when running with privileges. + typeset -g POWERLEVEL9K_CONTEXT_ROOT_FOREGROUND=178 + # Context color in SSH without privileges. + typeset -g POWERLEVEL9K_CONTEXT_{REMOTE,REMOTE_SUDO}_FOREGROUND=180 + # Default context color (no privileges, no SSH). + typeset -g POWERLEVEL9K_CONTEXT_FOREGROUND=180 + + # Context format when running with privileges: bold user@hostname. + typeset -g POWERLEVEL9K_CONTEXT_ROOT_TEMPLATE='%B%n@%m' + # Context format when in SSH without privileges: user@hostname. + typeset -g POWERLEVEL9K_CONTEXT_{REMOTE,REMOTE_SUDO}_TEMPLATE='%n@%m' + # Default context format (no privileges, no SSH): user@hostname. + typeset -g POWERLEVEL9K_CONTEXT_TEMPLATE='%n@%m' + + # Don't show context unless running with privileges or in SSH. + # Tip: Remove the next line to always show context. + #typeset -g POWERLEVEL9K_CONTEXT_{DEFAULT,SUDO}_{CONTENT,VISUAL_IDENTIFIER}_EXPANSION= + + # Custom icon. + # typeset -g POWERLEVEL9K_CONTEXT_VISUAL_IDENTIFIER_EXPANSION='⭐' + # Custom prefix. + # typeset -g POWERLEVEL9K_CONTEXT_PREFIX='%246Fwith ' + + ###[ virtualenv: python virtual environment (https://docs.python.org/3/library/venv.html) ]### + # Python virtual environment color. + typeset -g POWERLEVEL9K_VIRTUALENV_FOREGROUND=37 + # Don't show Python version next to the virtual environment name. + typeset -g POWERLEVEL9K_VIRTUALENV_SHOW_PYTHON_VERSION=false + # If set to "false", won't show virtualenv if pyenv is already shown. + # If set to "if-different", won't show virtualenv if it's the same as pyenv. + typeset -g POWERLEVEL9K_VIRTUALENV_SHOW_WITH_PYENV=false + # Separate environment name from Python version only with a space. + typeset -g POWERLEVEL9K_VIRTUALENV_{LEFT,RIGHT}_DELIMITER= + # Custom icon. + # typeset -g POWERLEVEL9K_VIRTUALENV_VISUAL_IDENTIFIER_EXPANSION='⭐' + + #####################[ anaconda: conda environment (https://conda.io/) ]###################### + # Anaconda environment color. + typeset -g POWERLEVEL9K_ANACONDA_FOREGROUND=37 + + # Anaconda segment format. The following parameters are available within the expansion. + # + # - CONDA_PREFIX Absolute path to the active Anaconda/Miniconda environment. + # - CONDA_DEFAULT_ENV Name of the active Anaconda/Miniconda environment. + # - CONDA_PROMPT_MODIFIER Configurable prompt modifier (see below). + # - P9K_ANACONDA_PYTHON_VERSION Current python version (python --version). + # + # CONDA_PROMPT_MODIFIER can be configured with the following command: + # + # conda config --set env_prompt '({default_env}) ' + # + # The last argument is a Python format string that can use the following variables: + # + # - prefix The same as CONDA_PREFIX. + # - default_env The same as CONDA_DEFAULT_ENV. + # - name The last segment of CONDA_PREFIX. + # - stacked_env Comma-separated list of names in the environment stack. The first element is + # always the same as default_env. + # + # Note: '({default_env}) ' is the default value of env_prompt. + # + # The default value of POWERLEVEL9K_ANACONDA_CONTENT_EXPANSION expands to $CONDA_PROMPT_MODIFIER + # without the surrounding parentheses, or to the last path component of CONDA_PREFIX if the former + # is empty. + typeset -g POWERLEVEL9K_ANACONDA_CONTENT_EXPANSION='${${${${CONDA_PROMPT_MODIFIER#\(}% }%\)}:-${CONDA_PREFIX:t}}' + + # Custom icon. + # typeset -g POWERLEVEL9K_ANACONDA_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ################[ pyenv: python environment (https://github.com/pyenv/pyenv) ]################ + # Pyenv color. + typeset -g POWERLEVEL9K_PYENV_FOREGROUND=37 + # Hide python version if it doesn't come from one of these sources. + typeset -g POWERLEVEL9K_PYENV_SOURCES=(shell local global) + # If set to false, hide python version if it's the same as global: + # $(pyenv version-name) == $(pyenv global). + typeset -g POWERLEVEL9K_PYENV_PROMPT_ALWAYS_SHOW=false + # If set to false, hide python version if it's equal to "system". + typeset -g POWERLEVEL9K_PYENV_SHOW_SYSTEM=true + + # Pyenv segment format. The following parameters are available within the expansion. + # + # - P9K_CONTENT Current pyenv environment (pyenv version-name). + # - P9K_PYENV_PYTHON_VERSION Current python version (python --version). + # + # The default format has the following logic: + # + # 1. Display just "$P9K_CONTENT" if it's equal to "$P9K_PYENV_PYTHON_VERSION" or + # starts with "$P9K_PYENV_PYTHON_VERSION/". + # 2. Otherwise display "$P9K_CONTENT $P9K_PYENV_PYTHON_VERSION". + typeset -g POWERLEVEL9K_PYENV_CONTENT_EXPANSION='${P9K_CONTENT}${${P9K_CONTENT:#$P9K_PYENV_PYTHON_VERSION(|/*)}:+ $P9K_PYENV_PYTHON_VERSION}' + + # Custom icon. + # typeset -g POWERLEVEL9K_PYENV_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ################[ goenv: go environment (https://github.com/syndbg/goenv) ]################ + # Goenv color. + typeset -g POWERLEVEL9K_GOENV_FOREGROUND=37 + # Hide go version if it doesn't come from one of these sources. + typeset -g POWERLEVEL9K_GOENV_SOURCES=(shell local global) + # If set to false, hide go version if it's the same as global: + # $(goenv version-name) == $(goenv global). + typeset -g POWERLEVEL9K_GOENV_PROMPT_ALWAYS_SHOW=false + # If set to false, hide go version if it's equal to "system". + typeset -g POWERLEVEL9K_GOENV_SHOW_SYSTEM=true + # Custom icon. + # typeset -g POWERLEVEL9K_GOENV_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ##########[ nodenv: node.js version from nodenv (https://github.com/nodenv/nodenv) ]########## + # Nodenv color. + typeset -g POWERLEVEL9K_NODENV_FOREGROUND=70 + # Hide node version if it doesn't come from one of these sources. + typeset -g POWERLEVEL9K_NODENV_SOURCES=(shell local global) + # If set to false, hide node version if it's the same as global: + # $(nodenv version-name) == $(nodenv global). + typeset -g POWERLEVEL9K_NODENV_PROMPT_ALWAYS_SHOW=false + # If set to false, hide node version if it's equal to "system". + typeset -g POWERLEVEL9K_NODENV_SHOW_SYSTEM=true + # Custom icon. + # typeset -g POWERLEVEL9K_NODENV_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ##############[ nvm: node.js version from nvm (https://github.com/nvm-sh/nvm) ]############### + # Nvm color. + typeset -g POWERLEVEL9K_NVM_FOREGROUND=70 + # If set to false, hide node version if it's the same as default: + # $(nvm version current) == $(nvm version default). + typeset -g POWERLEVEL9K_NVM_PROMPT_ALWAYS_SHOW=false + # If set to false, hide node version if it's equal to "system". + typeset -g POWERLEVEL9K_NVM_SHOW_SYSTEM=true + # Custom icon. + # typeset -g POWERLEVEL9K_NVM_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ############[ nodeenv: node.js environment (https://github.com/ekalinin/nodeenv) ]############ + # Nodeenv color. + typeset -g POWERLEVEL9K_NODEENV_FOREGROUND=70 + # Don't show Node version next to the environment name. + typeset -g POWERLEVEL9K_NODEENV_SHOW_NODE_VERSION=false + # Separate environment name from Node version only with a space. + typeset -g POWERLEVEL9K_NODEENV_{LEFT,RIGHT}_DELIMITER= + # Custom icon. + # typeset -g POWERLEVEL9K_NODEENV_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ##############################[ node_version: node.js version ]############################### + # Node version color. + typeset -g POWERLEVEL9K_NODE_VERSION_FOREGROUND=70 + # Show node version only when in a directory tree containing package.json. + typeset -g POWERLEVEL9K_NODE_VERSION_PROJECT_ONLY=true + # Custom icon. + # typeset -g POWERLEVEL9K_NODE_VERSION_VISUAL_IDENTIFIER_EXPANSION='⭐' + + #######################[ go_version: go version (https://golang.org) ]######################## + # Go version color. + typeset -g POWERLEVEL9K_GO_VERSION_FOREGROUND=37 + # Show go version only when in a go project subdirectory. + typeset -g POWERLEVEL9K_GO_VERSION_PROJECT_ONLY=true + # Custom icon. + # typeset -g POWERLEVEL9K_GO_VERSION_VISUAL_IDENTIFIER_EXPANSION='⭐' + + #################[ rust_version: rustc version (https://www.rust-lang.org) ]################## + # Rust version color. + typeset -g POWERLEVEL9K_RUST_VERSION_FOREGROUND=37 + # Show rust version only when in a rust project subdirectory. + typeset -g POWERLEVEL9K_RUST_VERSION_PROJECT_ONLY=true + # Custom icon. + # typeset -g POWERLEVEL9K_RUST_VERSION_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ###############[ dotnet_version: .NET version (https://dotnet.microsoft.com) ]################ + # .NET version color. + typeset -g POWERLEVEL9K_DOTNET_VERSION_FOREGROUND=134 + # Show .NET version only when in a .NET project subdirectory. + typeset -g POWERLEVEL9K_DOTNET_VERSION_PROJECT_ONLY=true + # Custom icon. + # typeset -g POWERLEVEL9K_DOTNET_VERSION_VISUAL_IDENTIFIER_EXPANSION='⭐' + + #####################[ php_version: php version (https://www.php.net/) ]###################### + # PHP version color. + typeset -g POWERLEVEL9K_PHP_VERSION_FOREGROUND=99 + # Show PHP version only when in a PHP project subdirectory. + typeset -g POWERLEVEL9K_PHP_VERSION_PROJECT_ONLY=true + # Custom icon. + # typeset -g POWERLEVEL9K_PHP_VERSION_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ##########[ laravel_version: laravel php framework version (https://laravel.com/) ]########### + # Laravel version color. + typeset -g POWERLEVEL9K_LARAVEL_VERSION_FOREGROUND=161 + # Custom icon. + # typeset -g POWERLEVEL9K_LARAVEL_VERSION_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ####################[ java_version: java version (https://www.java.com/) ]#################### + # Java version color. + typeset -g POWERLEVEL9K_JAVA_VERSION_FOREGROUND=32 + # Show java version only when in a java project subdirectory. + typeset -g POWERLEVEL9K_JAVA_VERSION_PROJECT_ONLY=true + # Show brief version. + typeset -g POWERLEVEL9K_JAVA_VERSION_FULL=false + # Custom icon. + # typeset -g POWERLEVEL9K_JAVA_VERSION_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ###[ package: name@version from package.json (https://docs.npmjs.com/files/package.json) ]#### + # Package color. + typeset -g POWERLEVEL9K_PACKAGE_FOREGROUND=117 + # Package format. The following parameters are available within the expansion. + # + # - P9K_PACKAGE_NAME The value of `name` field in package.json. + # - P9K_PACKAGE_VERSION The value of `version` field in package.json. + # + # typeset -g POWERLEVEL9K_PACKAGE_CONTENT_EXPANSION='${P9K_PACKAGE_NAME//\%/%%}@${P9K_PACKAGE_VERSION//\%/%%}' + # Custom icon. + # typeset -g POWERLEVEL9K_PACKAGE_VISUAL_IDENTIFIER_EXPANSION='⭐' + + #############[ rbenv: ruby version from rbenv (https://github.com/rbenv/rbenv) ]############## + # Rbenv color. + typeset -g POWERLEVEL9K_RBENV_FOREGROUND=168 + # Hide ruby version if it doesn't come from one of these sources. + typeset -g POWERLEVEL9K_RBENV_SOURCES=(shell local global) + # If set to false, hide ruby version if it's the same as global: + # $(rbenv version-name) == $(rbenv global). + typeset -g POWERLEVEL9K_RBENV_PROMPT_ALWAYS_SHOW=false + # If set to false, hide ruby version if it's equal to "system". + typeset -g POWERLEVEL9K_RBENV_SHOW_SYSTEM=true + # Custom icon. + # typeset -g POWERLEVEL9K_RBENV_VISUAL_IDENTIFIER_EXPANSION='⭐' + + #######################[ rvm: ruby version from rvm (https://rvm.io) ]######################## + # Rvm color. + typeset -g POWERLEVEL9K_RVM_FOREGROUND=168 + # Don't show @gemset at the end. + typeset -g POWERLEVEL9K_RVM_SHOW_GEMSET=false + # Don't show ruby- at the front. + typeset -g POWERLEVEL9K_RVM_SHOW_PREFIX=false + # Custom icon. + # typeset -g POWERLEVEL9K_RVM_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ###########[ fvm: flutter version management (https://github.com/leoafarias/fvm) ]############ + # Fvm color. + typeset -g POWERLEVEL9K_FVM_FOREGROUND=38 + # Custom icon. + # typeset -g POWERLEVEL9K_FVM_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ##########[ luaenv: lua version from luaenv (https://github.com/cehoffman/luaenv) ]########### + # Lua color. + typeset -g POWERLEVEL9K_LUAENV_FOREGROUND=32 + # Hide lua version if it doesn't come from one of these sources. + typeset -g POWERLEVEL9K_LUAENV_SOURCES=(shell local global) + # If set to false, hide lua version if it's the same as global: + # $(luaenv version-name) == $(luaenv global). + typeset -g POWERLEVEL9K_LUAENV_PROMPT_ALWAYS_SHOW=false + # If set to false, hide lua version if it's equal to "system". + typeset -g POWERLEVEL9K_LUAENV_SHOW_SYSTEM=true + # Custom icon. + # typeset -g POWERLEVEL9K_LUAENV_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ###############[ jenv: java version from jenv (https://github.com/jenv/jenv) ]################ + # Java color. + typeset -g POWERLEVEL9K_JENV_FOREGROUND=32 + # Hide java version if it doesn't come from one of these sources. + typeset -g POWERLEVEL9K_JENV_SOURCES=(shell local global) + # If set to false, hide java version if it's the same as global: + # $(jenv version-name) == $(jenv global). + typeset -g POWERLEVEL9K_JENV_PROMPT_ALWAYS_SHOW=false + # If set to false, hide java version if it's equal to "system". + typeset -g POWERLEVEL9K_JENV_SHOW_SYSTEM=true + # Custom icon. + # typeset -g POWERLEVEL9K_JENV_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ###########[ plenv: perl version from plenv (https://github.com/tokuhirom/plenv) ]############ + # Perl color. + typeset -g POWERLEVEL9K_PLENV_FOREGROUND=67 + # Hide perl version if it doesn't come from one of these sources. + typeset -g POWERLEVEL9K_PLENV_SOURCES=(shell local global) + # If set to false, hide perl version if it's the same as global: + # $(plenv version-name) == $(plenv global). + typeset -g POWERLEVEL9K_PLENV_PROMPT_ALWAYS_SHOW=false + # If set to false, hide perl version if it's equal to "system". + typeset -g POWERLEVEL9K_PLENV_SHOW_SYSTEM=true + # Custom icon. + # typeset -g POWERLEVEL9K_PLENV_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ###########[ perlbrew: perl version from perlbrew (https://github.com/gugod/App-perlbrew) ]############ + # Perlbrew color. + typeset -g POWERLEVEL9K_PERLBREW_FOREGROUND=67 + # Show perlbrew version only when in a perl project subdirectory. + typeset -g POWERLEVEL9K_PERLBREW_PROJECT_ONLY=true + # Don't show "perl-" at the front. + typeset -g POWERLEVEL9K_PERLBREW_SHOW_PREFIX=false + # Custom icon. + # typeset -g POWERLEVEL9K_PERLBREW_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ############[ phpenv: php version from phpenv (https://github.com/phpenv/phpenv) ]############ + # PHP color. + typeset -g POWERLEVEL9K_PHPENV_FOREGROUND=99 + # Hide php version if it doesn't come from one of these sources. + typeset -g POWERLEVEL9K_PHPENV_SOURCES=(shell local global) + # If set to false, hide php version if it's the same as global: + # $(phpenv version-name) == $(phpenv global). + typeset -g POWERLEVEL9K_PHPENV_PROMPT_ALWAYS_SHOW=false + # If set to false, hide php version if it's equal to "system". + typeset -g POWERLEVEL9K_PHPENV_SHOW_SYSTEM=true + # Custom icon. + # typeset -g POWERLEVEL9K_PHPENV_VISUAL_IDENTIFIER_EXPANSION='⭐' + + #######[ scalaenv: scala version from scalaenv (https://github.com/scalaenv/scalaenv) ]####### + # Scala color. + typeset -g POWERLEVEL9K_SCALAENV_FOREGROUND=160 + # Hide scala version if it doesn't come from one of these sources. + typeset -g POWERLEVEL9K_SCALAENV_SOURCES=(shell local global) + # If set to false, hide scala version if it's the same as global: + # $(scalaenv version-name) == $(scalaenv global). + typeset -g POWERLEVEL9K_SCALAENV_PROMPT_ALWAYS_SHOW=false + # If set to false, hide scala version if it's equal to "system". + typeset -g POWERLEVEL9K_SCALAENV_SHOW_SYSTEM=true + # Custom icon. + # typeset -g POWERLEVEL9K_SCALAENV_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ##########[ haskell_stack: haskell version from stack (https://haskellstack.org/) ]########### + # Haskell color. + typeset -g POWERLEVEL9K_HASKELL_STACK_FOREGROUND=172 + # Hide haskell version if it doesn't come from one of these sources. + # + # shell: version is set by STACK_YAML + # local: version is set by stack.yaml up the directory tree + # global: version is set by the implicit global project (~/.stack/global-project/stack.yaml) + typeset -g POWERLEVEL9K_HASKELL_STACK_SOURCES=(shell local) + # If set to false, hide haskell version if it's the same as in the implicit global project. + typeset -g POWERLEVEL9K_HASKELL_STACK_ALWAYS_SHOW=true + # Custom icon. + # typeset -g POWERLEVEL9K_HASKELL_STACK_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ################[ terraform: terraform workspace (https://www.terraform.io) ]################# + # Don't show terraform workspace if it's literally "default". + typeset -g POWERLEVEL9K_TERRAFORM_SHOW_DEFAULT=false + # POWERLEVEL9K_TERRAFORM_CLASSES is an array with even number of elements. The first element + # in each pair defines a pattern against which the current terraform workspace gets matched. + # More specifically, it's P9K_CONTENT prior to the application of context expansion (see below) + # that gets matched. If you unset all POWERLEVEL9K_TERRAFORM_*CONTENT_EXPANSION parameters, + # you'll see this value in your prompt. The second element of each pair in + # POWERLEVEL9K_TERRAFORM_CLASSES defines the workspace class. Patterns are tried in order. The + # first match wins. + # + # For example, given these settings: + # + # typeset -g POWERLEVEL9K_TERRAFORM_CLASSES=( + # '*prod*' PROD + # '*test*' TEST + # '*' OTHER) + # + # If your current terraform workspace is "project_test", its class is TEST because "project_test" + # doesn't match the pattern '*prod*' but does match '*test*'. + # + # You can define different colors, icons and content expansions for different classes: + # + # typeset -g POWERLEVEL9K_TERRAFORM_TEST_FOREGROUND=28 + # typeset -g POWERLEVEL9K_TERRAFORM_TEST_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_TERRAFORM_TEST_CONTENT_EXPANSION='> ${P9K_CONTENT} <' + typeset -g POWERLEVEL9K_TERRAFORM_CLASSES=( + # '*prod*' PROD # These values are examples that are unlikely + # '*test*' TEST # to match your needs. Customize them as needed. + '*' OTHER) + typeset -g POWERLEVEL9K_TERRAFORM_OTHER_FOREGROUND=38 + # typeset -g POWERLEVEL9K_TERRAFORM_OTHER_VISUAL_IDENTIFIER_EXPANSION='⭐' + + #############[ terraform_version: terraform version (https://www.terraform.io) ]############## + # Terraform version color. + typeset -g POWERLEVEL9K_TERRAFORM_VERSION_FOREGROUND=38 + # Custom icon. + # typeset -g POWERLEVEL9K_TERRAFORM_VERSION_VISUAL_IDENTIFIER_EXPANSION='⭐' + + #############[ kubecontext: current kubernetes context (https://kubernetes.io/) ]############# + # Show kubecontext only when the command you are typing invokes one of these tools. + # Tip: Remove the next line to always show kubecontext. + typeset -g POWERLEVEL9K_KUBECONTEXT_SHOW_ON_COMMAND='kubectl|helm|kubens|kubectx|oc|istioctl|kogito|k9s|helmfile|flux|fluxctl|stern|kubeseal|skaffold|kubent|kubecolor|cmctl|sparkctl' + + # Kubernetes context classes for the purpose of using different colors, icons and expansions with + # different contexts. + # + # POWERLEVEL9K_KUBECONTEXT_CLASSES is an array with even number of elements. The first element + # in each pair defines a pattern against which the current kubernetes context gets matched. + # More specifically, it's P9K_CONTENT prior to the application of context expansion (see below) + # that gets matched. If you unset all POWERLEVEL9K_KUBECONTEXT_*CONTENT_EXPANSION parameters, + # you'll see this value in your prompt. The second element of each pair in + # POWERLEVEL9K_KUBECONTEXT_CLASSES defines the context class. Patterns are tried in order. The + # first match wins. + # + # For example, given these settings: + # + # typeset -g POWERLEVEL9K_KUBECONTEXT_CLASSES=( + # '*prod*' PROD + # '*test*' TEST + # '*' DEFAULT) + # + # If your current kubernetes context is "deathray-testing/default", its class is TEST + # because "deathray-testing/default" doesn't match the pattern '*prod*' but does match '*test*'. + # + # You can define different colors, icons and content expansions for different classes: + # + # typeset -g POWERLEVEL9K_KUBECONTEXT_TEST_FOREGROUND=28 + # typeset -g POWERLEVEL9K_KUBECONTEXT_TEST_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_KUBECONTEXT_TEST_CONTENT_EXPANSION='> ${P9K_CONTENT} <' + typeset -g POWERLEVEL9K_KUBECONTEXT_CLASSES=( + # '*prod*' PROD # These values are examples that are unlikely + # '*test*' TEST # to match your needs. Customize them as needed. + '*' DEFAULT) + typeset -g POWERLEVEL9K_KUBECONTEXT_DEFAULT_FOREGROUND=134 + # typeset -g POWERLEVEL9K_KUBECONTEXT_DEFAULT_VISUAL_IDENTIFIER_EXPANSION='⭐' + + # Use POWERLEVEL9K_KUBECONTEXT_CONTENT_EXPANSION to specify the content displayed by kubecontext + # segment. Parameter expansions are very flexible and fast, too. See reference: + # http://zsh.sourceforge.net/Doc/Release/Expansion.html#Parameter-Expansion. + # + # Within the expansion the following parameters are always available: + # + # - P9K_CONTENT The content that would've been displayed if there was no content + # expansion defined. + # - P9K_KUBECONTEXT_NAME The current context's name. Corresponds to column NAME in the + # output of `kubectl config get-contexts`. + # - P9K_KUBECONTEXT_CLUSTER The current context's cluster. Corresponds to column CLUSTER in the + # output of `kubectl config get-contexts`. + # - P9K_KUBECONTEXT_NAMESPACE The current context's namespace. Corresponds to column NAMESPACE + # in the output of `kubectl config get-contexts`. If there is no + # namespace, the parameter is set to "default". + # - P9K_KUBECONTEXT_USER The current context's user. Corresponds to column AUTHINFO in the + # output of `kubectl config get-contexts`. + # + # If the context points to Google Kubernetes Engine (GKE) or Elastic Kubernetes Service (EKS), + # the following extra parameters are available: + # + # - P9K_KUBECONTEXT_CLOUD_NAME Either "gke" or "eks". + # - P9K_KUBECONTEXT_CLOUD_ACCOUNT Account/project ID. + # - P9K_KUBECONTEXT_CLOUD_ZONE Availability zone. + # - P9K_KUBECONTEXT_CLOUD_CLUSTER Cluster. + # + # P9K_KUBECONTEXT_CLOUD_* parameters are derived from P9K_KUBECONTEXT_CLUSTER. For example, + # if P9K_KUBECONTEXT_CLUSTER is "gke_my-account_us-east1-a_my-cluster-01": + # + # - P9K_KUBECONTEXT_CLOUD_NAME=gke + # - P9K_KUBECONTEXT_CLOUD_ACCOUNT=my-account + # - P9K_KUBECONTEXT_CLOUD_ZONE=us-east1-a + # - P9K_KUBECONTEXT_CLOUD_CLUSTER=my-cluster-01 + # + # If P9K_KUBECONTEXT_CLUSTER is "arn:aws:eks:us-east-1:123456789012:cluster/my-cluster-01": + # + # - P9K_KUBECONTEXT_CLOUD_NAME=eks + # - P9K_KUBECONTEXT_CLOUD_ACCOUNT=123456789012 + # - P9K_KUBECONTEXT_CLOUD_ZONE=us-east-1 + # - P9K_KUBECONTEXT_CLOUD_CLUSTER=my-cluster-01 + typeset -g POWERLEVEL9K_KUBECONTEXT_DEFAULT_CONTENT_EXPANSION= + # Show P9K_KUBECONTEXT_CLOUD_CLUSTER if it's not empty and fall back to P9K_KUBECONTEXT_NAME. + POWERLEVEL9K_KUBECONTEXT_DEFAULT_CONTENT_EXPANSION+='${P9K_KUBECONTEXT_CLOUD_CLUSTER:-${P9K_KUBECONTEXT_NAME}}' + # Append the current context's namespace if it's not "default". + POWERLEVEL9K_KUBECONTEXT_DEFAULT_CONTENT_EXPANSION+='${${:-/$P9K_KUBECONTEXT_NAMESPACE}:#/default}' + + # Custom prefix. + # typeset -g POWERLEVEL9K_KUBECONTEXT_PREFIX='%246Fat ' + + #[ aws: aws profile (https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-profiles.html) ]# + # Show aws only when the command you are typing invokes one of these tools. + # Tip: Remove the next line to always show aws. + typeset -g POWERLEVEL9K_AWS_SHOW_ON_COMMAND='aws|awless|cdk|terraform|pulumi|terragrunt' + + # POWERLEVEL9K_AWS_CLASSES is an array with even number of elements. The first element + # in each pair defines a pattern against which the current AWS profile gets matched. + # More specifically, it's P9K_CONTENT prior to the application of context expansion (see below) + # that gets matched. If you unset all POWERLEVEL9K_AWS_*CONTENT_EXPANSION parameters, + # you'll see this value in your prompt. The second element of each pair in + # POWERLEVEL9K_AWS_CLASSES defines the profile class. Patterns are tried in order. The + # first match wins. + # + # For example, given these settings: + # + # typeset -g POWERLEVEL9K_AWS_CLASSES=( + # '*prod*' PROD + # '*test*' TEST + # '*' DEFAULT) + # + # If your current AWS profile is "company_test", its class is TEST + # because "company_test" doesn't match the pattern '*prod*' but does match '*test*'. + # + # You can define different colors, icons and content expansions for different classes: + # + # typeset -g POWERLEVEL9K_AWS_TEST_FOREGROUND=28 + # typeset -g POWERLEVEL9K_AWS_TEST_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_AWS_TEST_CONTENT_EXPANSION='> ${P9K_CONTENT} <' + typeset -g POWERLEVEL9K_AWS_CLASSES=( + # '*prod*' PROD # These values are examples that are unlikely + # '*test*' TEST # to match your needs. Customize them as needed. + '*' DEFAULT) + typeset -g POWERLEVEL9K_AWS_DEFAULT_FOREGROUND=208 + # typeset -g POWERLEVEL9K_AWS_DEFAULT_VISUAL_IDENTIFIER_EXPANSION='⭐' + + # AWS segment format. The following parameters are available within the expansion. + # + # - P9K_AWS_PROFILE The name of the current AWS profile. + # - P9K_AWS_REGION The region associated with the current AWS profile. + typeset -g POWERLEVEL9K_AWS_CONTENT_EXPANSION='${P9K_AWS_PROFILE//\%/%%}${P9K_AWS_REGION:+ ${P9K_AWS_REGION//\%/%%}}' + + #[ aws_eb_env: aws elastic beanstalk environment (https://aws.amazon.com/elasticbeanstalk/) ]# + # AWS Elastic Beanstalk environment color. + typeset -g POWERLEVEL9K_AWS_EB_ENV_FOREGROUND=70 + # Custom icon. + # typeset -g POWERLEVEL9K_AWS_EB_ENV_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ##########[ azure: azure account name (https://docs.microsoft.com/en-us/cli/azure) ]########## + # Show azure only when the command you are typing invokes one of these tools. + # Tip: Remove the next line to always show azure. + typeset -g POWERLEVEL9K_AZURE_SHOW_ON_COMMAND='az|terraform|pulumi|terragrunt' + + # POWERLEVEL9K_AZURE_CLASSES is an array with even number of elements. The first element + # in each pair defines a pattern against which the current azure account name gets matched. + # More specifically, it's P9K_CONTENT prior to the application of context expansion (see below) + # that gets matched. If you unset all POWERLEVEL9K_AZURE_*CONTENT_EXPANSION parameters, + # you'll see this value in your prompt. The second element of each pair in + # POWERLEVEL9K_AZURE_CLASSES defines the account class. Patterns are tried in order. The + # first match wins. + # + # For example, given these settings: + # + # typeset -g POWERLEVEL9K_AZURE_CLASSES=( + # '*prod*' PROD + # '*test*' TEST + # '*' OTHER) + # + # If your current azure account is "company_test", its class is TEST because "company_test" + # doesn't match the pattern '*prod*' but does match '*test*'. + # + # You can define different colors, icons and content expansions for different classes: + # + # typeset -g POWERLEVEL9K_AZURE_TEST_FOREGROUND=28 + # typeset -g POWERLEVEL9K_AZURE_TEST_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_AZURE_TEST_CONTENT_EXPANSION='> ${P9K_CONTENT} <' + typeset -g POWERLEVEL9K_AZURE_CLASSES=( + # '*prod*' PROD # These values are examples that are unlikely + # '*test*' TEST # to match your needs. Customize them as needed. + '*' OTHER) + + # Azure account name color. + typeset -g POWERLEVEL9K_AZURE_OTHER_FOREGROUND=32 + # Custom icon. + # typeset -g POWERLEVEL9K_AZURE_OTHER_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ##########[ gcloud: google cloud account and project (https://cloud.google.com/) ]########### + # Show gcloud only when the command you are typing invokes one of these tools. + # Tip: Remove the next line to always show gcloud. + typeset -g POWERLEVEL9K_GCLOUD_SHOW_ON_COMMAND='gcloud|gcs|gsutil' + # Google cloud color. + typeset -g POWERLEVEL9K_GCLOUD_FOREGROUND=32 + + # Google cloud format. Change the value of POWERLEVEL9K_GCLOUD_PARTIAL_CONTENT_EXPANSION and/or + # POWERLEVEL9K_GCLOUD_COMPLETE_CONTENT_EXPANSION if the default is too verbose or not informative + # enough. You can use the following parameters in the expansions. Each of them corresponds to the + # output of `gcloud` tool. + # + # Parameter | Source + # -------------------------|-------------------------------------------------------------------- + # P9K_GCLOUD_CONFIGURATION | gcloud config configurations list --format='value(name)' + # P9K_GCLOUD_ACCOUNT | gcloud config get-value account + # P9K_GCLOUD_PROJECT_ID | gcloud config get-value project + # P9K_GCLOUD_PROJECT_NAME | gcloud projects describe $P9K_GCLOUD_PROJECT_ID --format='value(name)' + # + # Note: ${VARIABLE//\%/%%} expands to ${VARIABLE} with all occurrences of '%' replaced with '%%'. + # + # Obtaining project name requires sending a request to Google servers. This can take a long time + # and even fail. When project name is unknown, P9K_GCLOUD_PROJECT_NAME is not set and gcloud + # prompt segment is in state PARTIAL. When project name gets known, P9K_GCLOUD_PROJECT_NAME gets + # set and gcloud prompt segment transitions to state COMPLETE. + # + # You can customize the format, icon and colors of gcloud segment separately for states PARTIAL + # and COMPLETE. You can also hide gcloud in state PARTIAL by setting + # POWERLEVEL9K_GCLOUD_PARTIAL_VISUAL_IDENTIFIER_EXPANSION and + # POWERLEVEL9K_GCLOUD_PARTIAL_CONTENT_EXPANSION to empty. + typeset -g POWERLEVEL9K_GCLOUD_PARTIAL_CONTENT_EXPANSION='${P9K_GCLOUD_PROJECT_ID//\%/%%}' + typeset -g POWERLEVEL9K_GCLOUD_COMPLETE_CONTENT_EXPANSION='${P9K_GCLOUD_PROJECT_NAME//\%/%%}' + + # Send a request to Google (by means of `gcloud projects describe ...`) to obtain project name + # this often. Negative value disables periodic polling. In this mode project name is retrieved + # only when the current configuration, account or project id changes. + typeset -g POWERLEVEL9K_GCLOUD_REFRESH_PROJECT_NAME_SECONDS=60 + + # Custom icon. + # typeset -g POWERLEVEL9K_GCLOUD_VISUAL_IDENTIFIER_EXPANSION='⭐' + + #[ google_app_cred: google application credentials (https://cloud.google.com/docs/authentication/production) ]# + # Show google_app_cred only when the command you are typing invokes one of these tools. + # Tip: Remove the next line to always show google_app_cred. + typeset -g POWERLEVEL9K_GOOGLE_APP_CRED_SHOW_ON_COMMAND='terraform|pulumi|terragrunt' + + # Google application credentials classes for the purpose of using different colors, icons and + # expansions with different credentials. + # + # POWERLEVEL9K_GOOGLE_APP_CRED_CLASSES is an array with even number of elements. The first + # element in each pair defines a pattern against which the current kubernetes context gets + # matched. More specifically, it's P9K_CONTENT prior to the application of context expansion + # (see below) that gets matched. If you unset all POWERLEVEL9K_GOOGLE_APP_CRED_*CONTENT_EXPANSION + # parameters, you'll see this value in your prompt. The second element of each pair in + # POWERLEVEL9K_GOOGLE_APP_CRED_CLASSES defines the context class. Patterns are tried in order. + # The first match wins. + # + # For example, given these settings: + # + # typeset -g POWERLEVEL9K_GOOGLE_APP_CRED_CLASSES=( + # '*:*prod*:*' PROD + # '*:*test*:*' TEST + # '*' DEFAULT) + # + # If your current Google application credentials is "service_account deathray-testing x@y.com", + # its class is TEST because it doesn't match the pattern '* *prod* *' but does match '* *test* *'. + # + # You can define different colors, icons and content expansions for different classes: + # + # typeset -g POWERLEVEL9K_GOOGLE_APP_CRED_TEST_FOREGROUND=28 + # typeset -g POWERLEVEL9K_GOOGLE_APP_CRED_TEST_VISUAL_IDENTIFIER_EXPANSION='⭐' + # typeset -g POWERLEVEL9K_GOOGLE_APP_CRED_TEST_CONTENT_EXPANSION='$P9K_GOOGLE_APP_CRED_PROJECT_ID' + typeset -g POWERLEVEL9K_GOOGLE_APP_CRED_CLASSES=( + # '*:*prod*:*' PROD # These values are examples that are unlikely + # '*:*test*:*' TEST # to match your needs. Customize them as needed. + '*' DEFAULT) + typeset -g POWERLEVEL9K_GOOGLE_APP_CRED_DEFAULT_FOREGROUND=32 + # typeset -g POWERLEVEL9K_GOOGLE_APP_CRED_DEFAULT_VISUAL_IDENTIFIER_EXPANSION='⭐' + + # Use POWERLEVEL9K_GOOGLE_APP_CRED_CONTENT_EXPANSION to specify the content displayed by + # google_app_cred segment. Parameter expansions are very flexible and fast, too. See reference: + # http://zsh.sourceforge.net/Doc/Release/Expansion.html#Parameter-Expansion. + # + # You can use the following parameters in the expansion. Each of them corresponds to one of the + # fields in the JSON file pointed to by GOOGLE_APPLICATION_CREDENTIALS. + # + # Parameter | JSON key file field + # ---------------------------------+--------------- + # P9K_GOOGLE_APP_CRED_TYPE | type + # P9K_GOOGLE_APP_CRED_PROJECT_ID | project_id + # P9K_GOOGLE_APP_CRED_CLIENT_EMAIL | client_email + # + # Note: ${VARIABLE//\%/%%} expands to ${VARIABLE} with all occurrences of '%' replaced by '%%'. + typeset -g POWERLEVEL9K_GOOGLE_APP_CRED_DEFAULT_CONTENT_EXPANSION='${P9K_GOOGLE_APP_CRED_PROJECT_ID//\%/%%}' + + ##############[ toolbox: toolbox name (https://github.com/containers/toolbox) ]############### + # Toolbox color. + typeset -g POWERLEVEL9K_TOOLBOX_FOREGROUND=178 + # Don't display the name of the toolbox if it matches fedora-toolbox-*. + typeset -g POWERLEVEL9K_TOOLBOX_CONTENT_EXPANSION='${P9K_TOOLBOX_NAME:#fedora-toolbox-*}' + # Custom icon. + # typeset -g POWERLEVEL9K_TOOLBOX_VISUAL_IDENTIFIER_EXPANSION='⭐' + # Custom prefix. + # typeset -g POWERLEVEL9K_TOOLBOX_PREFIX='%246Fin ' + + ###############################[ public_ip: public IP address ]############################### + # Public IP color. + typeset -g POWERLEVEL9K_PUBLIC_IP_FOREGROUND=94 + # Custom icon. + # typeset -g POWERLEVEL9K_PUBLIC_IP_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ########################[ vpn_ip: virtual private network indicator ]######################### + # VPN IP color. + typeset -g POWERLEVEL9K_VPN_IP_FOREGROUND=81 + # When on VPN, show just an icon without the IP address. + # Tip: To display the private IP address when on VPN, remove the next line. + typeset -g POWERLEVEL9K_VPN_IP_CONTENT_EXPANSION= + # Regular expression for the VPN network interface. Run `ifconfig` or `ip -4 a show` while on VPN + # to see the name of the interface. + typeset -g POWERLEVEL9K_VPN_IP_INTERFACE='(gpd|wg|(.*tun)|tailscale)[0-9]*|(zt.*)' + # If set to true, show one segment per matching network interface. If set to false, show only + # one segment corresponding to the first matching network interface. + # Tip: If you set it to true, you'll probably want to unset POWERLEVEL9K_VPN_IP_CONTENT_EXPANSION. + typeset -g POWERLEVEL9K_VPN_IP_SHOW_ALL=false + # Custom icon. + # typeset -g POWERLEVEL9K_VPN_IP_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ###########[ ip: ip address and bandwidth usage for a specified network interface ]########### + # IP color. + typeset -g POWERLEVEL9K_IP_FOREGROUND=38 + # The following parameters are accessible within the expansion: + # + # Parameter | Meaning + # ----------------------+------------------------------------------- + # P9K_IP_IP | IP address + # P9K_IP_INTERFACE | network interface + # P9K_IP_RX_BYTES | total number of bytes received + # P9K_IP_TX_BYTES | total number of bytes sent + # P9K_IP_RX_BYTES_DELTA | number of bytes received since last prompt + # P9K_IP_TX_BYTES_DELTA | number of bytes sent since last prompt + # P9K_IP_RX_RATE | receive rate (since last prompt) + # P9K_IP_TX_RATE | send rate (since last prompt) + typeset -g POWERLEVEL9K_IP_CONTENT_EXPANSION='${P9K_IP_RX_RATE:+%70F⇣$P9K_IP_RX_RATE }${P9K_IP_TX_RATE:+%215F⇡$P9K_IP_TX_RATE }%38F$P9K_IP_IP' + # Show information for the first network interface whose name matches this regular expression. + # Run `ifconfig` or `ip -4 a show` to see the names of all network interfaces. + typeset -g POWERLEVEL9K_IP_INTERFACE='[ew].*' + # Custom icon. + # typeset -g POWERLEVEL9K_IP_VISUAL_IDENTIFIER_EXPANSION='⭐' + + #########################[ proxy: system-wide http/https/ftp proxy ]########################## + # Proxy color. + typeset -g POWERLEVEL9K_PROXY_FOREGROUND=68 + # Custom icon. + # typeset -g POWERLEVEL9K_PROXY_VISUAL_IDENTIFIER_EXPANSION='⭐' + + ################################[ battery: internal battery ]################################# + # Show battery in red when it's below this level and not connected to power supply. + typeset -g POWERLEVEL9K_BATTERY_LOW_THRESHOLD=20 + typeset -g POWERLEVEL9K_BATTERY_LOW_FOREGROUND=160 + # Show battery in green when it's charging or fully charged. + typeset -g POWERLEVEL9K_BATTERY_{CHARGING,CHARGED}_FOREGROUND=70 + # Show battery in yellow when it's discharging. + typeset -g POWERLEVEL9K_BATTERY_DISCONNECTED_FOREGROUND=178 + # Battery pictograms going from low to high level of charge. + typeset -g POWERLEVEL9K_BATTERY_STAGES='\UF008E\UF007A\UF007B\UF007C\UF007D\UF007E\UF007F\UF0080\UF0081\UF0082\UF0079' + # Don't show the remaining time to charge/discharge. + typeset -g POWERLEVEL9K_BATTERY_VERBOSE=false + + #####################################[ wifi: wifi speed ]##################################### + # WiFi color. + typeset -g POWERLEVEL9K_WIFI_FOREGROUND=68 + # Custom icon. + # typeset -g POWERLEVEL9K_WIFI_VISUAL_IDENTIFIER_EXPANSION='⭐' + + # Use different colors and icons depending on signal strength ($P9K_WIFI_BARS). + # + # # Wifi colors and icons for different signal strength levels (low to high). + # typeset -g my_wifi_fg=(68 68 68 68 68) # <-- change these values + # typeset -g my_wifi_icon=('WiFi' 'WiFi' 'WiFi' 'WiFi' 'WiFi') # <-- change these values + # + # typeset -g POWERLEVEL9K_WIFI_CONTENT_EXPANSION='%F{${my_wifi_fg[P9K_WIFI_BARS+1]}}$P9K_WIFI_LAST_TX_RATE Mbps' + # typeset -g POWERLEVEL9K_WIFI_VISUAL_IDENTIFIER_EXPANSION='%F{${my_wifi_fg[P9K_WIFI_BARS+1]}}${my_wifi_icon[P9K_WIFI_BARS+1]}' + # + # The following parameters are accessible within the expansions: + # + # Parameter | Meaning + # ----------------------+--------------- + # P9K_WIFI_SSID | service set identifier, a.k.a. network name + # P9K_WIFI_LINK_AUTH | authentication protocol such as "wpa2-psk" or "none"; empty if unknown + # P9K_WIFI_LAST_TX_RATE | wireless transmit rate in megabits per second + # P9K_WIFI_RSSI | signal strength in dBm, from -120 to 0 + # P9K_WIFI_NOISE | noise in dBm, from -120 to 0 + # P9K_WIFI_BARS | signal strength in bars, from 0 to 4 (derived from P9K_WIFI_RSSI and P9K_WIFI_NOISE) + + ####################################[ time: current time ]#################################### + # Current time color. + typeset -g POWERLEVEL9K_TIME_FOREGROUND=66 + # Format for the current time: 09:51:02. See `man 3 strftime`. + typeset -g POWERLEVEL9K_TIME_FORMAT='%D{%H:%M:%S}' + # If set to true, time will update when you hit enter. This way prompts for the past + # commands will contain the start times of their commands as opposed to the default + # behavior where they contain the end times of their preceding commands. + typeset -g POWERLEVEL9K_TIME_UPDATE_ON_COMMAND=false + # Custom icon. + typeset -g POWERLEVEL9K_TIME_VISUAL_IDENTIFIER_EXPANSION= + # Custom prefix. + # typeset -g POWERLEVEL9K_TIME_PREFIX='%246Fat ' + + # Example of a user-defined prompt segment. Function prompt_example will be called on every + # prompt if `example` prompt segment is added to POWERLEVEL9K_LEFT_PROMPT_ELEMENTS or + # POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS. It displays an icon and orange text greeting the user. + # + # Type `p10k help segment` for documentation and a more sophisticated example. + function prompt_example() { + p10k segment -f 208 -i '⭐' -t 'hello, %n' + } + + # User-defined prompt segments may optionally provide an instant_prompt_* function. Its job + # is to generate the prompt segment for display in instant prompt. See + # https://github.com/romkatv/powerlevel10k#instant-prompt. + # + # Powerlevel10k will call instant_prompt_* at the same time as the regular prompt_* function + # and will record all `p10k segment` calls it makes. When displaying instant prompt, Powerlevel10k + # will replay these calls without actually calling instant_prompt_*. It is imperative that + # instant_prompt_* always makes the same `p10k segment` calls regardless of environment. If this + # rule is not observed, the content of instant prompt will be incorrect. + # + # Usually, you should either not define instant_prompt_* or simply call prompt_* from it. If + # instant_prompt_* is not defined for a segment, the segment won't be shown in instant prompt. + function instant_prompt_example() { + # Since prompt_example always makes the same `p10k segment` calls, we can call it from + # instant_prompt_example. This will give us the same `example` prompt segment in the instant + # and regular prompts. + prompt_example + } + + # User-defined prompt segments can be customized the same way as built-in segments. + # typeset -g POWERLEVEL9K_EXAMPLE_FOREGROUND=208 + # typeset -g POWERLEVEL9K_EXAMPLE_VISUAL_IDENTIFIER_EXPANSION='⭐' + + # Transient prompt works similarly to the builtin transient_rprompt option. It trims down prompt + # when accepting a command line. Supported values: + # + # - off: Don't change prompt when accepting a command line. + # - always: Trim down prompt when accepting a command line. + # - same-dir: Trim down prompt when accepting a command line unless this is the first command + # typed after changing current working directory. + typeset -g POWERLEVEL9K_TRANSIENT_PROMPT=always + + # Instant prompt mode. + # + # - off: Disable instant prompt. Choose this if you've tried instant prompt and found + # it incompatible with your zsh configuration files. + # - quiet: Enable instant prompt and don't print warnings when detecting console output + # during zsh initialization. Choose this if you've read and understood + # https://github.com/romkatv/powerlevel10k#instant-prompt. + # - verbose: Enable instant prompt and print a warning when detecting console output during + # zsh initialization. Choose this if you've never tried instant prompt, haven't + # seen the warning, or if you are unsure what this all means. + typeset -g POWERLEVEL9K_INSTANT_PROMPT=verbose + + # Hot reload allows you to change POWERLEVEL9K options after Powerlevel10k has been initialized. + # For example, you can type POWERLEVEL9K_BACKGROUND=red and see your prompt turn red. Hot reload + # can slow down prompt by 1-2 milliseconds, so it's better to keep it turned off unless you + # really need it. + typeset -g POWERLEVEL9K_DISABLE_HOT_RELOAD=true + + # If p10k is already loaded, reload configuration. + # This works even with POWERLEVEL9K_DISABLE_HOT_RELOAD=true. + (( ! $+functions[p10k] )) || p10k reload +} + +# Tell `p10k configure` which file it should overwrite. +typeset -g POWERLEVEL9K_CONFIG_FILE=${${(%):-%x}:a} + +(( ${#p10k_config_opts} )) && setopt ${p10k_config_opts[@]} +'builtin' 'unset' 'p10k_config_opts' diff --git a/.profile b/.profile index 788fc7f..c8d3300 100755 --- a/.profile +++ b/.profile @@ -1,4 +1,15 @@ #!/bin/bash +if [ -n "$BASH_SOURCE" ]; then + # Bash or zsh (if BASH_SOURCE is defined) + script="$BASH_SOURCE[0]" +elif [ -n "$ZSH_VERSION" ]; then + # Zsh + script="${(%):-%x}" +else + # Dash or POSIX sh + script="$0" +fi + if test -z "${XDG_RUNTIME_DIR}"; then export XDG_RUNTIME_DIR=/tmp/${UID}-runtime-dir if ! test -d "${XDG_RUNTIME_DIR}"; then @@ -16,7 +27,7 @@ export PROMPT_EOL_MARK="" export EDITOR="nvim" export BROWSER="firefox" export PREFIX=/usr -export PATH="$PATH:$HOME/stuff/scripts/system:$HOME/.cargo/bin:$HOME/stuff/scripts/system/backup" +export PATH="$PATH:$HOME/.cargo/bin:$HOME/stuff/scripts/system:$HOME/stuff/scripts/system/backup:$HOME/stuff/scripts/system/wlx:$HOME/stuff/scripts/system/youtube-playlist-cli:$HOME/.local/bin/blender-4.1.1-linux-x64:$HOME/stuff/manual-programs/app-images" export MANPAGER='nvim +Man!' # export DWM_NOTIF_FILE="/home/iceyrazor/stuff/scripts/c/SDL/notif/notif.txt" @@ -24,33 +35,50 @@ export heartost="/home/iceyrazor/.steam/root/steamapps/music/Heartbound - OST" export cutil=/home/iceyrazor/stuff/scripts/c/my_utils +alias fukin="sudo $@" +alias fukn="sudo $@" +alias fuckin="sudo $@" alias ls='ls --color=auto' -alias lss="sudo du -ah -d 1 | sort -hr" +alias lss="fukin du -ah -d 1 | sort -hr" alias lsu="lsblk --filter 'NAME=~\"sd[abcde]\"' -o NAME,MOUNTPOINTS" +alias surf="WEBKIT_DISABLE_COMPOSITING_MODE=1 surf" alias lsblkfs="lsblk -o PATH,FSTYPE,MOUNTPOINT" alias grep='grep --color=auto' -alias fastfetch='fastfetch --localip-show-ipv4 0' +alias fastfetch='fastfetch --localip-show-ipv4 0 --kitty-direct /home/iceyrazor/stuff/media/ICE/Sprite-0009.png --logo-width 40 --logo-height 20' +[ "$(cat /etc/hostname)" = "Kasino" ] && alias fukn="doas $@" +[ "$(cat /etc/hostname)" = "Kasino" ] && alias fukin="doas $@" +[ "$(cat /etc/hostname)" = "Kasino" ] && alias fuckin="doas $@" +alias numen="echo key x | fukin dotool && NUMEN_DMENU=rofi NUMEN_DMENU_OPTS='-show drun' LD_LIBRARY_PATH=/usr/lib/ numen & disown" + +#[ "$(cat /etc/hostname)" = "Kasino" ] && alias gaysex="zypper dup --allow-vendor-change" +#[ "$(cat /etc/hostname)" = "Kasino" ] && alias cleangaysex="zypper clean -a && fukin zypper ref && fukin zypper dup --allow-vendor-change" +[ "$(cat /etc/hostname)" = "Witchen" ] && alias gaysex="pacman -Syyu && paru -Syyu --aur" +[ "$(cat /etc/hostname)" = "Kasino" ] && alias gaysex="pacman -Syyu && paru -Syyu --aur" alias ascii="~/stuff/scripts/c/SDL/ascii/ascii" -alias watchlss="sudo watch \"du -ah -d 1 | sort -hr\"" +alias watchlss="fukin watch \"du -ah -d 1 | sort -hr\"" alias lfub=~/.local/bin/lf-gadgets/lf-ueberzug/lf-ueberzug alias lfk=~/.local/bin/lf-gadgets/lf-kitty/lf-kitty alias ovim=/usr/bin/vim alias vim=nvim alias fzf="fzf --walker-skip=.private-parent" alias fcd="cd \"\$(fzf --walker dir,hidden --walker-skip=.private-parent)\"" +alias notes="cd ~/stuff/notes && vim notes.md && cd ~" alias ts="~/stuff/scripts/system/tmux-sessionizer.sh" +alias fman="bash -c 'compgen -c' | fzf | xargs man" +alias etask="$EDITOR stuff/scripts/system/task.sh" -#alias updateL='sudo /home/iceyrazor/update_list/update_list.sh ' +#alias updateL='fukin /home/iceyrazor/update_list/update_list.sh ' alias session="./Downloads/session-desktop-linux-x86_64-1.12.4.AppImage > /dev/null & disown" alias simplex="_JAVA_AWT_WM_NONREPARENTING=1 ./Downloads/simplex-desktop-x86_64.AppImage > /dev/null & disown" +alias ygg="fukin bash -c 'mkdir /var/run/yggdrasil; yggdrasil -useconf < /etc/yggdrasil.conf'" alias loki="./stuff/scripts/loki-toggle.sh" -alias lokig="sudo Lokinet-GUI.AppImage --no-sandbox > /dev/null & disown" -alias alvr="WINIT_X11_SCALE_FACTOR=\"1\" ~/stuff/app_images/ALVR-x86_64.AppImage & disown" -alias wlx="~/stuff/app_images/WlxOverlay-v1.4.5-x86_64.AppImage & disown" -alias obss="sudo obs && obs & disown" +alias lokig="fukin Lokinet-GUI.AppImage --no-sandbox > /dev/null & disown" +alias alvr="WINIT_X11_SCALE_FACTOR=\"1\" /home/iceyrazor/stuff/manual-programs/dontsync/alvr_streamer_linux/bin/alvr_dashboard & disown" +alias obss="fukin obs && obs & disown" +alias get_channel_id="xargs curl -s | grep -Eo 'channel_id=.{0,50}' | sed 's/\".*//g' | fzf | xargs printf \"https://www.youtube.com/feeds/videos.xml?%s\" | xclip -selection clipboard" alias killa="~/stuff/killall.sh" alias bbackup="~/stuff/scripts/system/backup/backup.sh" @@ -58,22 +86,25 @@ alias bbacklap="~/stuff/scripts/system/backup/backup-tol.sh" alias bgit="~/stuff/scripts/system/backup/move-to-git.sh" alias vasm="~/stuff/manual-programs/vasm/vasm6502_oldstyle -Fbin -dotdir " alias pipes="pipes.sh -t 0 -p 3 -f 30 -r 2000" +alias rerules="fukin udevadm control --reload-rules && fukin udevadm trigger" -alias bri="sudo ~/stuff/scripts/system/bri.sh" + +alias bri="fukin ~/stuff/scripts/system/bri.sh" +alias drkwll="nitrogen --head=0 --set-zoom-fill ~/stuff/media/gallifreyan/linux2.png" # mounting -alias umsu="sudo umount u" -alias umsu2="sudo umount u2" -alias mswin="sudo mount -o umask=0,uid=nobody,gid=nobody /dev/sdb3 ~/windir" -alias umswin="sudo umount ~/windir" -alias msbak="sudo cryptsetup open /dev/sda1 backups && sudo mount /dev/mapper/backups ~/mnt-backups" # && sudo bindfs -u iceyrazor /mnt-backups ~/mnt-backups" -alias umsbak="sudo umount ~/mnt-backups && sudo cryptsetup close backups" # " sudo umount /mnt-backups && sudo cryptsetup close backups" -alias msfd="sudo mount /dev/sdc1 u2" -alias msf="sudo cryptsetup open /dev/sdc2 flashdrive && sudo mount /dev/mapper/flashdrive ~/u" -alias umsf="sudo umount ~/u && sudo cryptsetup close flashdrive" +alias umsu="fukin umount u" +alias umsu2="fukin umount u2" +alias mswin="fukin mount -o umask=0,uid=nobody,gid=nobody /dev/sdb3 ~/windir" +alias umswin="fukin umount ~/windir" +alias msbak="doas cryptsetup open /dev/sda1 backups && doas mount /dev/mapper/backups ~/mnt-backups" # && fukin bindfs -u iceyrazor /mnt-backups ~/mnt-backups" +alias umsbak="doas umount ~/mnt-backups && doas cryptsetup close backups" # " fukin umount /mnt-backups && fukin cryptsetup close backups" +alias msfd="fukin mount /dev/sdc1 u2" +alias msf="fukin cryptsetup open /dev/sdc2 flashdrive && fukin mount /dev/mapper/flashdrive ~/u" +alias umsf="fukin umount ~/u && fukin cryptsetup close flashdrive" alias cam="ffplay -input_format mjpeg -fast -fflags +nobuffer -i -framerate 30 -max_delay 100 -max_probe_packets 0 -analyzeduration 0 -flags +low_delay /dev/video0" -alias sc="ffmpeg -f x11grab -framerate 1 -video_size 1920x1200 -i :0.0 -vframes 1 -crf 18 ~/output.jpeg" +alias sc="ffmpeg -f x11grab -framerate 1 -video_size 1920x1200 -i :0.0 -vframes 1 -crf 18 ~/Pictures/Screenshots/$(date '+%m-%d-%Y-%I-%M')_${RANDOM}_screenshot.jpeg" alias sc2="escrotum -s ~/Pictures/%Y-%m-%d-%H%M%S_$wx$h_escrotum.png" alias scs="sleep 3s && ffmpeg -f x11grab -framerate 1 -video_size 1920x1200 -i :0.0 -vframes 1 -crf 18 output.jpeg" alias wwrite="watch -d grep -e Dirty: -e Writeback: /proc/meminfo" @@ -83,7 +114,7 @@ alias gol="~/stuff/scripts/c/SDL/game-of-life/game-of-life & disown" alias statst="echo full_stat:true > ~/stuff/scripts/system/stbar/config.txt" alias statsf="echo full_stat:false > ~/stuff/scripts/system/stbar/config.txt" -alias get_drm="sudo cat /sys/module/nvidia_drm/parameters/modeset" +alias get_drm="fukin cat /sys/module/nvidia_drm/parameters/modeset" alias nodem="find . -name 'node_modules' -type d | xargs du -sh | sort -hr | fzf -m --header \"select witch ones to delete\" --preview 'cat $(dirname {})/package.json'|awk print '{print $2}' | xargs -r rm -rf" @@ -91,3 +122,4 @@ alias walltaker="stuff/manual-programs/git/walltaker-client/walltaker.sh" alias savewall="stuff/manual-programs/git/walltaker-client/save.sh" xset r rate 300 50 +# xset r off diff --git a/.surf/styles/default.css b/.surf/styles/default.css deleted file mode 100644 index 69259cc..0000000 --- a/.surf/styles/default.css +++ /dev/null @@ -1,16 +0,0 @@ -*,div,pre,textarea,body,input,td,tr,p { - background-color: #202020 !important; - background-image: none !important; - color: #bbbbbb !important; -} -h1,h2,h3,h4 { - background-color: #202020 !important; - color: #b8ddea !important; -} -img { - opacity: .5; -} -img:hover { - opacity: 1; -} - diff --git a/.tmux.conf b/.tmux.conf new file mode 100755 index 0000000..9a29b7a --- /dev/null +++ b/.tmux.conf @@ -0,0 +1,69 @@ +#run-shell ~/clone/path/logging.tmux +set -g default-terminal "screen-256color" +set -g terminal-overrides 'screen*:colors=256' + +set -g default-shell /bin/zsh +set -g default-command /bin/zsh + +#set -g status-interval 3 + +unbind C-b +set-option -g prefix C-Space + +# set vim mode +set-window-option -g mode-keys vi +setw -g mode-keys vi + +# yank and visual rebinds +bind -T copy-mode-vi v send-keys -X begin-selection +bind -T copy-mode-vi y send-keys -X copy-pipe-and-cancel 'xclip -selection clipboard' + +# dont exit copy mode with mouse drag +unbind -T copy-mode-vi MouseDragEnd1Pane + + +# bind r to reload config +unbind r +bind r source-file ~/.tmux.conf + +# start panes and windows 1 +set -g base-index 1 +set -g pane-base-index 1 +set -g renumber-windows on # renumber windows when one is closed + +# nav rebinds +bind -r C-h select-pane -L +bind -r C-j select-pane -D +bind -r C-k select-pane -U +bind -r C-l select-pane -R + +bind -r h resize-pane -L 5 +bind -r j resize-pane -D 5 +bind -r k resize-pane -U 5 +bind -r l resize-pane -R 5 +bind -r m resize-pane -Z # maximize + +# pane joining +bind J switch-client -T pane-management +bind-key -T pane-management \" command-prompt -p "join pane from:" "join-pane -s '%%' -h" +bind-key -T pane-management H command-prompt -p "join pane from:" "join-pane -s '%%' -f -h" +bind-key -T pane-management % command-prompt -p "join pane from:" "join-pane -s '%%' -v" +bind-key -T pane-management V command-prompt -p "join pane from:" "join-pane -s '%%' -f -v" +bind-key -T pane-management B break-pane +bind-key -T pane-management S command-prompt -p "send pane to:" "join-pane -t '%%'" + +bind-key -r H split-window -h -f + + +# colors/theme +set -g status-bg "#333333" +set -g status-fg "#f1f1f1" +set -wg mode-style bg="#333334" +set -g pane-border-style fg='#333333' +set -g pane-active-border-style fg='#a030f0' +active_window_fg='#e080f0' +set -g status-left "#[fg=${session_fg},bold,bg=${bg}][ #S] " +set -g status-left-length 40 +set -g window-status-current-format "#[fg=${active_window_fg},bg=default] #I:#W" +set -g window-status-format "#[fg=${default_fg},bg=default]#I:#W" +# set -g window-status-last-style "fg=${default_fg},bg=default" diff --git a/.wezterm.lua b/.wezterm.lua index 3e4242d..0e135d7 100755 --- a/.wezterm.lua +++ b/.wezterm.lua @@ -2,9 +2,13 @@ local wezterm = require 'wezterm' local config = {} local act = wezterm.action +config.default_prog = { 'zsh', '-l' } + --config.font = wezterm.font 'Classic Console' --config.font_size = 15 --config.font = wezterm.font 'Source Code Pro' +config.show_tabs_in_tab_bar = false +config.enable_tab_bar = false config.font = wezterm.font 'CozetteVector' config.font_size = 15 @@ -21,7 +25,8 @@ config.keys = { config.colors={ foreground = '#e6e6e6', - background = '#101010', + --background = '#101010', + background = '#04000a', cursor_fg = '#fabd2f', ansi = { '#263640', @@ -47,4 +52,62 @@ config.colors={ config.window_background_opacity = 0.8 +local function tab_title(tab_info) + local title = tab_info.tab_title + -- if the tab title is explicitly set, take that + if title and #title > 0 then + return title + end + -- Otherwise, use the title from the active pane + -- in that tab + return tab_info.active_pane.title +end + +-- The filled in variant of the < symbol +local SOLID_LEFT_ARROW = wezterm.nerdfonts.pl_right_hard_divider + +-- The filled in variant of the > symbol +local SOLID_RIGHT_ARROW = wezterm.nerdfonts.pl_left_hard_divider + +config.use_fancy_tab_bar = false +config.show_new_tab_button_in_tab_bar = false +--[[ +wezterm.on( + 'format-tab-title', + function(tab, tabs, panes, config2, hover, max_width) + local edge_background = '#0b0022' + local background = '#1b1032' + local foreground = '#808080' + + if tab.is_active then + background = '#2b2042' + foreground = '#c0c0c0' + elseif hover then + background = '#3b3052' + foreground = '#909090' + end + + local edge_foreground = background + + local title = tab_title(tab) + + -- ensure that the titles fit in the available space, + -- and that we have room for the edges. + title = wezterm.truncate_right(title, max_width - 2) + + return { + { Background = { Color = edge_background } }, + { Foreground = { Color = edge_foreground } }, + { Text = SOLID_LEFT_ARROW }, + { Background = { Color = background } }, + { Foreground = { Color = foreground } }, + { Text = title }, + { Background = { Color = edge_background } }, + { Foreground = { Color = edge_foreground } }, + { Text = SOLID_RIGHT_ARROW }, + } + end +) +--]] + return config diff --git a/.zshrc b/.zshrc index 9e07903..bfecd2c 100755 --- a/.zshrc +++ b/.zshrc @@ -1,22 +1,37 @@ +# Enable Powerlevel10k instant prompt. Should stay close to the top of ~/.zshrc. +# Initialization code that may require console input (password prompts, [y/n] +# confirmations, etc.) must go above this block; everything else may go below. + +if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]; then + source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" +fi + # Lines configured by zsh-newuser-install HISTFILE=~/.histfile HISTSIZE=1000 SAVEHIST=1000 -bindkey -v # End of lines configured by zsh-newuser-install -PS1='%B%F{white}[%B%F{red}Z%B%F{magenta}%n%B%F{yellow}@%B%F{magenta}%M %B%F{cyan}%1~%B%F{white}]%B%F{default}$ ' +PS1='%B%F{white}[%B%F{magenta}%n%B%F{yellow}@%B%F{magenta}%M %B%F{cyan}%1~%B%F{white}]%B%F{default}$ ' #PS1='%B%F{white}[%B%F{red}Z%B%F{magenta}ARCH %B%F{cyan}%1~%B%F{white}]%B%F{default}$ ' +bindkey -v # Yank to the system clipboard function vi-yank-xclip { - #zle vi-yank + zle vi-yank echo "$CUTBUFFER" | xclip -selection clipboard } zle -N vi-yank-xclip bindkey -M vicmd ' y' vi-yank-xclip -source ~/stuff/scripts/system/neoboot.sh source ~/.profile +#bash --login -i -c 'source ~/.profile' +source ~/.config/zsh/powerlevel10k/powerlevel10k.zsh-theme + +# To customize prompt, run `p10k configure` or edit ~/.p10k.zsh. +[[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh + + +eval "$(atuin init zsh)" diff --git a/stuff/manual-programs/suckless/dmenu-5.2/dmenu b/stuff/manual-programs/suckless/dmenu-5.2/dmenu old mode 100644 new mode 100755 diff --git a/stuff/manual-programs/suckless/dmenu-5.2/dmenu_path b/stuff/manual-programs/suckless/dmenu-5.2/dmenu_path old mode 100644 new mode 100755 diff --git a/stuff/manual-programs/suckless/dmenu-5.2/dmenu_run b/stuff/manual-programs/suckless/dmenu-5.2/dmenu_run old mode 100644 new mode 100755 diff --git a/stuff/manual-programs/suckless/dmenu-5.2/stest b/stuff/manual-programs/suckless/dmenu-5.2/stest old mode 100644 new mode 100755 diff --git a/stuff/manual-programs/suckless/dwm-bak/dwm b/stuff/manual-programs/suckless/dwm-bak/dwm old mode 100644 new mode 100755 diff --git a/stuff/manual-programs/suckless/dwm/dwm b/stuff/manual-programs/suckless/dwm/dwm old mode 100644 new mode 100755 diff --git a/stuff/manual-programs/suckless/dwm/dwm.c.orig b/stuff/manual-programs/suckless/dwm/dwm.c.orig index 0f0365a..f4e0d0b 100644 --- a/stuff/manual-programs/suckless/dwm/dwm.c.orig +++ b/stuff/manual-programs/suckless/dwm/dwm.c.orig @@ -223,6 +223,7 @@ static void resizemouse(const Arg *arg); static void resizerequest(XEvent *e); static void restack(Monitor *m); static void run(void); +static void runAutostart(void); static void scan(void); static int sendevent(Window w, Atom proto, int m, long d0, long d1, long d2, long d3, long d4); static void sendmon(Client *c, Monitor *m); @@ -1554,6 +1555,12 @@ run(void) handler[ev.type](&ev); /* call handler */ } +void +runAutostart(void) { + system("cd ~/.config/dwm; ./autostart_blocking.sh"); + system("cd ~/.config/dwm; ./autostart.sh &"); +} + void scan(void) { @@ -2509,6 +2516,7 @@ main(int argc, char *argv[]) die("pledge"); #endif /* __OpenBSD__ */ scan(); + runAutostart(); run(); cleanup(); XCloseDisplay(dpy); diff --git a/stuff/manual-programs/suckless/dwm/util.o b/stuff/manual-programs/suckless/dwm/util.o index 8e55fa1..aa3779b 100644 Binary files a/stuff/manual-programs/suckless/dwm/util.o and b/stuff/manual-programs/suckless/dwm/util.o differ diff --git a/stuff/manual-programs/suckless/surf/config.mk b/stuff/manual-programs/suckless/surf/config.mk index 2eb9fb0..e55ffd9 100644 --- a/stuff/manual-programs/suckless/surf/config.mk +++ b/stuff/manual-programs/suckless/surf/config.mk @@ -30,3 +30,4 @@ WEBEXTCFLAGS = -fPIC $(WEBEXTINC) # compiler #CC = c99 +CC = gcc -std=c99 diff --git a/stuff/manual-programs/suckless/surf/surf b/stuff/manual-programs/suckless/surf/surf index 4774188..2bc25ab 100644 Binary files a/stuff/manual-programs/suckless/surf/surf and b/stuff/manual-programs/suckless/surf/surf differ diff --git a/stuff/manual-programs/suckless/surf/surf.o b/stuff/manual-programs/suckless/surf/surf.o index addfe30..f7e1b3e 100644 Binary files a/stuff/manual-programs/suckless/surf/surf.o and b/stuff/manual-programs/suckless/surf/surf.o differ diff --git a/stuff/manual-programs/suckless/surf/webext-surf.o b/stuff/manual-programs/suckless/surf/webext-surf.o index b691525..4dc740f 100644 Binary files a/stuff/manual-programs/suckless/surf/webext-surf.o and b/stuff/manual-programs/suckless/surf/webext-surf.o differ diff --git a/stuff/manual-programs/suckless/surf/webext-surf.so b/stuff/manual-programs/suckless/surf/webext-surf.so index 8a38856..39e59d4 100644 Binary files a/stuff/manual-programs/suckless/surf/webext-surf.so and b/stuff/manual-programs/suckless/surf/webext-surf.so differ diff --git a/stuff/scripts/system/backup/backup.sh b/stuff/scripts/system/backup/backup.sh index 16559d1..3391ec6 100755 --- a/stuff/scripts/system/backup/backup.sh +++ b/stuff/scripts/system/backup/backup.sh @@ -15,11 +15,13 @@ fsyncb () { fi } -syncfile="stuff .bash_profile .bashrc .surf .wezterm.lua .tmux.conf .gtkrc-2.0 .profile .urlview .vimrc .xinitrc .Xresources .zshrc .newsboat .gnupg .ssh .local/bin/lf-gadgets .config/dwm .config/awesome .config/gtk-3.0 .config/rofi .config/lf .config/picom.conf .config/nvim .config/screenkey.json .config/vesktop/themes .keepass .config/Pinta" +syncfile="stuff .bash_profile .bashrc .surf/styles .wezterm.lua .tmux.conf .gtkrc-2.0 .profile .urlview .vimrc .xinitrc .Xresources .zshrc .p10k.zsh .newsboat .gnupg .ssh .local/bin/lf-gadgets .config/dwm .config/awesome .config/wlxoverlay .config/vesktop/themes .config/gtk-3.0 .config/rofi .config/lf .config/mutt .config/zsh .config/picom.conf .config/nvim .config/atuin .config/screenkey.json .config/vesktop/themes .keepass .config/Pinta .local/share/applications/custom" + +# se shit +syncfile="$syncfile /home/iceyrazor/.local/share/Steam/steamapps/compatdata/244850/pfx/drive_c/users/steamuser/AppData/Roaming/SpaceEngineers/Blueprints /home/iceyrazor/.local/share/Steam/steamapps/compatdata/244850/pfx/drive_c/users/steamuser/AppData/Roaming/SpaceEngineers/IngameScripts /home/iceyrazor/.local/share/Steam/steamapps/compatdata/244850/pfx/drive_c/users/steamuser/AppData/Roaming/SpaceEngineers/Saves" -#sync game stuff target="/home/iceyrazor/mnt-backups/LINUX FILES/home/iceyrazor" -exclude="--exclude **/cc-survival --exclude node_modules --exclude dontsync --exclude **/iceys-linux-stuffs" +exclude="--exclude node_modules --exclude node_modules_23 --exclude dontsync --exclude **/iceys-linux-stuffs --exclude **/target --exclude LinVAM/pyenv" fsynca @@ -27,4 +29,3 @@ fsynca printf "==CC-survival unsynced\n\n" fsyncb - diff --git a/stuff/scripts/system/backup/copy-to-git.sh b/stuff/scripts/system/backup/copy-to-git.sh index ad2a42d..921c051 100755 --- a/stuff/scripts/system/backup/copy-to-git.sh +++ b/stuff/scripts/system/backup/copy-to-git.sh @@ -1,21 +1,21 @@ cd ~/ fsync () { - rsync -RUurvn --size-only --delete-after $exclude $syncfile "$target" + rsync -RUurvn --delete-after $exclude $syncfile "$target" printf "===commit these changes?\n" read -p "y/n: " uinput if [ "$uinput" != "n" ] && [ "$uinput" != "N" ]; then printf "\n\n\n" - rsync -PRUurv --size-only --delete-after $exclude $syncfile "$target" + rsync -PRUurv --delete-after $exclude $syncfile "$target" printf "\n===end sync\n---------\n\n" fi } -syncfile=".bash_profile .bashrc .gtkrc-2.0 .wezterm.lua .profile .urlview .vimrc .Xresources .zshrc .config/dwm .config/awesome .config/rofi .config/lf .config/picom.conf .config/nvim .config/screenkey.json stuff/manual-programs/suckless" +syncfile=".bash_profile .bashrc .gtkrc-2.0 .tmux.conf .wezterm.lua .profile .urlview .vimrc .Xresources .zshrc .p10k.zsh .config/dwm .config/awesome .config/rofi .config/lf .config/picom.conf .config/nvim .config/atuin .config/screenkey.json stuff/manual-programs/suckless" syncfile="$syncfile stuff/scripts/system/stbar stuff/scripts/system/url-handler.sh stuff/scripts/system/backup/copy-to-git.sh stuff/scripts/system/backup/backup.sh" syncfile="$syncfile stuff/scripts/system/neoboot.sh stuff/scripts/system/math.sh stuff/scripts/system/bri.sh stuff/scripts/system/restart-pipe.sh stuff/scripts/system/set-pri-java.sh" target=~/stuff/iceys-linux-stuffs -exclude="--exclude check_weth.sh --exclude lua-ls-cc-tweaked --exclude .config/nvim/plugin" +exclude="--exclude check_weth.sh --exclude awesome/default --exclude lua-ls-cc-tweaked --exclude .config/nvim/plugin" fsync diff --git a/stuff/scripts/system/neoboot.sh b/stuff/scripts/system/neoboot.sh index 2df07de..9c64015 100755 --- a/stuff/scripts/system/neoboot.sh +++ b/stuff/scripts/system/neoboot.sh @@ -1,3 +1,4 @@ +#!/bin/bash normal() { randnum=$(($RANDOM % 2)) @@ -21,7 +22,7 @@ laptop() { lsblk --filter 'NAME=~"sd[abcde]"' -o NAME,MOUNTPOINTS | lolcat -as 10000 -S 100 } -if [[ "$(cat /etc/hostname)" == "iceynethp1" ]]; then +if [[ "$(cat /etc/hostname)" == "Witchen" ]]; then laptop else normal diff --git a/stuff/scripts/system/stbar/stbar-awesome.sh b/stuff/scripts/system/stbar/stbar-awesome.sh index 84c1894..ef9ecca 100755 --- a/stuff/scripts/system/stbar/stbar-awesome.sh +++ b/stuff/scripts/system/stbar/stbar-awesome.sh @@ -3,7 +3,7 @@ delim='|' curr_dir="$(cd "$(dirname "$0")" && pwd)" #wifi_device=$(cat $curr_dir/config.txt | grep wifi_device | sed 's/wifi_device://') -wifi_device="wlp4s0" +wifi_device="wlan0" # curr_dir/check_weth.sh "$cur_dir" & @@ -32,28 +32,34 @@ if [ "$(ls /sys/class/power_supply/BAT0/)" ]; then echo "$delim" fi +#mic + +[ "$(pactl get-source-mute @DEFAULT_SOURCE@)" == "Mute: no" ] && echo  || echo 󰍭 + +echo "$delim" + #rss -echo RSS:$(newsboat -x print-unread|sed "s/\s.*//; s/Error:/IA/") +echo  $(newsboat -x print-unread|sed "s/\s.*//; s/Error:/IA/") echo "$delim" if [ "$(cat $curr_dir/config.txt | grep full_stat)" == "full_stat:true" ]; then #cpu - echo CPU:$(ps axch -o cmd:15,%cpu --sort=-%cpu | sed "1q")% + echo  $(ps axch -o cmd:15,%cpu --sort=-%cpu | sed "1q")% echo "$delim" #mem - echo Mem:$(free -mlw | grep Mem: | sed "s/Mem\:\W*[0-9]*\W*//; s/ .*//") + echo  $(free -mlw | grep Mem: | sed "s/Mem\:\W*[0-9]*\W*//; s/ .*//") echo $(ps axch -o cmd:15,%mem --sort=-%mem | sed "1q")% else #cpu - echo CPU:$(ps axch -o cmd:15,%cpu --sort=-%cpu | sed "1q" | sed 's/.* //')% + echo  $(ps axch -o cmd:15,%cpu --sort=-%cpu | sed "1q" | sed 's/.* //')% #mem - echo Mem:$(free -mlw | grep Mem: | sed "s/Mem\:\W*[0-9]*\W*//; s/ .*//") + echo  $(free -mlw | grep Mem: | sed "s/Mem\:\W*[0-9]*\W*//; s/ .*//") fi echo "$delim" @@ -62,7 +68,7 @@ echo "$delim" #echo \/$(df -h | grep /dev/nvme0n1p3 | sed "s/\/dev\/nvme0n1p3 *[0-9]*.[0-9]*. *[0-9]*.[0-9]*. *//" | sed "s/ .*//") #echo \~$(df -h | grep /dev/nvme0n1p4 | sed "s/\/dev\/nvme0n1p4 *[0-9]*.[0-9]*. *[0-9]*.[0-9]*. *//" | sed "s/ .*//") -echo $(df -h -x=used /dev/mapper/system-root | sed '1d' | awk '{print $4}') +echo  $(df -h -x=used /dev/mapper/artix-root | sed '1d' | awk '{print $4}'| sed 's/[^0-9]*//g') echo "$delim" diff --git a/stuff/scripts/system/url-handler.sh b/stuff/scripts/system/url-handler.sh index b5a1a3a..5f626ce 100755 --- a/stuff/scripts/system/url-handler.sh +++ b/stuff/scripts/system/url-handler.sh @@ -9,7 +9,7 @@ clipboard firefox " -choice=$(echo "$choices" | sed /^$/d | dmenu -i -p "$prompt_message") +choice=$(echo "$choices" | sed /^$/d | rofi -dmenu "$prompt_message") if [ "$choice" == "clipboard" ]; then printf "$url" | xclip -selection clipboard