summaryrefslogtreecommitdiff
path: root/mut
diff options
context:
space:
mode:
Diffstat (limited to 'mut')
-rw-r--r--mut/aerospace/aerospace.toml10
-rwxr-xr-xmut/bin/pnsh-nvim3
-rw-r--r--mut/ghostty/config3
-rw-r--r--mut/neovim/lua/my/init.lua45
-rw-r--r--mut/nushell/config.nu8
5 files changed, 40 insertions, 29 deletions
diff --git a/mut/aerospace/aerospace.toml b/mut/aerospace/aerospace.toml
index c5e9a16..c11e5c5 100644
--- a/mut/aerospace/aerospace.toml
+++ b/mut/aerospace/aerospace.toml
@@ -92,8 +92,14 @@ automatically-unhide-macos-hidden-apps = false
cmd-shift-d = 'exec-and-forget source /etc/profile; PATH="$HOME/.local/bin:/opt/homebrew/bin:/opt/homebrew/sbin:$PATH" passmenu'
cmd-d = 'exec-and-forget source /etc/profile; PATH="$HOME/.local/bin:/opt/homebrew/bin:/opt/homebrew/sbin:$PATH" dmenu'
cmd-enter = '''exec-and-forget osascript -e '
- tell application "Ghostty"
- activate
+ tell application "System Events"
+ if exists application process "Ghostty" then
+ tell application process "Ghostty"
+ click menu item "New Window" of menu "File" of menu bar 1
+ end tell
+ else
+ tell application "Ghostty" to activate
+ end if
end tell'
'''
cmd-w = '''exec-and-forget osascript -e '
diff --git a/mut/bin/pnsh-nvim b/mut/bin/pnsh-nvim
index 07d09c0..30d8508 100755
--- a/mut/bin/pnsh-nvim
+++ b/mut/bin/pnsh-nvim
@@ -27,7 +27,8 @@ $" --workdir=($env | default $env.HOME PWD | get PWD)" +
# " --volume=/nix/store:/nix/store" +
$" --volume=/nix-config:/nix-config" +
$" --volume=($env.HOME)/.ssh:/root/.ssh" +
-$" --volume=($env | default "/var/run" XDG_RUNTIME_DIR | get XDG_RUNTIME_DIR)/docker.sock:/var/run/docker.sock"
+$" --volume=($env | default "/var/run" XDG_RUNTIME_DIR | get XDG_RUNTIME_DIR)/docker.sock:/var/run/docker.sock" +
+" --net=host"
)
(
diff --git a/mut/ghostty/config b/mut/ghostty/config
index 44a7aed..ea81f22 100644
--- a/mut/ghostty/config
+++ b/mut/ghostty/config
@@ -13,3 +13,6 @@ theme=GruvboxLuke
window-decoration=false
confirm-close-surface=false
macos-option-as-alt=true
+
+clipboard-read = allow
+clipboard-write = allow
diff --git a/mut/neovim/lua/my/init.lua b/mut/neovim/lua/my/init.lua
index 5703ed4..0c08504 100644
--- a/mut/neovim/lua/my/init.lua
+++ b/mut/neovim/lua/my/init.lua
@@ -422,40 +422,39 @@ function paste()
vim.fn.getregtype("")
}
end
-function xclip(lines)
- vim.system({ "nu", "--commands", "xclip -f -sel c | xclip"}, {stdin=lines, text=true}, nil)
-end
+-- function xclip(lines)
+-- vim.system({ "nu", "--commands", "xclip -f -sel c | xclip"}, {stdin=lines, text=true}, nil)
+-- end
function pbcopy(lines)
vim.system({ "nu", "--commands", "pbcopy"}, {stdin=lines, text=true}, nil)
end
-- Unix, Linux variants
-local fh, err = assert(io.popen("which xclip 2>/dev/null", "r"))
+local fh, err = assert(io.popen("which pbcopy 2>/dev/null", "r"))
if fh:read() then
vim.g.clipboard = {
- name = "Xclip Clipboard",
- copy = {
- ["+"] = xclip, ["*"] = xclip
+ name = 'pbcopy Clipboard',
+ copy = {
+ ['+'] = pbcopy,
+ ['*'] = pbcopy,
},
paste = {
- ["+"] = paste, ["*"] = paste
- }
+ ['+'] = paste,
+ ['*'] = paste,
+ },
}
else
- local fh, err = assert(io.popen("which pbcopy 2>/dev/null", "r"))
- if fh:read() then
- vim.g.clipboard = {
- name = 'pbcopy Clipboard',
- copy = {
- ['+'] = pbcopy,
- ['*'] = pbcopy,
- },
- paste = {
- ['+'] = paste,
- ['*'] = paste,
- },
- }
- end
+ vim.g.clipboard = {
+ name = 'OSC 52',
+ copy = {
+ ['+'] = require('vim.ui.clipboard.osc52').copy('+'),
+ ['*'] = require('vim.ui.clipboard.osc52').copy('*'),
+ },
+ paste = {
+ ['+'] = require('vim.ui.clipboard.osc52').paste('+'),
+ ['*'] = require('vim.ui.clipboard.osc52').paste('*'),
+ },
+ }
end
require("my.events")
require("my.packages")
diff --git a/mut/nushell/config.nu b/mut/nushell/config.nu
index a381700..ec9dc2d 100644
--- a/mut/nushell/config.nu
+++ b/mut/nushell/config.nu
@@ -1,6 +1,8 @@
-# if ($env | default "" DOCKER_NAME | get DOCKER_NAME | is-empty) {
-# try {pnsh-nvim}
-# }
+if ($env | default "" DOCKER_NAME | get DOCKER_NAME | is-empty) {
+ try {pnsh-nvim}
+} else {
+ use ~/Programming/Pionative/quickstart/.venv/bin/activate.nu
+}
# Nushell Config File
#
# version = "0.99.1"