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

How to chenge the default @omz link? #31

Closed
ysl2 opened this issue Jun 12, 2021 · 4 comments
Closed

How to chenge the default @omz link? #31

ysl2 opened this issue Jun 12, 2021 · 4 comments

Comments

@ysl2
Copy link

ysl2 commented Jun 12, 2021

Hi, I come from China, the original oh-my-zsh link address(https://github.com/ohmyzsh/ohmyzsh) is slow beacuse China's country network firewall.
So I was wondering if zpm cound change the default @omz address?
I always use https://hub.fastgit.org/ to replace https://github.com/. hub.fastgit.org is a China mirror of github.

Thanks! :-)

@grigorii-horos
Copy link
Member

Hello @ysl2 . Maybe I can help you in another way.

For example: I can add support for an env variable who will be used to replace github.com in all urls?

Like:

export GITHUB_MIRROR='https://some.site.ch/'
zpm load some/plugin # Plugin will be loaded from https://some.site.ch/some/plugin, not from https://github.com/some/plugin

If this is a good solution, can you provide the best github mirror in China? Or hub.fastgit.org is the best?

@grigorii-horos
Copy link
Member

@ysl2 Initial implementation done in next branch. See: https://github.com/zpm-zsh/zpm/tree/next#configuration

@ysl2
Copy link
Author

ysl2 commented Jun 14, 2021

@ysl2 Initial implementation done in next branch. See: https://github.com/zpm-zsh/zpm/tree/next#configuration

Sorry for my late reply, here are some mirror format:


Original(https):

https://github.com/zpm-zsh/zpm.git

Substitute(https):

https://hub.fastgit.org/zpm-zsh/zpm.git

https://ghproxy/https://github.com/zpm-zsh/zpm.git


Original(ssh):

git@github.com:zpm-zsh/zpm.git

Substitute(ssh):

git@git.zhlh6.com:zpm-zsh/zpm.git


Original(raw):

https://raw.githubusercontent.com/{user}/{repo}/{branch}/{file}

Substitute(raw):

https://cdn.jsdelivr.net/gh/{user}/{repo}/{file}

@ysl2
Copy link
Author

ysl2 commented Jun 14, 2021

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

No branches or pull requests

2 participants