-
-
Notifications
You must be signed in to change notification settings - Fork 62
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
Implement Self-Update parameter/functionality #12
base: master
Are you sure you want to change the base?
Conversation
Hi. This is interesting. First question is if changing from The upgrader logic seems ok, but it only checks if the version is the same. I have functions to check if version is bigger/smaller in other scripts. They also use the tarball, instead of the raw file (in case future versions have extra files). I may want to rename the parameter as well, probably Here is how it is done in Then there is also the parameters to ignore SSL certificates and to force-confirm prompts. Having --self-install is also interesting for many reasons, including to install directly from the web (one-liners). About the parsing of blacklisted packages, there are many options. Complex parsing is mostly done with AWK here in opkg-upgrade. We could just save a package per line in the file. Should be easy to parse that. |
This is from the help of pdfscale:
I would probably just remove the |
BTW Both the installer and the upgrader can certainly be simplified a lot just by assuming/ensuring that we are running as root. So we can basically make a single check if we are root and exit if it is not. Then we can remove all the checks and sudo parts. Would just run and check once. This removes 70% of the complexity of the pdfscale installers. About using the raw version or the tarball, still not sure here. It may be easier/better to just use the raw in this case, since opewrt devices may be very uncappable machines. |
/etc/os-release has same data, but has more informations and is platform independent (checked few opkg distributions for that). this is the only one reason to use it. |
#made from wish list
check if newer version exists and replaces executable require parameter -c or --check-version
declared with REPOSITORY
changed system variables call from /etc/openwrt_release to /etc/os-release which is more "linux like"
ROUTER_NAME > HOSTNAME
DISTRIB_ARCH > OPENWRT_ARCH
DISTRIB_TARGET > OPENWRT_BOARD
DISTRIB_DESCRIPTION > OPENWRT_RELEASE
NAME - to be used in reports (future)