Skip to content

Commit

Permalink
feat: further enhance copy and paste utilities
Browse files Browse the repository at this point in the history
  • Loading branch information
pascal-zarrad committed Mar 26, 2024
1 parent a93a30e commit ceb81b1
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
11 changes: 11 additions & 0 deletions lib/plugin_api.sh
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,17 @@ function apply_plugin() {
fi
}

# Function that checks if zplug oh-my-zsh lib is loaded or not
# and then adds the lib to the .zshrc
#
# @param $1 The lib to add to the .zshrc
function apply_ohmyzsh_lib() {
zplug_lib="$1"
if ! grep -q "zplug \"lib/${zplug_lib}\", from:oh-my-zsh" "${ZSHRC_PATH}" ; then
write_zshrc "zplug \"lib/${zplug_lib}\", from:oh-my-zsh"
fi
}

# Function that checks if zplug oh-my-zsh plugin is loaded or not
# and then adds the plugin to the .zshrc
#
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,7 @@
# Email : [email protected]
#==================================================================

apply_ohmyzsh_lib "clipboard"
apply_ohmyzsh_plugin "copypath"
apply_ohmyzsh_plugin "copybuffer"
apply_ohmyzsh_plugin "copyfile"

0 comments on commit ceb81b1

Please sign in to comment.