Lars Windolf's blog

Liferea 1.10 and Firefox 34 as External Browser

Today I learned that newest Firefox release 34 drops some Mozilla legacy command line options that Liferea used for a long time to open links in a Firefox tab or window.

When you upgrade to Firefox 34 opening links might suddenly stop to work, because Liferea uses the wrong launch command.

Workarounds

Here are 2 simple workaround alternatives. For both you need to open the "Browser" tab in the preferences dialog (via menu /Tools/Preferences):

  1. Either simply choose "GNOME Default Browser".
  2. Or choose "Manual" and set command to
    firefox %s

Screenshot of the browser settings tab:

Liferea 1.10.14 Released

There is a new maintenance release for the 1.10 line. It tries to fix startup crashes reported by several users and fixes a bug with launching links in the external browser. Please upgrade!

ChangeLog

    * Fixes Github #134: Broken default news feed.
      (reported by pvdl)
    * Fixes Github #133: Subscribe into TheOldReader categories
    * Fixes Github #122: Crashes at launch, "segmentation fault"
      (reported by geoffm)
    * Fixes some memory leaks
      (patch by Rich Coe)
    * Fixes Github #145: Incorrect method triggered for 'Launch External'
      (patch by mozbugbox)
    * Fixes Github #48: Window stays hidden on next start after Ctrl+W
      (reported by Jeff Fortin)
    * Expose LifereaHtmlView to GObject Introspection
      (patch by mozbugbox)
    * Improves Google Reader API error handling
    * Now using HTTPS only when accessing TheOldReader
    * Added LifereaNodeSourceActivatable interface to allow plugins
      implementing new node source types.
    * Downgrade enclosure drop warning from Glib warning to debug trace.

Download

You can download the release on Github:
https://github.com/lwindolf/liferea/releases/tag/v1.10.14

Puppet: List Changed Files

If you want to know which files where changed by puppet in the last days:

cd /var/lib/puppet
for i in $(find clientbucket/ -name paths); do
	echo "$(stat -c %y $i | sed 's/\..*//')       $(cat $i)";
done | sort -n

will give you an output like

[...]
2015-02-10 12:36:25       /etc/resolv.conf
2015-02-17 10:52:09       /etc/bash.bashrc
2015-02-20 14:48:18       /etc/snmp/snmpd.conf
2015-02-20 14:50:53       /etc/snmp/snmpd.conf
[...]

Liferea Trick #9: Skimming Trough the Headlines

I'm not sure about how many users are aware of the feature, but I'm certain it is worth to know about as it saves a lot of clicking and pointing with the mouse. If you are a keyboard user it's worth knowing about the hotkey to skim through headlines.

Remember the Hot Key

As this hotkey is configurable check the preference dialog ff you are not sure about the setting. The default setting is <Ctrl>-Space...

How it Works...

By using this hot key you can navigate the article pane and the item list view at the same time. As long as the article pane allow vertical scrolling it scrolls down. Once you reach bottom Liferea jumps to the next unread article.

Using the headline skimming hotkey is like a "Next Unread And Scroll Down" menu option...


Recent Liferea Tricks

Fixed Issue with "Open in External Browser" Option

Pull Request #145: "Incorrect method triggered for 'Launch External'" by mozbugbox fixes an often reported issue with launching links in external browser. Due to a copy an paste mistake the same callback was called for link menu options 'Open in External Browser' and 'Open in Browser'.

A screenshot of the menu options:

The difference between both option is that 'Open in External Browser' always launches the link in your favourite web browser while the other option does load links in Liferea if you specified so in the preferences. As 'Open in External Browser' incorrectly triggered the same callback as 'Open in Browser' the bug appeared depending on the preference settings.

Will be fixed with release 1.10.14 and 1.11.3

Help Needed: High Contrast Icon

Today Obsidien created ticket #148 about support for the GNOME high contrast icon theme.

Icons in this theme look like this:


(screenshot taken from GNOME Wiki)

As I'm not an artist in any way I want to ask you readers for your help! So if you are a graphics artist and have some spare time why not gift an high contrast icon for Liferea! If you are interested leave a note in the ticket.

Liferea 1.11.3 Released

There is a new release for the unstable line: Liferea 1.11.3. This release fixes several issues and introduces an improvement of the rendering of the 3 pane "Wide View" mode to save screen space on 16x9 screens. This is intended to improve usability in full screen mode on desktops and tablets. This release also introduces folder (categories) support for TheOldReader subscriptions.

Here is a screenshot of the changed "Wide View" mode

Give 1.11.3 a try and send feedback to the mailing list [email protected]!

ChangeLog

    * Fixes Github #134: Broken default news feed.
      (reported by pvdl)
    * Fixes Github #133: Subscribe into TheOldReader categories
    * Fixes Github #122: Crashes at launch, "segmentation fault"
      (reported by geoffm)
    * Fixes some memory leaks
      (patch by Rich Coe)
    * Fixes Github #145: Incorrect method triggered for 'Launch External'
      (patch by mozbugbox)
    * Fixes Github #48: Window stays hidden on next start after Ctrl+W
      (reported by Jeff Fortin)
    * Expose LifereaHtmlView to GObject Introspection
      (patch by mozbugbox)
    * Improves Google Reader API error handling
    * Now using HTTPS only when accessing TheOldReader
    * Added LifereaNodeSourceActivatable interface to allow plugins
      implementing new node source types.
    * Downgrade enclosure drop warning from Glib warning to debug trace.

