-
Notifications
You must be signed in to change notification settings - Fork 202
get rid of the case statements because it needs maintenance #755
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
Conversation
Added some predicted LOS and Android versions, so that future compiling is not hindered
use lineage numbers to split between legacy and new build instead of maintaining a list of branches
select branch and android version without maintaining a list
fix space between variable and equal sign
fix space between variable and equal sign
cleanup
cleanup
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This doesn't seem to do any validation of $branch
. We currently display an error if a user specifies a branch that is not supported. I don't want to lost that. Maybe we could check against a list of supported branches (e.g. the branches listed at https://github.com/LineageOS/android/branches/all).
Thinking some more about this, I think we should do the following:
These changes would need to be implemented and tested before merging into the master branch. Tests should involve calling |
Would the supported_branches.txt file be inside this git repository? Or would it be generated each time the init.sh script is called?
Why? What is the drawback if a user decides to compile the newest beta branch that is just now available? The only reason I see for a branch dependent code is for example the switch between legacy and non-legacy build. |
Yes
It will be trivial to add the new branch in the file, and would likely be done more promptly because it is more straightforward than the current code |
I'll give this approach a try (and some testing) if you can fix the shellcheck errors
and
(I can't fix them because I don't have write access to your repo) |
Replaced the part that may cause a globbing issue
Remove useless BRANCH_NUM variable.
Thanks. These changes are now in my test branch, and I hope to get them tested in the next few days when I get home from holiday |
Thanks for this PR. I'll close it since the code was merged into the master branch in #757 |
In order to get rid of the long list of "supported" lineage branches I propose a solution that does not need any more maintenance at each lineage version as long as the offset between lineage version and android version remains 7.
Background is, that I often could not build the newest lineage development version because of the lineage version in the case statements was outdated.