Skip to content
New issue

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

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

Already on GitHub? # to your account

Installing Bash-My-GCP in zsh #11

Open
chronograph3r opened this issue Feb 17, 2020 · 8 comments
Open

Installing Bash-My-GCP in zsh #11

chronograph3r opened this issue Feb 17, 2020 · 8 comments

Comments

@chronograph3r
Copy link

Hi, Please consider this a feature request or a How to do guide.

Please let us know how to use this for oh-my-Zsh,

@mcrmonkey
Copy link
Owner

Thanks for raising this! zsh support is something that was already on my radar just not had the time to look in to it properly yet

i did a quick test with this just now and I noticed when I pulled this in to a default oh-my-zsh install the gcp command already taken by the git cherrypick alias provided by the built in git module so there may be some changes need to make that work right

@chronograph3r
Copy link
Author

Looking forward to that 😄

@Rahulsharma0810
Copy link

@mcrmonkey are you moving forward with this?

mcrmonkey added a commit that referenced this issue Jun 29, 2020
This is for issue #11

* Patched loader for shared functions as `${BASH_SOURCE}` isn't a thing in
zsh

* Created hook for `oh-my-zsh` plugin system to call
@mcrmonkey
Copy link
Owner

I've created a branch with the changes needed to get this running via oh-my-zsh

You'll need to pull the test branch in to your oh-my-zsh plugins directory and add it to your plugins list to use it:

cd ~/.oh-my-zsh/plugins
git clone -b bmg-zsh https://github.com/mcrmonkey/bash-my-gcp

Then add it to your plugin list in ~/.zshrc

Note: The git plugin has already claimed the gcp function name so gcp function isn't going to work for the moment if you're also loading the git plugin

@mcrmonkey
Copy link
Owner

@chronograph3r, @Rahulsharma0810 If you have the time I'd appreciate any testing you can do with this

@richtong
Copy link

wow this is great will try it rn, gcloud is crazy long

@richtong
Copy link

OK, I don't know if this project is still alive, but I tried to use zinit with it and it failed, looks like the paths are not quite right for that installation. It works fine with a manual oh-my-zsh installation. https://github.com/zdharma-continuum/zinit

@richtong
Copy link

You can try it yourself with these lines:

# to pick up the branch
zinit ice bpick"bmg-zsh"
zinit light mcrmonkey/bash-my-gcp

The error is in the loader.sh saying

Downloading mcrmonkey/bash-my-gcp…

Cloning into '/Users/rich/.zinit/plugins/mcrmonkey---bash-my-gcp'...
▃ ███████████ OBJ: 100, PACK: 139/139, COMPR: 100%, REC: 100%, RES: 100%
Note: Compiling: loader.sh… OK.
/Users/rich/.zinit/plugins/mcrmonkey---bash-my-gcp/loader.sh:4: no matches found: ./lib/*-functions

In looking at this I think the path is not quite right

# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

No branches or pull requests

4 participants