Skip to content

Add --use-cache option #280

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

Closed
egoist opened this issue Dec 29, 2016 · 10 comments
Closed

Add --use-cache option #280

egoist opened this issue Dec 29, 2016 · 10 comments

Comments

@egoist
Copy link
Collaborator

egoist commented Dec 29, 2016

Maybe we can download the repo to ~/.vue-cli/repos instead of a random temp path so that we can use cached version later. 🤔

How do you think?

@kazupon
Copy link
Member

kazupon commented Dec 29, 2016

I think it's good idea. 👍

@posva
Copy link
Member

posva commented Dec 29, 2016

I think this should just be by default and always check. This would also enable offline usage

@likun7981
Copy link

likun7981 commented Jan 3, 2017

Use cache by default , --remote option to download remote repo, this may be better

@defcc
Copy link
Member

defcc commented Jan 3, 2017

Good idea.

@posva
Copy link
Member

posva commented Jan 3, 2017

@likun7981 I actually think we should always check and add an option for offline like yarn's --offline (only works if cached, no remote check). There's also --prefer-offline (download if no cache) which I don't think it's necessary since we should always check for the newest version and cache it. If we use the cache by default and make users use the --remote option manually to update, a lot of people will forget. However, if we have a remote first strategy, it'll work out of the box.

we can even add a vue cache update to update all templates cached and vue cache clear. But I don't think this is necessary since they update automatically

@likun7981
Copy link

@posva your idea is nice , but sometimes , I just want to update the current one which I need .

@posva
Copy link
Member

posva commented Jan 4, 2017

@likun7981 That's what I was saying 😄 : vue init webpack test would try to update the cached version of the webpack template while vue init --offline webpack test would directly use the cached version

@likun7981
Copy link

Sorry , that’s my fault 😂 , I just didn't completely understand your meaning. I understand now.
I just only saw vue cache update to update all templates

@posva
Copy link
Member

posva commented Jan 4, 2017

@likun7981 😆 No worries. I was just thinking out loud. I think we shouldn't add a vue cache update command

@egoist
Copy link
Collaborator Author

egoist commented Jan 25, 2017

Any thoughts on #303 ?

@egoist egoist closed this as completed in ff67bd2 Jan 26, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants