Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: Optimize the "News" function and avoid unexpected behaviors (#213)
This commit brings multiple improvements to the "News" function of the main script in order to optimize it and avoid unexpected behaviors: - Print a message when Arch-Update is looking for recent Arch News (to avoid people thinking the script is just stuck in case it takes some time due to network instability/slowness) - Print a message if no recent Arch News has been found since the last run - Optimize the curl requests by merging the two first ones into a single one - Add a default 30 sec timeout (`--max-time 30`) to curl requests so they don't end taking multiple minutes on slow/faulty network connection). If the timeout is reached, Arch-Update prints a warning explaining that it wasn't able to retrieve Arch News in a reasonable time, prints the URL of the Arch website or the URL of the selected news (so users can still look that up separately) and move on to the packages updates. Fixes #206
- Loading branch information