Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

To use it in my zsh #32

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

To use it in my zsh #32

wants to merge 1 commit into from

Conversation

xviubu
Copy link

@xviubu xviubu commented Jun 18, 2013

When i use it in my zsh,I found some command conflicts,i guess others face this problem,
so i change all command to add prefix 'bm' .

@briancline
Copy link

I like the idea of allowing flexibility, but I also really like the one-letter default commands. Have you considered revising this patch to instead set a bashmarks prefix var (if one isn't already set in the sourcing environment), and defaulting it to an empty value to preserve the existing commands for everyone else?

Perhaps something like this:

BASHMARKS_DEFAULT_PREFIX=""
BASHMARKS_PREFIX=${BASHMARKS_PREFIX:-$BASHMARKS_DEFAULT_PREFIX}

function bashmarks_s {
    ...
}

alias ${BASHMARKS_PREFIX}s=bashmarks_s
...

Then, in your .zshrc, all you'd need is this:

export BASHMARKS_PREFIX="bm"
source ~/.local/bin/bashmarks.sh

@xviubu
Copy link
Author

xviubu commented Nov 10, 2013

I,ll try !

@bachya
Copy link

bachya commented May 15, 2014

The solution proposed by @briancline is a very elegant one. I've submitted a pull request, but I'm not sure how active this repo is anymore; in case you're interested, my fork has this update: https://github.com/bachya/bashmarks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants