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

Added check for update in any mandatory release of karmor CLI #251

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

TheRealSibasishBehera
Copy link
Contributor

Signed-off-by: sibashi fangedhamster3114@gmail.com

Fixes #249

the function checkForUpdates first finds the latest release that contains the keyword "mandatory" in its release notes
compared it with current version from selfupdate.GitSummary
If diffrent informs the user

@PrimalPimmy
Copy link
Member

Hey @TheRealSibasishBehera . Great work on this 🚀.
Could you show an image/gif that this feature is working? If tested.

@TheRealSibasishBehera
Copy link
Contributor Author

Screenshot from 2023-01-31 16-21-01

the first stdout The client is up to data is from CheckForUpdates()

For this feature to identify major updates , the release notes must have a keyword mandatory , i dont think this keyword is used in release notes till now .

On further releases we can add the mandatory keyword in case of a major update

If its alright i can add a unit test with a mock *RepositoryRelease , which have that keyword and test it.

@PrimalPimmy
Copy link
Member

PrimalPimmy commented Jan 31, 2023

@TheRealSibasishBehera i don't think a test would be necessary for this feature. As long as the keyword isn't case sensitive. If it is case sensitive, could you make it "MANDATORY" all caps?

@TheRealSibasishBehera
Copy link
Contributor Author

TheRealSibasishBehera commented Feb 1, 2023

@TheRealSibasishBehera i don't think a test would be necessary for this feature. As long as the keyword isn't case sensitive. If it is case sensitive, could you make it "MANDATORY" all caps?

@PrimalPimmy I have updated the code , please take a look

Copy link
Contributor

@nyrahul nyrahul left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is an incorrect PR. This PR implements the logic in its own binary. The aim of the task was to check whether a mandatory release exists in the github when someone calls karmor version and highlight that a mandatory upgrade is pending.

Signed-off-by: Sibasish Behera <fangedhamster3114@gmail.com>
Signed-off-by: Sibasish Behera <fangedhamster3114@gmail.com>
@TheRealSibasishBehera TheRealSibasishBehera requested review from nyrahul and removed request for PrimalPimmy and Ankurk99 February 24, 2023 08:00
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.

Check for karmor client if mandatory updates are required
3 participants