Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

How to Install Caffeine in Debian

Share your HowTo, Documentation, Tips and Tricks. Not for support questions!.
Post Reply
Message
Author
rockstorm
Posts: 21
Joined: 2014-09-27 16:51

How to Install Caffeine in Debian

#1 Post by rockstorm »

This is about installing Caffeine in Debian Jessie (I believe this method works in Debian Wheezy as well but I haven't tested it). Caffeine is a program only available for Ubuntu so it's not in debian repositories and this is why installing it in debian is not as easy as it could be. This might also serve as an example of a more general HowTo: "How to Install Ubuntu Packages in Debian".

Caffeine is a program that disables power managment settings while some applications are active. In my case I use it to prevent the monitor from going black while whatching movies. More information about this program here.

Adding Caffeine repositories:

Open as root the file /etc/apt/sources.list. In my case im using the text editor kwrite, replace "kwrite" with your text editor:

Code: Select all

sudo kwrite /etc/apt/sources.list

At the end of the file append this lines*:

Code: Select all

deb http://ppa.launchpad.net/caffeine-developers/ppa/ubuntu precise main 
deb-src http://ppa.launchpad.net/caffeine-developers/ppa/ubuntu precise main
Save and close file /etc/apt/sources.list and update the sources:

Code: Select all

apt-get update

Manually installing "python-central"

Usually apt-get handles all the dependencies but in my case apt-get could not install this one on his own so I had to manually install it. Download the package from here:
https://packages.debian.org/wheezy/python-central

Install the package using the command [1]:

Code: Select all

dpkg -i package_name.deb
In my case it was:

Code: Select all

dpkg -i python-central_0.6.17_all.deb

Install Caffeine:

Finally we get to install Caffeine:

Code: Select all

apt-get install caffeine
* In this case I'm using ubuntu version Precise (12.04), I believe you could use almost any previous ubuntu release but it definitely does not work with Trusty (14.04).
[1] http://www.cyberciti.biz/faq/ubuntu-lin ... -packages/

NOTE: I'm far from being an expert in linux so if anyone notices something that I might be doing terribly wrong I would be very pleased if you could point it out.
"What we have done for ourselves alone dies with us; what we have done for others and the world remains and is immortal."
― Albert Pike

User avatar
stevepusser
Posts: 12930
Joined: 2009-10-06 05:53
Has thanked: 41 times
Been thanked: 71 times

Re: How to Install Caffeine in Debian

#2 Post by stevepusser »

The Ubuntu Precise packages will probably work without harming your system, but so many people have damaged their systems by adding Ubuntu and PPA repositories, they are not recommended. Of course, one can break their system if they want to, they own it, but it's better to get the Debianized source code out of a PPA and rebuild the packages against a Wheezy base--this ensures that they will be compatible.

A far better choice than dpkg for single deb file installation is gdebi--it will refuse to install incompatible packages, and get any missing dependencies (python-central, anyone) automatically.
Last edited by stevepusser on 2014-10-02 21:10, edited 1 time in total.
MX Linux packager and developer

User avatar
harrycaul
Posts: 105
Joined: 2008-12-23 17:06

Re: How to Install Caffeine in Debian

#3 Post by harrycaul »

Last edited by harrycaul on 2014-10-02 21:10, edited 1 time in total.


User avatar
stevepusser
Posts: 12930
Joined: 2009-10-06 05:53
Has thanked: 41 times
Been thanked: 71 times

Re: How to Install Caffeine in Debian

#5 Post by stevepusser »

We could start charging to fix systems that got screwed up by PPA packages...
Debian-only screwups from upstream half-off.

Sometimes I wonder if these guys that keep pushing Ubuntu solutions didn't also hang around here and touch up photos for free:

http://www.photoshoptroll.com/

Image
MX Linux packager and developer

User avatar
llivv
Posts: 5340
Joined: 2007-02-14 18:10
Location: cold storage

Re: How to Install Caffeine in Debian

#6 Post by llivv »

asked to have this thread removed.

If a user doesn't already know howto add a ppa to a Debian Install,
those users shouldn't have instructions showing them how to make changes that can
cause further, unsupported issues.

If someone wants to add a ppa to their system that is their decision,
but issues resulting from adding a ppa will not be supported in this forum.

thanks for your understanding
In memory of Ian Ashley Murdock (1973 - 2015) founder of the Debian project.

Post Reply