Compare commits
2 commits
f50a72b03b
...
9ecd9a7cc2
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9ecd9a7cc2 | ||
|
|
3cd3e38358 |
12 changed files with 306 additions and 199 deletions
|
|
@ -17,7 +17,7 @@ exec-once = waybar
|
|||
exec-once = clipse -listen
|
||||
exec-once = swaync
|
||||
exec-once = /usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1
|
||||
exec-once = /home/rafayahmad/eww/target/release/eww daemon
|
||||
exec-once = eww daemon
|
||||
|
||||
exec-once = hyprpaper && ~/dotfiles/scripts/currentWallpaperHyprlock.sh
|
||||
exec-once = /home/rafayahmad/dotfiles/scripts/brightnessWidget.sh
|
||||
|
|
@ -120,7 +120,7 @@ master {
|
|||
|
||||
gestures {
|
||||
# See https://wiki.hyprland.org/Configuring/Variables/ for more
|
||||
workspace_swipe = on
|
||||
gesture = 3, horizontal, workspace
|
||||
}
|
||||
|
||||
misc {
|
||||
|
|
|
|||
|
|
@ -1,28 +1,29 @@
|
|||
{
|
||||
"LuaSnip": { "branch": "master", "commit": "458560534a73f7f8d7a11a146c801db00b081df0" },
|
||||
"auto-session": { "branch": "main", "commit": "ee320d7a59c1dfe83df7c9d58150d9f194690d53" },
|
||||
"blink.cmp": { "branch": "main", "commit": "586ee87534f5bf65f1c8dea2d1da2a57e8cddd36" },
|
||||
"catppuccin": { "branch": "main", "commit": "fa42eb5e26819ef58884257d5ae95dd0552b9a66" },
|
||||
"auto-session": { "branch": "main", "commit": "3a895bace7d0260c8daac5bf5c84236765f00212" },
|
||||
"blink.cmp": { "branch": "main", "commit": "327fff91fe6af358e990be7be1ec8b78037d2138" },
|
||||
"catppuccin": { "branch": "main", "commit": "30fa4d122d9b22ad8b2e0ab1b533c8c26c4dde86" },
|
||||
"diffview.nvim": { "branch": "main", "commit": "4516612fe98ff56ae0415a259ff6361a89419b0a" },
|
||||
"fidget.nvim": { "branch": "main", "commit": "d9ba6b7bfe29b3119a610892af67602641da778e" },
|
||||
"fidget.nvim": { "branch": "main", "commit": "4d5858bd4c471c895060e1b9f3575f1551184dc5" },
|
||||
"flutter-tools.nvim": { "branch": "main", "commit": "65b7399804315a1160933b64292d3c5330aa4e9f" },
|
||||
"gitsigns.nvim": { "branch": "main", "commit": "93f882f7041a2e779addbd34943812ca66edef5a" },
|
||||
"gitsigns.nvim": { "branch": "main", "commit": "f780609807eca1f783a36a8a31c30a48fbe150c5" },
|
||||
"harpoon": { "branch": "harpoon2", "commit": "ed1f853847ffd04b2b61c314865665e1dadf22c7" },
|
||||
"image.nvim": { "branch": "master", "commit": "c40215d7d7d1d8c823ee9a77be1a894d5c8df41b" },
|
||||
"jupytext.nvim": { "branch": "main", "commit": "c8baf3ad344c59b3abd461ecc17fc16ec44d0f7b" },
|
||||
"lazy.nvim": { "branch": "main", "commit": "6c3bda4aca61a13a9c63f1c1d1b16b9d3be90d7a" },
|
||||
"lazydev.nvim": { "branch": "main", "commit": "2367a6c0a01eb9edb0464731cc0fb61ed9ab9d2c" },
|
||||
"lualine.nvim": { "branch": "master", "commit": "a94fc68960665e54408fe37dcf573193c4ce82c9" },
|
||||
"markview.nvim": { "branch": "main", "commit": "ec33f2aa333ca1d76f51847922578434d7aeadf7" },
|
||||
"mason-lspconfig.nvim": { "branch": "main", "commit": "bb3a17efc797c34c054463174e5522442576ebd8" },
|
||||
"mason.nvim": { "branch": "main", "commit": "8024d64e1330b86044fed4c8494ef3dcd483a67c" },
|
||||
"lazydev.nvim": { "branch": "main", "commit": "258d2a5ef4a3e3d6d9ba9da72c9725c53e9afcbd" },
|
||||
"lualine.nvim": { "branch": "master", "commit": "b8c23159c0161f4b89196f74ee3a6d02cdc3a955" },
|
||||
"markview.nvim": { "branch": "main", "commit": "e6b0f5aee8105adab6077509c46459812db4cffa" },
|
||||
"mason-lspconfig.nvim": { "branch": "main", "commit": "7f9a39fcd2ac6e979001f857727d606888f5909c" },
|
||||
"mason.nvim": { "branch": "main", "commit": "7dc4facca9702f95353d5a1f87daf23d78e31c2a" },
|
||||
"mini.nvim": { "branch": "main", "commit": "94cae4660a8b2d95dbbd56e1fbc6fcfa2716d152" },
|
||||
"molten-nvim": { "branch": "main", "commit": "a286aa914d9a154bc359131aab788b5a077a5a99" },
|
||||
"notebook.nvim": { "branch": "main", "commit": "e7145d5e905f74ac927aa45fe109adbdd9e9f340" },
|
||||
"nvim-lspconfig": { "branch": "master", "commit": "f47cd681d7cb6048876a2e908b6d8ba1e530d152" },
|
||||
"nvim-lspconfig": { "branch": "master", "commit": "1f7fbc34e6420476142b5cc85e9bee52717540fb" },
|
||||
"nvim-treesitter": { "branch": "master", "commit": "42fc28ba918343ebfd5565147a42a26580579482" },
|
||||
"nvim-web-devicons": { "branch": "master", "commit": "0422a19d9aa3aad2c7e5cca167e5407b13407a9d" },
|
||||
"plenary.nvim": { "branch": "master", "commit": "857c5ac632080dba10aae49dba902ce3abf91b35" },
|
||||
"snacks.nvim": { "branch": "main", "commit": "bc0630e43be5699bb94dadc302c0d21615421d93" },
|
||||
"nvim-web-devicons": { "branch": "master", "commit": "6e51ca170563330e063720449c21f43e27ca0bc1" },
|
||||
"otter.nvim": { "branch": "main", "commit": "c44d645f03ae96e2e3cdc37f92ecfa93a534b736" },
|
||||
"plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" },
|
||||
"snacks.nvim": { "branch": "main", "commit": "d67a47739dfc652cfcf66c59e929c704a854b37a" },
|
||||
"todo-comments.nvim": { "branch": "main", "commit": "304a8d204ee787d2544d8bc23cd38d2f929e7cc5" },
|
||||
"vim-sleuth": { "branch": "master", "commit": "be69bff86754b1aa5adcbb527d7fcd1635a84080" }
|
||||
}
|
||||
|
|
|
|||
|
|
@ -75,7 +75,7 @@ vim.keymap.set('n', '<leader>/', function()
|
|||
Snacks.picker.lines({ layout = 'select' })
|
||||
end, { desc = 'fuzzily search in current buffer' })
|
||||
|
||||
vim.keymap.set('n', '<leader>sp', '<cmd>SessionSearch<CR>', { desc = 'search sessions' })
|
||||
vim.keymap.set('n', '<leader>sp', '<cmd>AutoSession search<CR>', { desc = 'search sessions' })
|
||||
|
||||
|
||||
-- INFO: LSP
|
||||
|
|
@ -204,7 +204,7 @@ vim.keymap.set('n', '<leader>mo', ':MoltenEvaluateOperator<CR>', { silent = true
|
|||
vim.keymap.set('n', '<leader>ml', ':MoltenEvaluateLine<CR>', { silent = true, desc = 'evaluate line' })
|
||||
vim.keymap.set('v', '<leader>mv', ':<C-u>MoltenEvaluateVisual<CR>gv', { silent = false, desc = 'evaluate visual selection' })
|
||||
vim.keymap.set('n', '<leader>mc', ':MoltenReevaluateCell<CR>', { silent = false, desc = 'reevaluate cell' })
|
||||
vim.keymap.set('n', '<leader>me', ':noautocmd MoltenEnterOutput<CR>', { silent = true, desc = 'show/enter output' })
|
||||
vim.keymap.set('n', '<leader>me', ':noautocmd MoltenEnterOutput<CR>:noautocmd MoltenEnterOutput<CR>', { silent = true, desc = 'show/enter output' })
|
||||
vim.keymap.set('n', '<leader>mh', ':MoltenHideOutput<CR>', { silent = true, desc = 'hide output' })
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -47,6 +47,9 @@ vim.o.winborder = 'rounded'
|
|||
vim.opt.hlsearch = false
|
||||
vim.opt.wrap = false
|
||||
|
||||
vim.o.swapfile = false
|
||||
vim.o.undofile = false
|
||||
|
||||
vim.o.sessionoptions='blank,buffers,curdir,folds,help,tabpages,winsize,winpos,terminal,localoptions'
|
||||
-- Example for configring Neovim to load user-installed installed Lua rocks:
|
||||
package.path = package.path .. ';' .. vim.fn.expand('$HOME') .. '/.luarocks/share/lua/5.1/?/init.lua;'
|
||||
|
|
|
|||
|
|
@ -17,7 +17,6 @@ require('lazy').setup({
|
|||
'tpope/vim-sleuth', -- Detect tabstop and shiftwidth automatically
|
||||
{ 'folke/todo-comments.nvim', event = 'VimEnter', dependencies = { 'nvim-lua/plenary.nvim' }, opts = {} },
|
||||
|
||||
{ 'meatballs/notebook.nvim', opts = {} },
|
||||
-- { 'stevearc/dressing.nvim', opts = {}, },
|
||||
|
||||
-- 'ThePrimeagen/vim-be-good',
|
||||
|
|
@ -33,7 +32,7 @@ require('lazy').setup({
|
|||
require('config.plugins.snacks'),
|
||||
require('config.plugins.mini'),
|
||||
|
||||
require('config.plugins.languages.molten'),
|
||||
require('config.plugins.languages.notebook'),
|
||||
require('config.plugins.languages.flutter'),
|
||||
require('config.plugins.languages.markdown'),
|
||||
|
||||
|
|
|
|||
|
|
@ -1,27 +0,0 @@
|
|||
return {
|
||||
{
|
||||
'3rd/image.nvim',
|
||||
version = '1.1.0',
|
||||
build = false, -- so that it doesn't build the rock https://github.com/3rd/image.nvim/issues/91#issuecomment-2453430239
|
||||
opts = {
|
||||
backend = 'kitty', -- whatever backend you would like to use
|
||||
max_width = 100,
|
||||
max_height = 20,
|
||||
max_height_window_percentage = math.huge,
|
||||
max_width_window_percentage = math.huge,
|
||||
window_overlap_clear_enabled = true, -- toggles images when windows are overlapped
|
||||
window_overlap_clear_ft_ignore = { 'cmp_menu', 'cmp_docs', '' },
|
||||
}
|
||||
|
||||
},
|
||||
{
|
||||
'benlubas/molten-nvim',
|
||||
version = '^1.0.0', -- use version <2.0.0 to avoid breaking changes
|
||||
dependencies = { '3rd/image.nvim' },
|
||||
build = ':UpdateRemotePlugins',
|
||||
init = function()
|
||||
-- these are examples, not defaults. Please see the readme
|
||||
vim.g.molten_image_provider = 'image.nvim'
|
||||
end,
|
||||
}
|
||||
}
|
||||
121
.config/nvim/lua/config/plugins/languages/notebook.lua
Normal file
121
.config/nvim/lua/config/plugins/languages/notebook.lua
Normal file
|
|
@ -0,0 +1,121 @@
|
|||
-- Provide a command to create a blank new Python notebook
|
||||
-- note: the metadata is needed for Jupytext to understand how to parse the notebook.
|
||||
-- if you use another language than Python, you should change it in the template.
|
||||
local default_notebook = [[
|
||||
{
|
||||
"cells": [
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
""
|
||||
]
|
||||
}
|
||||
],
|
||||
"metadata": {
|
||||
"kernelspec": {
|
||||
"display_name": "Python 3",
|
||||
"language": "python",
|
||||
"name": "python3"
|
||||
},
|
||||
"language_info": {
|
||||
"codemirror_mode": {
|
||||
"name": "ipython"
|
||||
},
|
||||
"file_extension": ".py",
|
||||
"mimetype": "text/x-python",
|
||||
"name": "python",
|
||||
"nbconvert_exporter": "python",
|
||||
"pygments_lexer": "ipython3"
|
||||
}
|
||||
},
|
||||
"nbformat": 4,
|
||||
"nbformat_minor": 5
|
||||
}
|
||||
]]
|
||||
|
||||
local function new_notebook(filename)
|
||||
local path = filename .. ".ipynb"
|
||||
local file = io.open(path, "w")
|
||||
if file then
|
||||
file:write(default_notebook)
|
||||
file:close()
|
||||
vim.cmd("edit " .. path)
|
||||
else
|
||||
print("Error: Could not open new notebook file for writing.")
|
||||
end
|
||||
end
|
||||
|
||||
vim.api.nvim_create_user_command('NewNotebook', function(opts)
|
||||
new_notebook(opts.args)
|
||||
end, {
|
||||
nargs = 1,
|
||||
complete = 'file'
|
||||
})
|
||||
|
||||
return {
|
||||
{
|
||||
'3rd/image.nvim',
|
||||
version = '1.1.0',
|
||||
build = false, -- so that it doesn't build the rock https://github.com/3rd/image.nvim/issues/91#issuecomment-2453430239
|
||||
opts = {
|
||||
backend = 'kitty', -- whatever backend you would like to use
|
||||
max_width = 100,
|
||||
max_height = 20,
|
||||
max_height_window_percentage = math.huge,
|
||||
max_width_window_percentage = math.huge,
|
||||
window_overlap_clear_enabled = true, -- toggles images when windows are overlapped
|
||||
window_overlap_clear_ft_ignore = { 'cmp_menu', 'cmp_docs', '' },
|
||||
}
|
||||
|
||||
},
|
||||
{
|
||||
'benlubas/molten-nvim',
|
||||
version = '^1.0.0', -- use version <2.0.0 to avoid breaking changes
|
||||
dependencies = { '3rd/image.nvim' },
|
||||
build = ':UpdateRemotePlugins',
|
||||
init = function()
|
||||
-- these are examples, not defaults. Please see the readme
|
||||
vim.g.molten_image_provider = 'image.nvim'
|
||||
vim.g.molten_virt_text_output = true
|
||||
vim.g.molten_virt_lines_off_by_1 = true
|
||||
vim.g.molten_auto_open_output = false
|
||||
end,
|
||||
},
|
||||
{
|
||||
'GCBallesteros/jupytext.nvim',
|
||||
opts = {
|
||||
style = 'markdown',
|
||||
output_extension = 'md',
|
||||
force_ft = 'markdown'
|
||||
}
|
||||
},
|
||||
{
|
||||
'jmbuhr/otter.nvim',
|
||||
dependencies = {
|
||||
'nvim-treesitter/nvim-treesitter',
|
||||
},
|
||||
config = function ()
|
||||
local otter = require('otter')
|
||||
otter.setup()
|
||||
|
||||
vim.api.nvim_create_autocmd('BufEnter', {
|
||||
pattern = { '*.ipynb' },
|
||||
callback = function ()
|
||||
if not vim.b._molten_import_output then
|
||||
vim.b._molten_import_output = true
|
||||
vim.cmd('MoltenImportOutput')
|
||||
otter.activate({ 'python' })
|
||||
end
|
||||
end
|
||||
})
|
||||
vim.api.nvim_create_autocmd('BufWritePost', {
|
||||
pattern = { '*.ipynb' },
|
||||
callback = function ()
|
||||
vim.cmd('MoltenExportOutput!')
|
||||
end
|
||||
})
|
||||
|
||||
end
|
||||
}
|
||||
}
|
||||
|
|
@ -79,6 +79,8 @@ return {
|
|||
|
||||
['<c-h>'] = { 'toggle_hidden', mode = 'i' },
|
||||
['<c-l>'] = { 'toggle_ignored', mode = 'i' },
|
||||
|
||||
['<a-q>'] = { 'qflist', mode = 'i' },
|
||||
}
|
||||
}
|
||||
},
|
||||
|
|
|
|||
|
|
@ -52,7 +52,8 @@
|
|||
"widgets": [
|
||||
"inhibitors",
|
||||
"title",
|
||||
"dnd",
|
||||
"buttons-grid",
|
||||
"mpris",
|
||||
"notifications"
|
||||
],
|
||||
"widget-config": {
|
||||
|
|
@ -81,11 +82,18 @@
|
|||
"buttons-grid": {
|
||||
"actions": [
|
||||
{
|
||||
"label": "直",
|
||||
"label": "",
|
||||
"type": "toggle",
|
||||
"active": true,
|
||||
"command": "sh -c '[[ $SWAYNC_TOGGLE_STATE == true ]] && nmcli radio wifi on || nmcli radio wifi off'",
|
||||
"update-command": "sh -c '[[ $(nmcli radio wifi) == \"enabled\" ]] && echo true || echo false'"
|
||||
},
|
||||
{
|
||||
"label": "",
|
||||
"type": "toggle",
|
||||
"active": true,
|
||||
"command": "sh -c '[[ $SWAYNC_TOGGLE_STATE == true ]] && rfkill unblock bluetooth || rfkill block bluetooth'",
|
||||
"update-command": "sh -c '[[ $(rfkill list bluetooth | grep -c \"Soft blocked: no\") -eq 1 ]] && echo true || echo false'"
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3,20 +3,20 @@
|
|||
while true; do
|
||||
while "$(cat /home/rafayahmad/dotfiles/.config/eww/brightnessShow)"; do
|
||||
|
||||
activeWindows=$(/home/rafayahmad/eww/target/release/eww active-windows)
|
||||
activeWindows=$(eww active-windows)
|
||||
if [[ "$activeWindows" != *"brightnessWin"* ]] ; then
|
||||
echo "opening"
|
||||
/home/rafayahmad/eww/target/release/eww open brightnessWin
|
||||
eww open brightnessWin
|
||||
fi
|
||||
|
||||
echo false > /home/rafayahmad/.config/eww/brightnessShow
|
||||
sleep 1
|
||||
done
|
||||
|
||||
activeWindows=$(/home/rafayahmad/eww/target/release/eww active-windows)
|
||||
activeWindows=$(eww active-windows)
|
||||
if [[ "$activeWindows" == *"brightnessWin"* ]] ; then
|
||||
echo "closing"
|
||||
/home/rafayahmad/eww/target/release/eww close brightnessWin
|
||||
eww close brightnessWin
|
||||
fi
|
||||
|
||||
done
|
||||
|
|
|
|||
|
|
@ -1,2 +1,2 @@
|
|||
2025-08-13
|
||||
45
|
||||
2025-10-25
|
||||
10
|
||||
Loading…
Add table
Add a link
Reference in a new issue