thytom / dwmbar

A Modular Status Bar for dwm.
GNU General Public License v3.0
128 stars 23 forks source link

`archupdates` issue #17

Closed keeganjk closed 3 years ago

keeganjk commented 4 years ago

Although there are no packages to upgrade/update using pacman or yay, using archupdates on the statusbar shows between 0 and 6 updates available, a value that seems to shift frequently. yay does note a package as being newer than in the AUR and another as being flagged out-of-date, yet there are no updates available; pacman merely states that there is nothing to

I am pretty sure this issue has to do with those packages that have special conditions although there are no updates available (Updates frequently shows 2 available, and there are 2 [both newer than in AUR and marked out of date]).

Is it possible to ignore instances such as these to prevent this issue?

thytom commented 4 years ago

I'm not sure that this has to do with AUR packages being flagged out of date. I installed a random package that hasn't been updated since 2017 (eigen3-hg) and confirmed it was flagged out-of-date with yay -Su --aur, which can tell you about missing/out-of-date packages. Running yay -Qum --devel, then shows no available updates, as expected.

Perhaps this has something to do with the --devel flag? This flag makes sure to check -git packages for updates. You could run pacman -Qe | grep -e "-git" to see a list of installed packages with the "-git" suffix. If you see around 6 packages or more, that might be your problem? Git packages will obviously change quite frequently, so I would expect the fluctuation you see.

It could also be -Qum vs -Qu, although I'm not sure of the difference there. @Baitinq wrote this one so he might have more of an idea. I'll get his attention.

keeganjk commented 4 years ago

I just updated and then ran yay -Qum --devel and it does show one item (anbox-git) (it showed 2 before updating and the statusbar displayed Updates: 4), after a moment it did upgrade to Updates: 1, which is true in relation to the command that I just ran.

Running pacman -Qe | grep -e "-git" showed 9 discrete items that ended with -git.

Running yay -Qum --devel again results in 7 items and yay -Qu --devel showed 1 item. After running yay, yay -Qum --devel showed 4 items and yay -Qu --devel shows none.

It seems that yay is not actually updating anything but these git applications still exist. I suppose I should somehow use a different command in the archupdates to fix this issue?

Baitinq commented 4 years ago

Hey @keeganjk. To get rid of those extra updates you can remove the --devel flag from the yay command in archupdates, as it checks for updates (new commits) on -git packages. Another way to fix this would be to update your system by doing yay -Syu --devel, which should update your -git packages. Keep in mind *-git packages can be updated extremely frequently as a new update can just be a new git commit.

Baitinq commented 4 years ago

@keeganjk latest commit should fix your issue :)

keeganjk commented 4 years ago

@Baitinq I removed --devel from the command in archupdates but it still showed 8 updates and then 1, although there should be 0. I've tried to restart dwm several times. I am having difficulty understanding what the code does, specifically the if statement toward the bottom. My $DELAY appears to be at 0.05, but it still seems to be updating slowly/not at all. Do you know what is supposed to enact the update/changing of this module?