: bharatvaj/dotfiles

Cross platform dotfiles for linux, mac and windows

commit 309d292441aec4dee795e687d2ebd3ef0f922663
parent 167ec2beb42fedfcc24bc85799c04d8cb64a4290
Author: Bharatvaj Hemanth <bharatvaj@yahoo.com>
Date: Mon, 13 Apr 2026 03:14:23 +0530

Disable annoying characters when finding sendmail

Add default path for songdl

Add tpm in functions
3 files changed, 17 insertions(+), 8 deletions(-)
diff --git a/.config/sh/functions b/.config/sh/functions
@@ -76,3 +76,12 @@ download() {
 	esac
 }
 
+tpm() {
+		case "$1" in
+			copy) shift; tpm-copy "$@" ;;
+			generate) shift; tpm-generate "$@" ;;
+			otp) shift; tpm-otp "$@" ;;
+			ls) tpm-ls ;;
+			*) command tpm "$@" ;;
+		esac
+}
diff --git a/.config/vim/plugin/plugin.vim b/.config/vim/plugin/plugin.vim
@@ -174,10 +174,10 @@ func! s:plugin_post_load()
         let g:notmuch_open_command = 'fzf'
         let g:notmuch_fzf_command = 'fzf --reverse'
         let g:notmuch_use_conversation_view = 1
-        let sendmail_path = systemlist('sed -n "s/^set sendmail=\(.*\)$/\1/p; $!d" ~/.mailrc')
-        if len(sendmail_path) > 0
-            "let g:notmuch_sendmail=sendmail_path[]
-        endif
+        "let sendmail_path = systemlist('sed -n "s/^set sendmail=\(.*\)$/\1/p; $!d" ~/.mailrc')
+        "if len(sendmail_path) > 0
+        "    "let g:notmuch_sendmail=sendmail_path[]
+        "endif
     endif
 
 endfunc
diff --git a/.local/bin/sh/songdl b/.local/bin/sh/songdl
@@ -1,11 +1,11 @@
 #!/bin/sh
 
-[ $# -ne 1 ] && echo "Usage: $0 <youtube-url>" && exit 1
+[ $# -ne 1 ] && echo 'Usage: songdl <youtube-url>' && exit 1
 
-: ${XDG_MUSIC_DIR:=$HOME/Music}
-cd "${XDG_MUSIC_DIR:?$XDG_MUSIC_DIR not found}"
+: ${XDG_MUSIC_HOME:=$HOME/Music}
+cd "${XDG_MUSIC_HOME:?$XDG_MUSIC_HOME not found}"
 
-song_name=$1
+song_name="$1"
 
 yt-dlp --extract-audio --audio-format mp3 "$song_name" --external-downloader aria2c