maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   SailfishOS (https://talk.maemo.org/forumdisplay.php?f=52)
-   -   [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak (https://talk.maemo.org/showthread.php?t=92935)

coderus 2016-05-09 17:55

Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
 
ls /var/lib/patchmanager/ausmt/patches
for each patch file check files it's patching
then search for packages using rpm -qf filename
and reinstall each found package by using pkcon install package

ajalkane 2016-05-09 20:06

Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
 
One more problem... Other patches I had no trouble with doing it like this:

With coderus' method reinstalled each package, then unapplied them from PatchManager and reapplied them.

But the "Upcoming events on lockscreen" patch was a trickier one. I tried unapplying it and PatchManager said "Failed to remove patch" and it stayed activated.

I then decided to remove it with "pkcon remove lockscreen-upcoming". Now PatchManager told me the patch is no longer available and removed it from its list. I then reinstalled it from warehouse. Now when I started PatchManager it showed this patch already applied, and I'm in the same sorry state that I can't unapply it so that I could reapply it.

coderus 2016-05-09 20:09

Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
 
remove folders from /var/lib/patchmanager/ausmt/patches

ajalkane 2016-05-10 20:22

Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
 
Quote:

Originally Posted by coderus (Post 1505277)
remove folders from /var/lib/patchmanager/ausmt/patches

This was not enough for Upcoming Events on lockscreen patch, so to save time for others potentially battling with this (and for me to remember for next update) here's how I got it working:

First uninstall:

Code:

pkcon remove lockscreen-upcoming
Edit file /var/lib/patchmanager/ausmt/packages and remove the line which references lockscreen-upcoming.

Remove all added QML files that have been installed when lockscreen-upcoming was applied:

Code:

rm -f /usr/share/lipstick-jolla-home-qt5/lockscreen/BorderRectangle.qml
rm /usr/share/lipstick-jolla-home-qt5/lockscreen/LockEventItem.qml
rm -f /usr/share/lipstick-jolla-home-qt5/lockscreen/LockTimeLabel.qml
rm -f /usr/share/lipstick-jolla-home-qt5/lockscreen/ShowCalEvents.qml

Then you can install it again from Warehouse and activate successfully from PatchManager.

coderus 2016-05-10 20:37

Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
 
It's so bad when patches creating new files. this is not the thing patches should really do.

Ancelad 2016-05-10 20:46

Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
 
@coderus
but what about diff between file and /dev/null? Is it bad or not? :)

coderus 2016-05-11 13:29

Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
 
bad. you should package new files, not apply with patch.

Ancelad 2016-05-11 13:46

Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
 
Even if post/pre contains file-check and rm-command for this file?

coderus 2016-05-11 16:04

Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
 
yes. everything new should be packaged.

pichlo 2016-05-11 17:52

Re: [WIP] App / Tweak: patchmanager a system-wide patching system + homescreen tweak
 
coderus is right, a patch creating a file is BAD.
I like the idea of diff with /dev/null though. Maybe even /dev/random ;)


All times are GMT. The time now is 05:07.

vBulletin® Version 3.8.8