Linux Lite 8.0 RC1 has been released - Click here


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5

Lite Updates Notify - Development
#61

Nice catch Ralphy, your solution worked :)

Steps to test on 32bit fresh 3.2 VM install:

1. Install a fresh 3.2 bit VM, do not run Install Updates.
2. Take a Snaphot of the VM for future testing.
3. Install Lite Updates Notify package.
4. Set to 2 mins to test.
5. First notification shows 143 total packages available 90 of which are Security.
6. Open Synaptic, Synaptic shows 145 packages for upgrade. (2 package discrepancy from Step 5)

So far, so excellent!

I wonder what the 2 extra packages are between Steps 5 & 6?

New updatenotify-launcher pushed to git.

Very happy with this development to date.

Download your free copy of Linux Lite today.

Jerry Bezencon
Linux Lite Creator

"Do not correct a fool, or he will hate you; correct a wise man and he will appreciate you."

[Image: X5qGkCg.png]

[Image: 0op1GNe.png] [Image: LgJ2mtP.png] [Image: vLZcFUE.png] [Image: lrUHro3.jpg]
Reply
#62

[Image: xECJGWw.png]

[Image: vAWV8XA.png]

Download your free copy of Linux Lite today.

Jerry Bezencon
Linux Lite Creator

"Do not correct a fool, or he will hate you; correct a wise man and he will appreciate you."

[Image: X5qGkCg.png]

[Image: 0op1GNe.png] [Image: LgJ2mtP.png] [Image: vLZcFUE.png] [Image: lrUHro3.jpg]
Reply
#63

This command seems to ensure Steps 5 & 6 match:

Code:
apt-get -s dist-upgrade | awk '/[0-9]+ upgraded,/ {print $1 " package updates are available"}'

Propose the following for updatenotify file:

Code:
#!/bin/bash
xhost local:$USER > /dev/null 2>&1
export DISPLAY=:0
tmpfile=/tmp/lun
ionice -c2 -p$$ -n 7;nice -n 19 apt-get update >/dev/null 2>&1
UPD=$(apt-get -s dist-upgrade | awk '/[0-9]+ upgraded,/ {print $1 " package updates are available"}' && echo && echo Click here to remove this message); >> $tmpfile
if grep -q -x '0 packages can be updated.' /tmp/lun; then
    notify-send -i /usr/share/icons/Faenza/places/48/distributor-logo-ubuntu.png --expire-time=5000 '   Lite Updates Notify' "Your system is up-to-date"
else
    notify-send -i /usr/share/icons/Faenza/apps/48/system-software-installer.png --expire-time=10000 'Install Updates' "$UPD"
fi
xhost - >/dev/null 2>&1
rm -f $tmpfile
exit

[Image: IDnCHCK.png]

Download your free copy of Linux Lite today.

Jerry Bezencon
Linux Lite Creator

"Do not correct a fool, or he will hate you; correct a wise man and he will appreciate you."

[Image: X5qGkCg.png]

[Image: 0op1GNe.png] [Image: LgJ2mtP.png] [Image: vLZcFUE.png] [Image: lrUHro3.jpg]
Reply
#64

(12-16-2016, 09:13 AM)Jerry link Wrote:  This command seems to ensure Steps 5 & 6 match:

Code:
apt-get -s dist-upgrade | awk '/[0-9]+ upgraded,/ {print $1 " package updates are available"}'

Propose the following for updatenotify file:

Code:
#!/bin/bash
xhost local:$USER > /dev/null 2>&1
export DISPLAY=:0
tmpfile=/tmp/lun
ionice -c2 -p$$ -n 7;nice -n 19 apt-get update >/dev/null 2>&1
UPD=$(apt-get -s dist-upgrade | awk '/[0-9]+ upgraded,/ {print $1 " package updates are available"}' && echo && echo Click here to remove this message); >> $tmpfile
if grep -q -x '0 packages can be updated.' /tmp/lun; then
    notify-send -i /usr/share/icons/Faenza/places/48/distributor-logo-ubuntu.png --expire-time=5000 '   Lite Updates Notify' "Your system is up-to-date"
else
    notify-send -i /usr/share/icons/Faenza/apps/48/system-software-installer.png --expire-time=10000 'Install Updates' "$UPD"
fi
xhost - >/dev/null 2>&1
rm -f $tmpfile
exit

[Image: IDnCHCK.png]

Well we can use apt-get -s dist-upgrade since it is just a simulation but that requires additional changes in the script. Before we get into that, can we just put this on hold for a moment? There are few things that I would like to share with you first.

