Refactor Version Checks #472

Merged
mmarif merged 11 commits from 6543/GitNex:refactor-versionCheck into master 2020-05-17 16:14:21 +00:00
Member

as title - finaly a GOOD solution :)

  • convert enum to class

  • remove range compare

  • create constructor for strings ( Version("1.1.2") )

  • refactor main compare function

  • UnitTests 🎉

close #489

as title - finaly a GOOD solution :) * [x] convert enum to class * [x] remove range compare * [x] create constructor for strings ( `Version("1.1.2")` ) * [x] refactor main compare function * [x] UnitTests :tada: close #489
Author
Member

rename to SemanticVersion

func: equal, less, higher

rename to SemanticVersion func: equal, less, higher
6543 added the
Refactor
Improvement
WIP
labels 2020-04-28 13:32:41 +00:00
6543 added this to the 3.0.0 milestone 2020-04-28 13:32:50 +00:00
6543 self-assigned this 2020-04-28 13:32:58 +00:00
6543 added
LGTM-need
and removed
WIP
labels 2020-05-08 23:06:00 +00:00
6543 added
Bug
and removed
Improvement
labels 2020-05-08 23:07:17 +00:00
mmarif requested changes 2020-05-09 07:04:59 +00:00
Dismissed
@ -25,3 +25,3 @@
import org.mian.gitnex.helpers.StaticGlobalVariables;
import org.mian.gitnex.helpers.Toasty;
import org.mian.gitnex.helpers.VersionCheck;
import org.mian.gitnex.helpers.Version;

Version name is too generic here. Can we use something like GiteaVersion or similar?

Version name is too generic here. Can we use something like GiteaVersion or similar?
mmarif marked this conversation as resolved
Owner

VersionTest has to be part of the code? in case yes it should not be there. Let me know I can help where to put them.

Also If I am not mistaken MainActivity has version check somewhere?

VersionTest has to be part of the code? in case yes it should not be there. Let me know I can help where to put them. Also If I am not mistaken MainActivity has version check somewhere?
Author
Member

VersionTest has to be part of the code ...

no and its not :)

Version name is too generic here

well this Version class can handle all kind of semantic Versions not only those from gitea, should I make it more specific?

> VersionTest has to be part of the code ... no and its not :) > Version name is too generic here well this Version class can handle all kind of semantic Versions not only those from gitea, should I make it more specific?
Owner

well this Version class can handle all kind of semantic Versions not only those from gitea, should I make it more specific?

Let's keep it as is for now.

> well this Version class can handle all kind of semantic Versions not only those from gitea, should I make it more specific? Let's keep it as is for now.
6543 requested review from mmarif 2020-05-16 13:25:20 +00:00
mmarif approved these changes 2020-05-17 16:10:40 +00:00
Dismissed
mmarif added
LGTM-done
and removed
LGTM-need
labels 2020-05-17 16:11:18 +00:00
Owner

Works. ?

Works. ?
mmarif merged commit 3de4dd9463 into master 2020-05-17 16:14:18 +00:00
6543 deleted branch refactor-versionCheck 2020-05-17 22:05:56 +00:00
This repo is archived. You cannot comment on pull requests.
No reviewers
No Milestone
No Assignees
2 Participants
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: gitnex/GitNex#472
No description provided.