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

Upgrade at will #11

Merged
merged 4 commits into from
Jun 19, 2020
Merged

Upgrade at will #11

merged 4 commits into from
Jun 19, 2020

Conversation

PaulDance
Copy link
Contributor

@PaulDance PaulDance commented Jun 18, 2020

Currently, the only way to run the upgrade of the custom themes and plugins is
to let time pass so the time check may be triggered by the UPDATE_ZSH_DAYS
configuration variable's delay. As it is in days only, one may run the upgrade
every day at most, which is sufficient really, but if an upgrade fails for whatever
reason, then it would convenient to do it again right after.

Therefore, two small modifications are proposed here:

  • Make the upgrade function public
  • Add an alias to upgrade everything at once

The first one is the most important one, while the second is proposed in order
to complete it further so it can be a bit more convenient. The names used may
be subject to discussion of course. Let me know your opinion.

I am not really able to test if it is 100% compatible with all types of configuration
neither if it is usable outside of a loaded OhMyZsh environment, but I don't
know if that is even possible. So could you guide me in this regard ?

Thanks in advance.

Previously, one could only use this plugin when the automatic ZSH update
days configuration value triggered the time check, so at most once a day.
This commit makes the core function _upgrade_custom public and changes
its name to upgrade_oh_my_zsh_custom. This way, one may check for
updates as regularly as desired, while keeping the time trigger active.
Also, the chosen name is not too far from the OhMyZsh upgrade function.

Signed-off-by: Paul Mabileau <[email protected]>
This commit introduces a small alias that enables one to run the OhMyZsh,
custom plugins and custom themes in one go. It is called upgrade_ohl_my_zsh
in order to be even closer to the OhMyZsh upgrade function's name, while
still making sort of a sense: 'ohl' = 'all'.

Signed-off-by: Paul Mabileau <[email protected]>
This adds a small description of the added functionalities to the
README.

Signed-off-by: Paul Mabileau <[email protected]>
@tamcore
Copy link
Owner

tamcore commented Jun 18, 2020

@PositivePaulo Thank you for this contribution! Me merging another PR introduced merge conflicts here. Would you be so kind to resolve them? I'll merge this PR then as well :)

@PaulDance
Copy link
Contributor Author

@tamcore You are most welcome! Obviously I did this for my own benefit as well, but I am glad it can be shared.
I resolved the conflicts in the last merge commit, you should now be able to merge and close this PR.

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