https://unlockforus.com

Sorry for seeming stupid and preferring Linux - I just don't know any better.

[Image: AGxgqJ6.png]
Reply
#65

Not a problem.

Download your free copy of Linux Lite today.

Jerry Bezencon
Linux Lite Creator

"Do not correct a fool, or he will hate you; correct a wise man and he will appreciate you."

[Image: X5qGkCg.png]

[Image: 0op1GNe.png] [Image: LgJ2mtP.png] [Image: vLZcFUE.png] [Image: lrUHro3.jpg]
Reply
#66

It seems you've been left alone for too long to take care of everything. A distribution on the shoulders of a single person is no joke. I'm really surprised you've been able to handle it all on your own because I can't picture myself doing what you do, hence my most sincere respect to your work and dedication; you Jerry, are a truly rock star!

With that said, I'm going to make a positive criticism next, and I deeply hope I'm not misunderstood in my words, thus I'll be selective and cautious in the way I say it because like I said before, I can only dream about doing what you do.

You need help deb packaging to make the OS cleaner in the backend... mostly with permissions delivered via postinst and also prerm scripts. Not all packages must be "required" nor they are "essential", therefore they should have good prerm scripts to really clean their leftovers on uninstall and what not. I know for a fact that it is not you don't want it that way but that you've been overloaded with everything the distribution requires... including maintenance, advertisement, website, servers, etc.

My point is, I wanna help because it is actions what makes the difference. Allow me to help you packaging or scripting (with you) LL packages, postinst and prerm. Here is a good example of a package that does it the way it should:

https://unlockforus.com/downloads/liteup...uxlite.deb

- The package is not marked as essential
- It includes postinst to set correct permissions in all files being installed
- It includes an md5sums file with a hash of all files contained in the package for installation
- It includes a prerm to remove all leftovers, including the cron job set by the application, hence an apt-get remove will not leave non-runnable cron jobs in the user's cron, or files from this package behind.

That's what I want to help you improve as time goes because I know there is only so much you can do. These things do take time. I propose that we collaborate with one another so that we both keep scripts up to date on both sides and irrespective who does the packaging we can always be on the same page.

The development goes from the icon we added to the application, its first line of code, all the way to the packaging and distribution of said app. And I believe LL needs some love in this department. That's what I wanted to share with you for your consideration.


 


https://unlockforus.com

Sorry for seeming stupid and preferring Linux - I just don't know any better.

[Image: AGxgqJ6.png]
Reply
#67

I welcome feedback, and you've done it the right way. I'll start with adding the DEBIAN folder to all the github repos so that the a more complete co-operation can occur.

Download your free copy of Linux Lite today.

Jerry Bezencon
Linux Lite Creator

"Do not correct a fool, or he will hate you; correct a wise man and he will appreciate you."

[Image: X5qGkCg.png]

[Image: 0op1GNe.png] [Image: LgJ2mtP.png] [Image: vLZcFUE.png] [Image: lrUHro3.jpg]
Reply
#68

Do you want to be responsible for going through our existing packages and ensuring the points you mentioned are created and maintained? Are you able to create files and folders on the github repos you can merge to?

Download your free copy of Linux Lite today.

Jerry Bezencon
Linux Lite Creator

"Do not correct a fool, or he will hate you; correct a wise man and he will appreciate you."

[Image: X5qGkCg.png]

[Image: 0op1GNe.png] [Image: LgJ2mtP.png] [Image: vLZcFUE.png] [Image: lrUHro3.jpg]
Reply
#69

Yes an yes. I want to help but I don't want to "be responsible" to the extend that it becomes my obligation because I have many other things I do besides my LL limited contribution.

To make it easy, we just need to do one package at a time as updates are released. It shouldn't be too hard to get everything under control quickly :)

Agreed?


https://unlockforus.com

Sorry for seeming stupid and preferring Linux - I just don't know any better.

[Image: AGxgqJ6.png]
Reply
#70

Agreed :) It won't be your obligation, I believe all tasks can be shared, not an accurate choice of words on my behalf.

Are you able to create files and folders on the github repos you can merge to?

Download your free copy of Linux Lite today.

Jerry Bezencon
Linux Lite Creator

"Do not correct a fool, or he will hate you; correct a wise man and he will appreciate you."

[Image: X5qGkCg.png]

[Image: 0op1GNe.png] [Image: LgJ2mtP.png] [Image: vLZcFUE.png] [Image: lrUHro3.jpg]
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)