mirror of
https://github.com/js0ny/dotfiles.git
synced 2025-12-21 08:43:00 +00:00
sync: from macOS
This commit is contained in:
parent
9436322a73
commit
06ddd359a7
11 changed files with 113 additions and 10 deletions
|
|
@ -1,6 +1,7 @@
|
|||
#! /bin/bash
|
||||
mkdir -p $XDG_CONFIG_HOME/conda $XDG_CONFIG_HOME/git $XDG_CONFIG_HOME/ideavim $XDG_CONFIG_HOME/markdownlint $XDG_CONFIG_HOME/pip $XDG_CONFIG_HOME/neovide $XDG_CONFIG_HOME/powershell $XDG_CONFIG_HOME/vscode $XDG_CONFIG_HOME/NuGet $XDG_CONFIG_HOME/vim $XDG_CONFIG_HOME/tmux $XDG_CONFIG_HOME/npm $XDG_CONFIG_HOME/readline $XDG_CONFIG_HOME/ipython
|
||||
mkdir -p ~/.config/zellij # Not support XDG_CONFIG_HOME but same directory
|
||||
# Not support XDG_CONFIG_HOME but same directory
|
||||
mkdir -p ~/.config/zellij ~/.config/yazi ~/.config/glow
|
||||
# mkdir -p $WAKATIME_HOME
|
||||
# mkdir -p $XDG_STATE_HOME/vim/undo $XDG_STATE_HOME/vim/backup $XDG_STATE_HOME/vim/swap $XDG_STATE_HOME/vim/view
|
||||
mkdir -p $HOME/Obsidian
|
||||
|
|
@ -22,6 +23,9 @@ ln -sf $DOTFILES/common/zellij.config.kdl ~/.config/zellij/config.kdl
|
|||
# $DOTFILES/tools
|
||||
ln -sf $DOTFILES/tools/ipython $XDG_CONFIG_HOME/ipython
|
||||
ln -sf $DOTFILES/tools/nvim $XDG_CONFIG_HOME/nvim
|
||||
ln -sf $DOTFILES/tools/yazi/config/keymap.toml ~/.config/yazi/keymap.toml
|
||||
ln -sf $DOTFILES/tools/yazi/config/yazi.toml ~/.config/yazi/yazi.toml
|
||||
|
||||
|
||||
if [ $(uname) = "Darwin"]; then
|
||||
mkdir -p ~/.config/karabiner $XDG_CONFIG_HOME/skhd $XDG_CONFIG_HOME/yabai $XDG_CONFIG_HOME/sketchybar
|
||||
|
|
|
|||
|
|
@ -17,7 +17,6 @@ PLUGIN_DIR="$CONFIG_DIR/plugins"
|
|||
# https://felixkratz.github.io/SketchyBar/config/tricks#color-picker
|
||||
|
||||
sketchybar --bar position=top height=40 blur_radius=30 color=0x40000000
|
||||
|
||||
##### Changing Defaults #####
|
||||
# We now change some default values, which are applied to all further items.
|
||||
# For a full list of all available item properties see:
|
||||
|
|
@ -82,14 +81,22 @@ sketchybar --add item chevron left \
|
|||
# volume is registered. More info about the event system can be found here:
|
||||
# https://felixkratz.github.io/SketchyBar/config/events
|
||||
|
||||
sketchybar --add item clock right \
|
||||
sketchybar --add item clock center \
|
||||
--set clock update_freq=10 icon= script="$PLUGIN_DIR/clock.sh" \
|
||||
--add item volume right \
|
||||
--set volume script="$PLUGIN_DIR/volume.sh" \
|
||||
--subscribe volume volume_change \
|
||||
--add item battery right \
|
||||
--set battery update_freq=120 script="$PLUGIN_DIR/battery.sh" \
|
||||
--subscribe battery system_woke power_source_change
|
||||
--subscribe battery system_woke power_source_change \
|
||||
--add item apple_music right
|
||||
|
||||
sketchybar --add item music right
|
||||
sketchybar --set music \
|
||||
script="$PLUGIN_DIR/music.sh" \
|
||||
update_freq=5 \
|
||||
label.color=0xffd7ba7d \
|
||||
background.corner_radius=5
|
||||
|
||||
##### Force all scripts to run the first time (never do this in a script) #####
|
||||
sketchybar --update
|
||||
|
|
|
|||
|
|
@ -33,3 +33,4 @@ shift + alt - e : \
|
|||
shift + alt - i : \
|
||||
yabai -m window --resize right:20:0 ; \
|
||||
yabai -m window --resize left:20:0
|
||||
|
||||
|
|
|
|||
|
|
@ -31,13 +31,12 @@ yabai -m config \
|
|||
window_animation_easing ease_out_circ \
|
||||
window_opacity_duration 0.0 \
|
||||
active_window_opacity 1.0 \
|
||||
normal_window_opacity 0.90 \
|
||||
window_opacity off \
|
||||
normal_window_opacity 0.70 \
|
||||
window_opacity on \
|
||||
insert_feedback_color 0xffd75f5f \
|
||||
split_ratio 0.50 \
|
||||
split_type auto \
|
||||
auto_balance off \
|
||||
top_padding 12 \
|
||||
bottom_padding 12 \
|
||||
left_padding 12 \
|
||||
right_padding 12 \
|
||||
|
|
@ -48,4 +47,5 @@ yabai -m config \
|
|||
mouse_action2 resize \
|
||||
mouse_drop_action swap
|
||||
|
||||
|
||||
echo "yabai configuration loaded.."
|
||||
|
|
|
|||
|
|
@ -22,6 +22,8 @@ vim.api.nvim_create_autocmd("FileType", {
|
|||
pattern = "markdown",
|
||||
callback = function()
|
||||
set_markdown_keymaps(0)
|
||||
vim.opt_local.shiftwidth = 2
|
||||
vim.opt_local.tabstop = 2
|
||||
end,
|
||||
})
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,17 @@
|
|||
|
||||
return {
|
||||
{ import = "plugins.mod.lspconfig" },
|
||||
{ "MeanderingProgrammer/render-markdown.nvim" },
|
||||
-- {
|
||||
-- "OXY2DEV/markview.nvim",
|
||||
-- lazy = false, -- Recommended
|
||||
-- -- ft = "markdown" -- If you decide to lazy-load anyway
|
||||
--
|
||||
-- dependencies = {
|
||||
-- "nvim-treesitter/nvim-treesitter",
|
||||
-- "nvim-tree/nvim-web-devicons"
|
||||
-- }
|
||||
-- },
|
||||
{ "williamboman/mason.nvim", config = true },
|
||||
{
|
||||
"williamboman/mason-lspconfig.nvim",
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
return {
|
||||
"epwalsh/obsidian.nvim",
|
||||
version = "*", -- recommended, use latest release instead of latest commit
|
||||
lazy = true,
|
||||
lazy = false,
|
||||
ft = "markdown",
|
||||
-- Replace the above line with this if you only want to load obsidian.nvim for markdown files in your vault:
|
||||
-- event = {
|
||||
|
|
@ -21,7 +21,7 @@ return {
|
|||
workspaces = {
|
||||
{
|
||||
name = "personal",
|
||||
path = "/mnt/c/Users/citoy/Obsidian",
|
||||
path = "~/Obsidian",
|
||||
},
|
||||
},
|
||||
completion = {
|
||||
|
|
|
|||
69
tools/yazi/config/keymap.toml
Normal file
69
tools/yazi/config/keymap.toml
Normal file
|
|
@ -0,0 +1,69 @@
|
|||
# A TOML linter such as https://taplo.tamasfe.dev/ can use this schema to validate your config.
|
||||
# If you encounter any issues, please make an issue at https://github.com/yazi-rs/schemas.
|
||||
"$schema" = "https://yazi-rs.github.io/schemas/prepend_keymap.json"
|
||||
|
||||
[manager]
|
||||
|
||||
prepend_keymap = [
|
||||
|
||||
# Hopping
|
||||
{ on = "e", run = "arrow -1", desc = "Move cursor up" },
|
||||
{ on = "n", run = "arrow 1", desc = "Move cursor down" },
|
||||
{ on = "i", run = "enter", desc = "Enter the child directory" },
|
||||
{ on = "I", run = "forward", desc = "Go forward to the next directory" },
|
||||
|
||||
# Seeking
|
||||
{ on = "E", run = "seek -5", desc = "Seek up 5 units in the preview" },
|
||||
{ on = "N", run = "seek 5", desc = "Seek down 5 units in the preview" },
|
||||
|
||||
# Find
|
||||
{ on = "k", run = "find_arrow", desc = "Go to the next found" },
|
||||
{ on = "K", run = "find_arrow --previous", desc = "Go to the previous found" },
|
||||
|
||||
|
||||
]
|
||||
|
||||
[tasks]
|
||||
|
||||
prepend_keymap = [
|
||||
{ on = "e", run = "arrow -1", desc = "Move cursor up" },
|
||||
{ on = "n", run = "arrow 1", desc = "Move cursor down" },
|
||||
]
|
||||
|
||||
[select]
|
||||
|
||||
prepend_keymap = [
|
||||
{ on = "e", run = "arrow -1", desc = "Move cursor up" },
|
||||
{ on = "n", run = "arrow 1", desc = "Move cursor down" },
|
||||
]
|
||||
|
||||
[input]
|
||||
|
||||
prepend_keymap = [
|
||||
# Mode
|
||||
{ on = "l", run = "insert", desc = "Enter insert mode" },
|
||||
{ on = "L", run = [ "move -999", "insert" ], desc = "Move to the BOL, and enter insert mode" },
|
||||
{ on = "i", run = "move 1", desc = "Move forward a character" },
|
||||
{ on = "j", run = "forward --end-of-word", desc = "Move forward to the end of the current or next word" },
|
||||
]
|
||||
|
||||
[confirm]
|
||||
prepend_keymap = [
|
||||
{ on = "N", run = "close", desc = "Cancel the confirm" },
|
||||
|
||||
{ on = "e", run = "arrow -1", desc = "Move cursor up" },
|
||||
{ on = "n", run = "arrow 1", desc = "Move cursor down" },
|
||||
]
|
||||
|
||||
[completion]
|
||||
|
||||
prepend_keymap = [
|
||||
]
|
||||
|
||||
[help]
|
||||
|
||||
prepend_keymap = [
|
||||
# Navigation
|
||||
{ on = "e", run = "arrow -1", desc = "Move cursor up" },
|
||||
{ on = "n", run = "arrow 1", desc = "Move cursor down" },
|
||||
]
|
||||
2
tools/yazi/config/yazi.toml
Normal file
2
tools/yazi/config/yazi.toml
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
[manager]
|
||||
show_hidden = true
|
||||
|
|
@ -32,4 +32,3 @@ esac
|
|||
for file in $DOTFILES/tools/zsh/mod/*.zsh; do
|
||||
source $file
|
||||
done
|
||||
|
||||
|
|
|
|||
|
|
@ -58,6 +58,14 @@ fi
|
|||
if command -v az > /dev/null; then
|
||||
export AZURE_CONFIG_DIR="$XDG_DATA_HOME"/azure
|
||||
fi
|
||||
# Bun JS
|
||||
# mv ~/.bun $XDG_DATA_HOME/bun
|
||||
# ln -sf $XDG_DATA_HOME/bun/bin/bun ~/.local/bin/bun
|
||||
if command -v bun > /dev/null; then
|
||||
export BUN_INSTALL="$XDG_DATA_HOME"/bun
|
||||
export PATH="$BUN_INSTALL/bin:$PATH"
|
||||
[ -s "$BUN_INSTALL/_bun" ] && source "$BUN_INSTALL/_bun"
|
||||
fi
|
||||
# Cargo
|
||||
if command -v cargo > /dev/null; then
|
||||
export CARGO_HOME="$XDG_DATA_HOME"/cargo
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue