Add vars and logic for home-dir clean-up, minor obsidian changes
This commit is contained in:
@@ -1,8 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
# adjust settings in src_files/shell/profile, src_files/shell/rc, or otherwise
|
||||
# for programs i actually use or programs which have simple enough configuration
|
||||
# options to follow the XDG spec.
|
||||
# this script is for everything else, which i just want to wipe out quickly.
|
||||
|
||||
rm -rf "$HOME"/.bash*
|
||||
@@ -32,6 +32,9 @@ echo "---- making system dirs ----------------"
|
||||
! [ -d "$DIR_REAPER_PORTABLE_LINUX" ] && mkdir -p "$DIR_REAPER_PORTABLE_LINUX"
|
||||
! [ -d "$DIR_REAPER_PORTABLE_MACOS" ] && mkdir -p "$DIR_REAPER_PORTABLE_MACOS"
|
||||
|
||||
# echo "---- making system or home-cleanup files"
|
||||
# ! [ -d "$(dirname $HISTFILE)" ] && mkdir -p "$(dirname $HISTFILE)"
|
||||
# ! [ -r "$HISTFILE" ] && touch "$HISTFILE"
|
||||
# xdg spec and/or clean-up of home dir
|
||||
echo "---- making xdg-spec/home-clean-up files"
|
||||
! [ -d "$XDG_CONFIG_HOME/cups" ] && mkdir -p "$XDG_CONFIG_HOME/cups"
|
||||
! [ -d "$XDG_DATA_HOME/irb" ] && mkdir -p "$XDG_DATA_HOME/irb"
|
||||
! [ -d "$XDG_DATA_HOME/ncmpcpp" ] && mkdir -p "$XDG_DATA_HOME/ncmpcpp"
|
||||
! [ -d "$XDG_CACHE_HOME/maven/repository" ] && mkdir -p "$XDG_CACHE_HOME/maven/repository"
|
||||
|
||||
1
src_files/.config/irb/irbrc
Normal file
1
src_files/.config/irb/irbrc
Normal file
@@ -0,0 +1 @@
|
||||
IRB.conf[:HISTORY_FILE] ||= File.join(ENV["XDG_DATA_HOME"], "irb", "history")
|
||||
1
src_files/.config/maven/settings.xml
Normal file
1
src_files/.config/maven/settings.xml
Normal file
@@ -0,0 +1 @@
|
||||
<localRepository>${env.XDG_CACHE_HOME}/maven/repository</localRepository>
|
||||
3
src_files/.config/ncmpcpp/config
Normal file
3
src_files/.config/ncmpcpp/config
Normal file
@@ -0,0 +1,3 @@
|
||||
ncmcpp_directory = "$XDG_DATA_HOME/ncmpcpp"
|
||||
lyrics_directory = "$DIR_MUSIC/.lyrics"
|
||||
mpd_music_dir = "$DIR_MUSIC"
|
||||
@@ -1,66 +0,0 @@
|
||||
initial_screen = "library"
|
||||
library_tabs = ["playlists", "albums", "artists", "browse"]
|
||||
|
||||
[keybindings]
|
||||
"Space" = "playpause"
|
||||
|
||||
##########################################################################################
|
||||
# theme
|
||||
|
||||
# [theme] # from eltoncezar, similar to official spotify colors
|
||||
# background = "#191414"
|
||||
# primary = "#FFFFFF"
|
||||
# secondary = "light black"
|
||||
# title = "#1DB954"
|
||||
# playing = "#1DB954"
|
||||
# playing_selected = "#1ED760"
|
||||
# playing_bg = "#191414"
|
||||
# highlight = "#FFFFFF"
|
||||
# highlight_bg = "#484848"
|
||||
# error = "#FFFFFF"
|
||||
# error_bg = "red"
|
||||
# statusbar = "#191414"
|
||||
# statusbar_progress = "#1DB954"
|
||||
# statusbar_bg = "#1DB954"
|
||||
# cmdline = "#FFFFFF"
|
||||
# cmdline_bg = "#191414"
|
||||
# search_match = "light red"
|
||||
|
||||
[theme] # from wojciech-zurek, tokyonight
|
||||
background = "#1a1b26"
|
||||
primary = "#9aa5ce"
|
||||
secondary = "#414868"
|
||||
title = "#9ece6a"
|
||||
playing = "#7aa2f7"
|
||||
playing_selected = "#bb9af7"
|
||||
playing_bg = "#24283b"
|
||||
highlight = "#c0caf5"
|
||||
highlight_bg = "#24283b"
|
||||
error = "#414868"
|
||||
error_bg = "#f7768e"
|
||||
statusbar = "#ff9e64"
|
||||
statusbar_progress = "#7aa2f7"
|
||||
statusbar_bg = "#1a1b26"
|
||||
cmdline = "#c0caf5"
|
||||
cmdline_bg = "#24283b"
|
||||
search_match = "#f7768e"
|
||||
|
||||
# [theme] # from clooles, uses defaults/primary, supports transparency, for dynamic themes
|
||||
# background = "default"
|
||||
# primary = "foreground"
|
||||
# secondary = "light black"
|
||||
# title = "primary"
|
||||
# playing = "primary"
|
||||
# playing_selected = "primary"
|
||||
# playing_bg = "primary"
|
||||
# highlight = "#FFFFFF"
|
||||
# highlight_bg = "#484848"
|
||||
# error = "#FF0000"
|
||||
# error_bg = "red"
|
||||
# statusbar = "primary"
|
||||
# statusbar_progress = "primary"
|
||||
# statusbar_bg = "primary"
|
||||
# cmdline = "default"
|
||||
# cmdline_bg = "primary"
|
||||
# search_match = "light red"
|
||||
|
||||
@@ -15,5 +15,6 @@
|
||||
"showInlineTitle": false,
|
||||
"readableLineLength": true,
|
||||
"strictLineBreaks": true,
|
||||
"livePreview": false
|
||||
"livePreview": false,
|
||||
"propertiesInDocument": "hidden"
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"theme": "obsidian",
|
||||
"accentColor": "#2f930e",
|
||||
"baseFontSize": 18,
|
||||
"baseFontSize": 20,
|
||||
"enabledCssSnippets": [],
|
||||
"translucency": false,
|
||||
"cssTheme": "Obsidian gruvbox"
|
||||
|
||||
@@ -1,7 +1,4 @@
|
||||
{
|
||||
"markdown:toggle-preview": [
|
||||
{ "modifiers": [ "Ctrl", "Shift" ], "key": "E" }
|
||||
],
|
||||
"switcher:open": [
|
||||
{ "modifiers": [ "Ctrl" ], "key": "F" }
|
||||
],
|
||||
@@ -11,10 +8,16 @@
|
||||
"app:toggle-right-sidebar": [
|
||||
{ "modifiers": [ "Ctrl", "Shift" ], "key": "F" }
|
||||
],
|
||||
"markdown:toggle-preview": [
|
||||
{ "modifiers": [ "Ctrl", "Shift" ], "key": "E" }
|
||||
],
|
||||
"editor:toggle-readable-line-length": [
|
||||
{ "modifiers": [ "Ctrl", "Shift" ], "key": "R" }
|
||||
],
|
||||
"file-explorer:reveal-active-file": [
|
||||
{ "modifiers": [ "Ctrl", "Shift" ], "key": "N" }
|
||||
],
|
||||
"app:open-settings": [
|
||||
{ "modifiers": [ "Ctrl", "Shift" ], "key": "O" }
|
||||
]
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
[ -r "$HOME/.config/profile" ] && . "$HOME/.config/profile"
|
||||
[ -r "$XDG_CONFIG_HOME/rc" ] && . "$XDG_CONFIG_HOME/rc"
|
||||
|
||||
# overwrite PS1 here, since zsh decided to use different special chars
|
||||
export PS1="%n@%m ${PWD##*/} %# "
|
||||
# overwrite PS1 here, since zsh to use different special chars
|
||||
export PS1="%n@%m %1~ %# "
|
||||
|
||||
3
src_files/.local/bin/bundle
Executable file
3
src_files/.local/bin/bundle
Executable file
@@ -0,0 +1,3 @@
|
||||
#!/bin/sh
|
||||
|
||||
mise exec ruby@$MISE_RUBY_VERSION -- bundle "$@"
|
||||
3
src_files/.local/bin/irb
Executable file
3
src_files/.local/bin/irb
Executable file
@@ -0,0 +1,3 @@
|
||||
#!/bin/sh
|
||||
|
||||
mise exec ruby@$MISE_RUBY_VERSION -- irb "$@"
|
||||
25
src_files/.local/scripts/home-dir-clean.sh
Executable file
25
src_files/.local/scripts/home-dir-clean.sh
Executable file
@@ -0,0 +1,25 @@
|
||||
#!/bin/sh
|
||||
|
||||
# adjust settings in src_files/shell/profile, src_files/shell/rc, or otherwise
|
||||
# where feasible. if not feasible and i don't care about the programs, just
|
||||
# wipe out the associated files.
|
||||
|
||||
################
|
||||
# clean up and re-org
|
||||
|
||||
[ -d "$HOME/.cups" ] &&
|
||||
mv "$HOME"/.cups/* "$XDG_CONFIG_HOME/cups/" &&
|
||||
rmdir "$HOME/.cups"
|
||||
|
||||
################
|
||||
# wipe out
|
||||
|
||||
rm -rf "$HOME"/.bash*
|
||||
rm -rf "$HOME"/.sh_history # HISTFILE should be used instead, so just wipe this if present
|
||||
rm -rf "$HOME"/.python_history # since v 3.13.0a3, respects PYTHON_HISTORY; just wipe this
|
||||
rm -rf "$HOME"/.ruby-lsp # not sure if i want this or not, just delete for now
|
||||
rm -rf "$HOME"/.vim* # using neovim, so if any vim stuff is made, delete it
|
||||
|
||||
[ -d "$HOME/Public" ] && sudo rm -rf "$HOME/Public" # apple
|
||||
[ -d "$HOME/Documents" ] && sudo rm -rf "$HOME/Documents" # apple
|
||||
|
||||
@@ -3,9 +3,6 @@ export BROWSER='brave'
|
||||
export EDITOR='nvim'
|
||||
export TERMINAL='kitty'
|
||||
|
||||
# set ENV for ksh/oksh (should be ignored by zsh and bash)
|
||||
export ENV="$HOME/.config/ksh/kshrc"
|
||||
|
||||
# env vars used for my organization structure
|
||||
export DIR_HOME_BOX="$HOME/dbox"
|
||||
export DIR_NOTES="$DIR_HOME_BOX/notes"
|
||||
@@ -32,6 +29,9 @@ export XDG_DATA_DIRS="/usr/local/share:/usr/share"
|
||||
export DIR_THEME_SETTINGS="$XDG_CONFIG_HOME/zz-this-box/themes"
|
||||
export DEFAULT_THEME_NAME="gruvbox"
|
||||
|
||||
# ksh/oksh
|
||||
export ENV="$HOME/.config/ksh/kshrc" # ENV var should be ignored by zsh and bash
|
||||
|
||||
# zsh
|
||||
export ZDOTDIR="$XDG_CONFIG_HOME/zsh" # may already be set, set anyway
|
||||
|
||||
@@ -52,6 +52,20 @@ export DIR_REAPER_PORTABLE_LINUX="$DIR_USER_OPT/reaper-portable/linux"
|
||||
export DIR_REAPER_PORTABLE_MACOS="$DIR_USER_OPT/reaper-portable/macos"
|
||||
|
||||
# xdg spec and/or clean-up of home dir
|
||||
export __CF_USER_TEXT_ENCODING="0x0:0x0" # TODO: does this actually accomplish anything?
|
||||
MAC_USER_ID=`id -u` export __CF_USER_TEXT_ENCODING="`printf '0x%x' $MAC_USER_ID`:0x0:0x0"
|
||||
export ANDROID_USER_HOME="$XDG_DATA_HOME/android"
|
||||
export BUNDLE_USER_CONFIG="$XDG_CONFIG_HOME/bundle"
|
||||
export BUNDLE_USER_CACHE="$XDG_CACHE_HOME/bundle"
|
||||
export BUNDLE_USER_PLUGIN="$XDG_DATA_HOME/bundle"
|
||||
export GNUPGHOME="$XDG_DATA_HOME/gnupg"
|
||||
export HISTFILE="$XDG_STATE_HOME/sh_history"
|
||||
export IRBRC="$XDG_CONFIG_HOME/irb/irbrc"
|
||||
export LESSHISTFILE="$XDG_STATE_HOME/lesshst"
|
||||
export LESSKEYIN="$XDG_CONFIG_HOME/lesskey"
|
||||
export NPM_CONFIG_CACHE="$XDG_CACHE_HOME/npm"
|
||||
export NPM_CONFIG_INIT_MODULE="$XDG_CONFIG_HOME/npm/config/npm-init.js"
|
||||
export NPM_CONFIG_TMP="$XDG_RUNTIME_DIR/npm"
|
||||
export NPM_CONFIG_USERCONFIG="$XDG_CONFIG_HOME/npm/npmrc"
|
||||
export PYTHON_HISTORY="$XDG_STATE_HOME/python_history"
|
||||
export SHELL_SESSIONS_DISABLE=1 # this may only apply for zsh on macOS
|
||||
|
||||
|
||||
@@ -69,4 +69,5 @@ export DEVKITARM=/opt/devkitpro/devkitARM
|
||||
|
||||
# xdg spec and/or clean-up of home dir
|
||||
alias adb="HOME='$XDG_DATA_HOME/android' adb"
|
||||
alias mvn="mvn -gs $XDG_CONFIG_HOME/maven/settings.xml"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user