28 November 2006

Browser Integration

For completeness here is another writeup of the integration of Liferea with different browsers:

Epiphany



If you using Epiphany you only need to enable the feed subscription plugin which is delivered per default (in some distributions as a epiphany-plugins package). To do so enable the "News Feed Subscription" extensions under Tools/Extensions. If the plugin is enabled and the currently loaded website provides a feed you will see an icon in the toolbar as shown in this screenshot on the left.

After clicking the icon the subscription will be added.


Mozilla/Firefox 1.5+

If you are using Firefox 1.5 you need the FeedBag extension. You can download it from the Liferea Homepage or from the Mozilla Addons website.

Firefox 2.0+



When using Firefox feeds are represented by the orange feed icon in the URL bar. To subscribe to a feed just click the icon. In the default setting clicking the icon will add the feed to the Live Bookmarks of Firefox. If you want to directly add a subscription to your feed reader you need to change the subscription preferences. This can be done under Tools/Edit Preferences in the "Feed" tab. For Liferea you need to specify the command "liferea-add-feed" as shown in the screenshot below:


The "liferea-add-feed" script should come with your Liferea package and uses DBUS to send a subscription request to the running Liferea instance.

15 comments:

intangible said...

liferea-add-feed is useful, but I had to create a wrapper in ~/bin/liferea-add-feed so it would work even when liferea wasn't already running...


#!/usr/bin/env bash

if [[ "$@" == '' ]]
then
zenity --error --text "Please provide a feed url!"
exit 1
fi

if [ -e "$HOME/.liferea/lock" ] || [ -h "$HOME/.liferea/lock" ]
then
/usr/bin/liferea-add-feed $@
else
liferea &
sleep 1
/usr/bin/liferea-add-feed $@
fi


The sleep 1 is a dirty hack, but this was primarily for my own use... Any word on liferea-add-feed supporting starting liferea in the future?

Lars said...

Good idea. The question is how to ensure that the DBUS message is sent after the program startup was successful.

Jay L said...

Liferea-add-feed does nothing for me. I've set it in Firefox, but nothing happens in Liferea when I click to add a feed in Firefox.

I'm running Ubuntu Dapper 6.06.

Anyone else experience this problem?

Anonymous said...

The same problem here. I can't add the feeds with the liferea-add-feed script. It doesn't work.

Lars said...

@Jay L+Anonymous: If you are using the package of your distribution (Ubuntu) please contact the package maintainer. He should be able to tell wether
- the script is included at all
- if he compiled with DBUS support

If you want to check for yourself please run Liferea like this 'liferea --debug-all | grep -i "Registering with DBUS"'. If it gives you a "Registering with DBUS" line the liferea-add-feed could work in principle. Then the next step would be to use it on the command line: "liferea-add-feed <feed url>". It should give you an error or add the subscription.

Without knowing wether you have the script installed and wether the program was compiled with DBUS support or not I cannot help you.

SilitekAtTheWheel said...

Hi;
I'm really happy I discovered liferea so long ago in its 0.x days.

Though the 1.2x flavour has some issues, personal they be. I'm not crazy about the time reference format using the labels like "Today" and "Yesterday", then as time recedes the old year/month/day time" standard I'm so used to kicks in. Is there an easy way to revert to the older way of displaying the date/time in the headline pane? Is it a gconf thing? Sorry if the answer to this change is obvious. The Yesterday and Today tokens well they're cute..if a little Macish :)

Also the graphics (source fvavicon/icon site graphic, et cetera) rendering in the article pane is different...maybe cleaner looking all around, occupying less space, but I prefer the stylized look of the 1.0x series. Is this also fixed in stone, or can the old style article window dressing be displayed?

On wrapper scripts, liferea and firefox:

I had a legacy configuration for my firefox starter icon and menu item that looked like this: /usr/bin/aoss firefox