Download

You can download the release on Github:
https://github.com/lwindolf/liferea/releases/tag/v1.11.3

Static Code Analysis of any Autotools Project with OCLint

The following is a HowTo describing the setup of OCLint for any C/C++ project using autotools.

1. OCLint Setup

First step is downloading OCLint, as there are no package so far, it's just extracting the tarball somewhere in $HOME. Check out the latest release link on http://archives.oclint.org/releases/.

cd
wget "http://archives.oclint.org/releases/0.8/oclint-0.8.1-x86_64-linux-3.13.0-35-generic.tar.gz"
tar zxvf oclint-0.8.1-x86_64-linux-3.13.0-35-generic.tar.gz 

This should leave you with a copy of OCLint in ~/oclint-0.8.1

2. Bear Setup

As project usually consist of a lot of source files in different subdirectories it is hard for a linter to know where to look for files. While "cmake" has support for dumping a list of source files it processes during a run "make" doesn't. This is where the "Bear" wrapper comes to play: instead of

make

you run

bear make

so "bear" can track all files being compiled. It will dump a JSON file "compile_commands.json" which OCLint can use to do analysis of all files.

To setup Bear do the following

cd
git clone https://github.com/rizsotto/Bear.git
cd Bear
cmake .
make

3. Analyzing Code

Now we have all the tools we need. Let's download some autotools project like Liferea. Before doing code analysis it should be downloaded and build at least once:

git clone https://github.com/lwindolf/liferea.git
cd liferea
sh autogen.sh
make

Now we collect all code file compilation instructions with bear:

make clean
bear make

And if this succeed we can start a complete analysis with

~/oclint-0.8.1/bin/oclint-json-compilation-database

which will run OCLint with the input from "compile_commands.json" produced by "bear". Don't call "oclint" directly as you'd need to pass all compile flags manually.

If all went well you could see code analysis lines like those:

[...]
conf.c:263:9: useless parentheses P3 
conf.c:274:9: useless parentheses P3 
conf.c:284:9: useless parentheses P3 
conf.c:46:1: high cyclomatic complexity P2 Cyclomatic Complexity Number 33 exceeds limit of 10
conf.c:157:1: high cyclomatic complexity P2 Cyclomatic Complexity Number 12 exceeds limit of 10
conf.c:229:1: high cyclomatic complexity P2 Cyclomatic Complexity Number 30 exceeds limit of 10
conf.c:78:1: long method P3 Method with 55 lines exceeds limit of 50
conf.c:50:2: short variable name P3 Variable name with 2 characters is shorter than the threshold of 3
conf.c:52:2: short variable name P3 Variable name with 1 characters is shorter than the threshold of 3
[...]

Liferea Trick #8: Change Menu Accelerators

When you are not satisfied with the menu key bindings defined by Liferea do not despair it is easy to change them!

Variant #1: Edit ~/.config/liferea/accels

This variant is 100% portable and should work for everyone. Open ~/.config/liferea/accels in your favourite editor. This file is loaded upon startup by Liferea and contains lines like these:

[...]
; (gtk_accel_path "<Actions>/AddActions/NewVFolder" "")
; (gtk_accel_path "<Actions>/GeneralActions/SearchMenu" "")
; (gtk_accel_path "<Actions>/ItemActions/ToggleItemFlag" "<Primary>t")
; (gtk_accel_path "<Actions>/GeneralActions/PrevReadItem" "<Primary><Shift>n")
[...]

Note how only the "ToggleItemFlag" and the "PrevReadItem" line have defined key bindings, while "NewVFolder" and "SearchMenu" don't.

To change a key binding first remove the semicolon at the start of the line and then adapt or clear the key binding field. Choose prefixes like "<Primary>" (for Ctrl), "<Alt>", "$lt;Shift> as needed and append the key after it.

Variant #2: Enable Editable Accelerators with your Linux Distro Settings

This variant is hard to document as different distributions have different setting dialogs. Some expose a setting to enable life editing of key bindings. Once this is enabled you can open a menu hover over a menu option and press the accelerator you want to assign. It should show up instantly.


Recent Liferea Tricks

Debugging dovecot ACL Shared Mailboxes Not Showing in Thunderbird

When you can't get ACL shared mailboxes visible with Dovecot and Thunderbird here are some debugging tipps:

  1. Thunderbird fetches the ACLs on startup (and maybe at some other interval). So for testing restart Thunderbird on each change you make.
  2. Ensure the shared mailboxes index can be written. You probably have it configured like
    plugin {
      acl_shared_dict = file:/var/lib/dovecot/db/shared-mailboxes.db
    }

    Check if such a file was created and is populated with new entries when you add ACLs from the mail client. As long as entries do not appear here, nothing can work.

  3. Enable debugging in the dovecot log or use the "debug" flag and check the ACLs for the user who should see a shared mailbox like this:
    doveadm acl debug -u [email protected] shared/users/box
    • Watch out for missing directories
    • Watch out for permission issues
    • Watch out for strangely created paths this could hint a misconfigured namespace prefix
Syndicate content