Software

[Bluetooth] Failed to connect: org.bluez.Error.Failed

Error after removing then reconnecting my Bluetooth dongle. The culprit was PulseAudio, which needed to be restarted:

$ pulseaudio -k
# re-do bluetoothctl stuff (may not be needed)
$ pulseaudio --start

Unreadable tiny names in LibreOffice Calc sheet tabs

Tiny sheet tabs

This issue happens in LibreOffice 4.3 and older with some desktop themes. To solve this, either change your desktop theme or increase the value of GtkScrollbar::slider_width in the file /usr/share/themes//gtk-2.0/gtkrc. In my case, the line was commented out. Activating it with the default value did the trick.

gtkrc edit

Restart LibreOffice Calc to see the result:

Readable sheet tabs

Source

Pacman: use regex to install multiple packages

Say I want to install all the packages starting with 'festival'. Using a wildcard throws an error, as well as using a regex, quoted or not:

$ sudo pacman -S festival*
error: target not found: festival*
$ sudo pacman -S 'festival.*'
error: target not found: festival.*
$ sudo pacman -S '^festival'
error: target not found: ^festival

And it is perfectly normal... since this is not implemented!

One solution is to pipe the result of a search query, which does support regex:

$ pacman -Ssq '^festival' | sudo pacman -S -
resolving dependencies...
looking for conflicting packages...

Packages (3) festival-2.1-5  festival-english-2.4-1  festival-us-2.4-1
[...]

Hide Vimperator bottom bar

Vimperator bottom bar

Copy the following snippet in your Vimperator configuration file (mine is ~/.vimperatorrc):

map <silent> <C-F8> :js toggle_bottombar()<CR>

:js << EOF
function toggle_bottombar() {
  var bb = document.getElementById('liberator-bottombar');
  if (!bb)
    return;
  bb.style.height = (bb.style.height == '') ? '0px' : '';
  bb.style.overflow = (bb.style.height == '') ? '' : 'hidden';
}
EOF

Restart Firefox, then type ctrl+F8 to hide/show the bottom bar. As the author warns, you must first make the bar visible in order to execute commands.

This is useful to me when watching a video in fullscreen because the bar is always on top.

Source

GNU/Linux: read-only file system error when accessing FAT/FAT32 drive

Sometimes and for no obvious reason, I suddenly cannot write or delete a file located on a removable USB drive using a FAT file system. Having no knowledge about all the magic going on under file system operations, I can just observe that some actions previously done successfully on some drives are no longer possible!

$ rm -r /path/to/some/obsolete/data/*
rm: cannot remove '/path/to/some/obsolete/data/data1': Read-only file system

It happened a few times in the previous years and I think it always involved FAT, but this is maybe not limited to that file system. We can easily solve this issue by running fsck, in this case in the form of its vfat variant:

$ sudo fsck.vfat -a /dev/sdc1

Replace /dev/sdc1 with your rebellious partition. The -a flag tells fsck to automatically repair the file system. The man page warns to use this feature with caution. You may prefer the -r flag which makes fsck asking you confirmation.

Note that fsck comes with lot of flavors, such as fsck.ext2|3|4, fsck.msdos, fsck.nfs... You may have to install some of them depending on your GNU/Linux distribution.