It's leftover from when the audio drivers didn't work that well with Realplayer. the aoss wrapper itself prevented liferea-add-feed from launching, and ironically the aoss wrapper script also prevented java crashes. Don't ask me why...and the crash insurance has nothing to do with liferea anyway, but it's a curiosity nevertheless.

Thanks coding liferea in the first place Lars!!!

I am grateful!

Lars said...

@SilitekAtTheWheel: Thanks for the feedback! As for the date formatting there is a Gconf key where you can set it to a manual format string. Please have a look at posting. The same goes for the CSS styles that changed from 1.0 to 1.2. You can change them by supplying user defined stylesheets as described in this post. I think that with some effort it is possible to get a similar style as with 1.0.

Jay L said...

lars

I ran your instruction. Here's the output:

~$ liferea --debug-all | grep -i "Registering with DBUS"

** (liferea:15288): WARNING **: Unknown social bookmarking site ""!
error : xmlEncodeEntitiesReentrant : input not UTF-8

Any suggestions?

I installed liferea 1.2 from the site download.

Thanks.

Lars said...

@Jay L: With "installed from site download" I assume you downloaded the sources and compiled yourself? If this is the case please rerun the configure script and check the feature summary given after a successful run. To liferea-add-feed to work correctly the DBUS support must be listed as enabled.

Jay L said...

lars,

Thanks, but I'm a little too un-techie to quite know what I need to do.

You are correct that I downloaded the source and compiled myself.

1. However, what do I do to rerun the configure script. Is that just going back into the relevant directory, and running ./configure at the command line. Or something else?

2. How do I check the feature summary after I do that.

Thanks.

Lars said...

@Jay L: All you need to do is to run "./configure" from the source root. The end of the output of configure could look like this:

[...]
liferea 1.2.2

Build Mozilla Plugin............ : no
Build XulRunner Plugin.......... : yes
Build GtkHTML Plugin............ : yes

Build libnotify Plugin.......... : yes
Build LUA scripting Plugin ..... : yes

Use X Session Management........ : yes
Use DBUS........................ : yes
Use NetworkManager.............. : yes
GNUTLS SSL/HTTPS Support........ : yes

Liferea will be installed in /usr/local/bin.
[...]

And the important thing for your problem is the "Use DBUS" line which needs to be set to "yes" for DBUS to work.

Jay L said...

lars,

I don't know what you mean by running ./configure "from the root source." I know how to run ./configure at the command line. It's the from root source that I don't understand.

Sorry.

Jay L said...

lars,

I figured it out. So here's what I get:

liferea 1.2.1

Build Mozilla Plugin............ : yes (mozilla)
Build XulRunner Plugin.......... : no
Build GtkHTML Plugin............ : no

Build libnotify Plugin.......... : no
Build LUA scripting Plugin ..... : yes

Use X Session Management........ : yes
Use DBUS........................ : no
Use NetworkManager.............. : no
GNUTLS SSL/HTTPS Support........ : yes

Liferea will be installed in /usr/local/bin.

Use DBUS, I see, is no, instead of yes. Now what do I do?

Thanks.

Jay L said...

lars,

I installed some software, and ran the compiler script again. Now I get the necessary yes:

liferea 1.2.1

Build Mozilla Plugin............ : yes (mozilla)
Build XulRunner Plugin.......... : no
Build GtkHTML Plugin............ : no

Build libnotify Plugin.......... : no
Build LUA scripting Plugin ..... : yes

Use X Session Management........ : yes
Use DBUS........................ : yes
Use NetworkManager.............. : no
GNUTLS SSL/HTTPS Support........ : yes

Liferea will be installed in /usr/local/bin.

Therefore, I ran make and make install.

And I still find that liferea-add-feed does not add the feed that I select. I set the preference in Firefox, and the progress bar in Firefox shows movement. But the feed never appears in Liferea.

Jay L said...

I ran the configure script again, and re-installed again, this time as root, rather than as user with root privileges. Now, Liferea-add-feed works.