Necoro’s Blog

Blog? Blog? There is no blog…

Matching web-fonts with fontconfig

with 2 comments

I had a small issue today: A font used on a webpage and loaded via CSS was not rendered as it should be. I searched quite some time to find out if it is matched by font-config, and if so, how. So here is the answer: it is matched against the name defined in the CSS prepended by a @font-face:. With this I was able to add stuff like the following to my ~/.fonts.conf:

<match target="font">
  <test name="family">
    <string>@font-face:Thesis</string>
  </test>
  <edit name="hintstyle" mode="assign">
    <const>hintslight</const>
  </edit>
 </match>

Written by Necoro

April 29, 2013 at 22:30

Posted in Howtos

Tagged with , , ,

moztmp update

leave a comment »

Someone has obviously discovered my old post about moving the .mozilla directory of firefox into RAM. Unfortunately it did not work anymore and I also stopped using it (one reason: well – it did not work, second reason: my computer was quite unstable for some time and thus I lost quite often my FF-data).

But now I took the time to look into it and fix it. I also moved it from bzr to git: It can now be found at github.

Feel free to play around with it. And if you want to add nice features: do so. Remember that it is quite easy to fork and push-back repositories with git and github :)

Written by Necoro

March 14, 2011 at 21:01

Posted in Gentoo

Tagged with , ,

Portato 0.14.1 released

leave a comment »

Well … it probably won’t hurt to announce it here too:

Because of some API-changes in portage, I had to release a bugfix release for portato. And well … it is called 0.14.1 as you might have guessed :P

At the moment I am not developing portato actively. This is partly due to lack of time and partly due to lack of interest. The latter one is especially created by the fast-changing portage (which is in itself a nice thing), where I can’t keep step with w/o needing to spend tons of time in it.

Written by Necoro

September 8, 2010 at 22:37

Posted in Gentoo, Portato

Tagged with ,

Portato 0.14 released

leave a comment »

“Was lange währt, wird gut” is the German saying (the dictionary tells me “Good things come to those who wait.” is the English translation) — hopefully this applies for this version of Portato too.

The changes:

  • NEW: allow eix as backend DB
  • NEW: show the list of world packages
  • NEW: allow to search descriptions
  • NEW: add an icon to signal the ‘best’ version for a package
  • CHANGE: use an internal messagequeue module instead of external shm
  • FIX: bugmail sending
  • I18N: Italian translation – thanks to Ponsi
  • I18N: French translation – thanks to Clément ‘moonpyk’ Bourgeois

Personally, I find the addition of the eix-backend the most important improvement. This now allows fast startup and fast searching. Additionally the long awaitened feature of searching descriptions is only possible here (implementing it with other backends would make the startup sloooooooow).

So – let’s hope that the bugs are on vacation. :) — And a big thanks to idl0r for adding it to the portage tree in no time.

Written by Necoro

May 12, 2010 at 00:41

Posted in Gentoo, Portato

Tagged with ,

Subscribing to Google Group without needing a Google account

leave a comment »

More and more projects host their mailinglists on google groups. This is nothing bad per se. But it is not quite easy to find out how one can subscribe there w/o needing a google account. But it is easy: If the mailinglist you want to subscribe to is named foo-bar@googlegroups.com, you just have to send a normal subscription message (i.e. an empty one) to foo-bar+subscribe@googlegroups.com.

This is also documented on Google, but somewhat hidden.

Hopefully someone finds this useful :)

Written by Necoro

April 21, 2010 at 21:11

Posted in Howtos

Tagged with ,

Portato’s homepage moved to own server

leave a comment »

Up until now, the web home for Portato was at http://portato.origo.ethz.ch — but although the Origo-platform was promising during the start (and has been a nice alternative to Sourceforge), several problems appeared (I won’t repeat them here, as I already wrote about them in this post).

I started to look for a new home, but could not find a pre-hosted solution. Thus (and as I happened to have rented a virtual server) I decided to host it on my own. So I was able to use the software I liked etc. Well … finding the ‘right’ software was not as easy as I thought ^^… I am now settled with running web.py as the web framework and Mako. But, as I’m only serving more or less static sites, getting rid of web.py and using some tool to generate static pages from the mako templates is also a nice idea… Perhaps I’ll do something in this direction later (if I find a nice tool doing all the work :P).

Oh – btw: The new home for portato is: http://necoro.eu/portato – bugs are going to be hosted on launchpad (this is no final decision either) … and I decided, that there is no need for a wiki.

Written by Necoro

April 9, 2010 at 00:50

Posted in Portato

Tagged with , , , , ,

Managing your configuration files with Git and StGit. Revisited #2

leave a comment »

Ok … I wrote about using Git and StGit and about how I ditched StGit and used plain Git. So – just a short update: I reverted back to using StGit :D. I updated the two mentioned posts.

Oh – and for my convenience, I wrote a “small” function in zsh which does the “pop, commit, push, push” cycle needed if you want to have a patch applied directly in Git and not in StGit. You can find it here (function “cci”) … or below.

cci ()
{
    if [[ $# == 0 ]]; then
        echo "No message given. Aborting."
        return 1
    fi

    local message=$1
    local tok=__cci__

    pushd -q ~

    cstg diff
    echo -n "Is this ok? [y/n] "
    
    if ! read -q; then
        echo
        echo "I would have done the wrong thing ... aborting!"
        return 2
    fi

    echo ">> Creating new patch"
    cstg new $tok -m "$message"
    
    echo ">> Refreshing"
    cstg refresh

    if [[ -z $(cstg files) ]]; then
        echo
        echo "Ehm - this patch is empty. Narf. Aborting!"
        echo "Deleting useless patch"
        cstg del $tok
        return 3
    fi

    echo ">> Committing"
    cstg commit $tok
    
    if [[ -n $(cstg series --applied) ]]; then
        echo
        echo "Urgs! Something went wrong. There are still patches applied."
        echo "Clean up for yourself. Aborting here!"
        return 4
    fi
    
    echo ">> Pushing to remote"
    config push

    echo ">> Re-apply patches"
    cstg push -a

    echo ">> Done"

    popd -q
}

Written by Necoro

March 27, 2010 at 15:28