Rewrite whole app #1000
Labels
No labels
⌚ Major-release
⌚ Minor-release
⚔️ Wontfix
⚙️ CI
⛏️ Breaking
✨ Duplicate
❌ Invalid
❓ Question
❤️ Support
➡️ Frontport
➡️ Needs-frontport
🔙 Backport
💭 Brainstorming
🐛 Bug
🔭 Cannot-reproduce
🧺 Cleanup
🧾 Confirmed
💬 Discussion
📄 Documentation
🎯 Enhancement
🩹 External-dependecy
📱 F-droid
🎉 Feature
👋 Good-first-issue
🤾 Google-play
🔙 Has-backport
🚀 Improvement
🚨 Investigate
🌠 Long-term
🔙 Needs-backport
🧺 Needs-cleanup
📡 Needs-feedback
📈 Performance
📌 Priority-critical
📌 Priority-high
📍 Priority-low
📍 Priority-medium
🥑 Ready
🪒 Refactor
🔙 Regression
📸 Release
🔒 Security
💡 Suggestion
🧪 Testing
🌐 Translation
💻 UI/UX
🪜 Upstream
🟦 Website
🙇♂️ Needs-help
🛰️ API-dependency
🛡️ Blocked
🏗️ Build
🗒️ Changelog
🗄️ Repository
🗓️ Summary
No milestone
No project
No assignees
3 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: gitnex/GitNex#1000
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
This is issue #1000 :)
I know that it may be hard to understand why I suggest to rewrite the whole app (even if you prabably would copy most code), and I don't think it's something that will happen in the near future. However, GitNex has lot of old, duplicated code (e.g. #972 (comment)) and some issues with the architecture and structure (e.g. #826, #876, #885) or other issues/features that would require a big refactor (e.g. #354, #907).
I would suggest rewriting the app (at any point in the future) using:
tea4j-autodeploy
I tend to agree with most parts, but as in software industry for long I know there is no such thing without duplicate code, refactors etc.
There is always room for improvements in every line of code. But the real question is not about it should be done that way. The real question is, is it broken for long, does it need a fix?
So as you slowly grow, things get complicated and some time out of hand.
So let's hope one day we rewrite this app, which to be honest with you I don't see it in far future.. haha
Your points:
By that I meant it depends on resources and time. Rewriting the current code would really need some time and going. Not an easy task.
Of course that needs a lot of time, but probably you could copy much code of the current app (and that's why I added
Long-term
andPriority-low
labels)Maybe I don't understand your point, but of course you can't change the base class of the activities and rename them to
...Fragment
. It's a bit more work.I'm fine with this, even if Jetbrains invented it and not Google (but Java is although simpler to understand for most people)
Of course (and unfortunately) a rewrite would only be helpful for a few years until there are so many changes that you have to re-rewrite it.
My bad, yes JetBrains not Google.
Yes, will need time. But we can slowly do it one by one. Like I do the refactors for pagination in every release.
True.
I thought a bit about this and I think I can split this a bit into single points:
tea4j-autodeploy
NavGraph
library, which is used to control navigation for fragments (the current MainActivity just changes the fragment if you click one of the items in the side bar, but this NavGraph is easier and makes the code more readable (docs: https://developer.android.com/jetpack/androidx/releases/navigation, https://developer.android.com/reference/androidx/navigation/NavGraph; maybe I'll see if I can get a refactor for this into 4.2.0 or any later release).Maybe a whole rewrite isn't the best idea, but it would be good to refactor smaller or bigger things from time to time.
I'm aware of that duplicated code thing ... I suggest another route: migrating one big issue at a time. and if posible enforce things with linters.
so lets say ativity -> fragments ... after a release before moving on with new features etc ... sit down, create a extra branch and collaborate on that to make that migration. if done, merge it and keep on with normal bussines?
this way, work load is distributed and you can still deliver value :)
#1034 is a nice example ☝️
is transition mostly done or do we have to keep this open?
Yes, mostly as discussed in chat.
Not sure if @qwerty287 want to add anything else.
Not really. Let's close it for now.