Category Archives: English

No more TweetDeck for me, on AIR

I changed (once again) to awesome and AIR applications doesn’t work here.

One of the apps I heavily use based on AIR is TweetDeck. So I tried old clients that were once an alternative like HootSuite but not having support for both kind of RTs (Native and Quote) is a pain in the ass.

Then I remembered I installed once TweetDeck for Google Chrome on my browser and never give it a chance, because it was not exactly the same as the AIR-based app. Now it only lacks proper relation between followers and no-followers in each account when there are multiple accounts configured.

So yesterday was the day to try it, the right day.

It even has notification support, and customized by column!

ThinkPads and Amarok2 Multimedia Keys

I love Amarok, since the beginning. But I have had issues since I moved from awesome (and didn’t knew it was coincidence) with my multimedia keys.

Today I discovered a script called Gnome Multimedia Keys 2 for Amarok2 and now I got it working again, after trying with Banshee, Rhytmbox, Songbird, Exaile… I went back to Amarok :D

WordPress: URL change and cookies issues

I had a site under alpha.mydomain.tld and when I changed it to www.mydomain.tld I did it trough the Settings of WordPress without changing anything else.

I added the new domains to my nginx-configuration without removing the alpha subdomain and I got a lot of issues with WordPress cookies. By e.g., I logged in to /wp-admin, closed that tab and reopened in a while and I got to re-login, even if I set “Remember Me”.

After checking, re-change of URL and things like that I just removed the alpha subdomain from my nginx-configuration and everything got solved. Yes, is stupid, but it happens.

WordPress: Paginating with query_posts()

I discovered, in not a very amusing way that if you use query_posts() then the variables for paginating with The Loop stop working.

Fixing this is easy, just add to paged option on the array the variable $paged, in this way:

query_posts(
    'posts_per_page'    => 15,
    'paged'                 => $paged,
);

Or if you don’t use it like this, then:

query_posts('posts_per_page=15&paged=' . $paged);

After this, using posts_nav_link() actually works.

Dear Lazyweb: Arrange posts on WordPress by weight

I have searched all these days a WordPress plugin that let’s me arrange my posts by weight or some kind of score system so I can do something like:

query_posts('category_name='.$current_category.'&posts_per_page=1&min_weight=80&max_weight=100');

Then only shows the last post with a weight between 80 and 100, and so on.

Any clue of any plugin that does anything at least similar?

413: Request Entity Too Large with nginx

I’m working on a big site, importing a lot of files to a WordPress installation and started to get a bunch of 413′s. After a little bit of googling I found out what was happening:

What needs to be done is on /etc/nginx/nginx.conf write:

http {
    client_max_body_size 20M;
    include       /etc/nginx/mime.types;
    A LOT MORE SETTINGS...

Yes, just add client_max_body_size and restart your webserver. This by default is 1M, so anything beyond this will be refused.

snipmate.vim snippets

I’m a long-time snipmate.vim user and I’ve been adding occasionally some snippets to it, and today I want to share it to everyone who may be interested on using them.

All of them are CSS3, Javascript and HTML5 related, plus 2 (or something) for PHP+WordPress.

Anyway, if any of you use WordPress+PHP and use snippets please, let me know. I’m working on WordPress these days and some snippets would help me a lot.

You can download my snippets from my github, hope its useful for anyone.

WordPress update 3.0.4

Fixes XSS vulnerabilities, please update your blog if you use WordPress.

See more…

Follow-up[2]: pino-0.3+librest (and not cmake, at all)

So, after having troubles while trying to compile pino-0.3 it turns out is has nothing to do with cmake, nor with librest not shipping gir files but with vala bindings and incompability between those bindings from rest-0.6 and rest-0.7. So if I really want to compile pino-0.3 I have two options: use rest-0.6 or update rest.vapi for vala and send a patch for pino-0.3 to get a working code with rest-0.7 and it’s new vala bindings…

But there’s not enough free time for me this holidays so, maybe next time :-/

Anyway, thanks to all those who helped :)

Follow-up: pino0.3+cmake (and now librest)

Last night I made some changes to what I made for compiling pino0.3: patched CMakeLists.txt so uses rest-0.7 and rest-extras-0.7 and now the last issue is not a problem anymore, but now the error is that can’t found them while compiling (here’s in paste.debian if you can’t see it nicely formatted):

/usr/bin/cmake -E cmake_progress_report "/tmp/buildd/pino-0.3+hg~20101225/obj-i486-linux-gnu/CMakeFiles" 47
[  2%] Generating src/stream_abstract.c, src/globals.c, src/twitter_favorites_stream.c, src/meta_row.c, src/search_interface.c, src/search_dialog.c, src/text_input.c, src/template.c, src/identica_create_dialog.c, src/updates_cell_renderer.c, src/stream_state.c, src/twitter_stream_mentions.c, src/accounts.c, src/accounts_types.c, src/main.c, src/hig_table.c, src/main_window.c, src/twitter_parser.c, src/twitter_recursive_reply.c, src/utils.c, src/identica_account.c, src/settings.c, src/visual_style.c, src/status_choose_bar.c, src/time_utils.c, src/status_box.c, src/menu_indicator.c, src/account_abstract.c, src/stream_meta.c, src/streams_types.c, src/content_view.c, src/img_cache.c, src/tree_widget.c, src/twitter_stream_public.c, src/icon_with_status_cell_renderer.c, src/account_state.c, src/create_dialog_generic.c, src/twitter_create_dialog.c, src/twitter_stream_abstract.c, src/status.c, src/twitter_stream_home.c, src/twitter_account.c, src/pino_enums.c, src/twitter_stream_search.c
/usr/bin/valac -C -b /tmp/buildd/pino-0.3+hg~20101225 -d /tmp/buildd/pino-0.3+hg~20101225/obj-i486-linux-gnu --pkg=glib-2.0 --pkg=gobject-2.0 --pkg=gtk+-2.0 --pkg=gee-1.0 --pkg=gio-2.0 --pkg=libnotify --pkg=libsoup-2.4 --pkg=libxml-2.0 --pkg=webkit-1.0 --pkg=unique-1.0 --pkg=rest-0.7 --pkg=rest-extras-0.7 --thread -g --save-temps -D LIBINDICATE /tmp/buildd/pino-0.3+hg~20101225/src/stream_abstract.vala /tmp/buildd/pino-0.3+hg~20101225/src/globals.vala /tmp/buildd/pino-0.3+hg~20101225/src/twitter_favorites_stream.vala /tmp/buildd/pino-0.3+hg~20101225/src/meta_row.vala /tmp/buildd/pino-0.3+hg~20101225/src/search_interface.vala /tmp/buildd/pino-0.3+hg~20101225/src/search_dialog.vala /tmp/buildd/pino-0.3+hg~20101225/src/text_input.vala /tmp/buildd/pino-0.3+hg~20101225/src/template.vala /tmp/buildd/pino-0.3+hg~20101225/src/identica_create_dialog.vala /tmp/buildd/pino-0.3+hg~20101225/src/updates_cell_renderer.vala /tmp/buildd/pino-0.3+hg~20101225/src/stream_state.vala /tmp/buildd/pino-0.3+hg~20101225/src/twitter_stream_mentions.vala /tmp/buildd/pino-0.3+hg~20101225/src/accounts.vala /tmp/buildd/pino-0.3+hg~20101225/src/accounts_types.vala /tmp/buildd/pino-0.3+hg~20101225/src/main.vala /tmp/buildd/pino-0.3+hg~20101225/src/hig_table.vala /tmp/buildd/pino-0.3+hg~20101225/src/main_window.vala /tmp/buildd/pino-0.3+hg~20101225/src/twitter_parser.vala /tmp/buildd/pino-0.3+hg~20101225/src/twitter_recursive_reply.vala /tmp/buildd/pino-0.3+hg~20101225/src/utils.vala /tmp/buildd/pino-0.3+hg~20101225/src/identica_account.vala /tmp/buildd/pino-0.3+hg~20101225/src/settings.vala /tmp/buildd/pino-0.3+hg~20101225/src/visual_style.vala /tmp/buildd/pino-0.3+hg~20101225/src/status_choose_bar.vala /tmp/buildd/pino-0.3+hg~20101225/src/time_utils.vala /tmp/buildd/pino-0.3+hg~20101225/src/status_box.vala /tmp/buildd/pino-0.3+hg~20101225/src/menu_indicator.vala /tmp/buildd/pino-0.3+hg~20101225/src/account_abstract.vala /tmp/buildd/pino-0.3+hg~20101225/src/stream_meta.vala /tmp/buildd/pino-0.3+hg~20101225/src/streams_types.vala /tmp/buildd/pino-0.3+hg~20101225/src/content_view.vala /tmp/buildd/pino-0.3+hg~20101225/src/img_cache.vala /tmp/buildd/pino-0.3+hg~20101225/src/tree_widget.vala /tmp/buildd/pino-0.3+hg~20101225/src/twitter_stream_public.vala /tmp/buildd/pino-0.3+hg~20101225/src/icon_with_status_cell_renderer.vala /tmp/buildd/pino-0.3+hg~20101225/src/account_state.vala /tmp/buildd/pino-0.3+hg~20101225/src/create_dialog_generic.vala /tmp/buildd/pino-0.3+hg~20101225/src/twitter_create_dialog.vala /tmp/buildd/pino-0.3+hg~20101225/src/twitter_stream_abstract.vala /tmp/buildd/pino-0.3+hg~20101225/src/status.vala /tmp/buildd/pino-0.3+hg~20101225/src/twitter_stream_home.vala /tmp/buildd/pino-0.3+hg~20101225/src/twitter_account.vala /tmp/buildd/pino-0.3+hg~20101225/src/pino_enums.vala /tmp/buildd/pino-0.3+hg~20101225/src/twitter_stream_search.vala /tmp/buildd/pino-0.3+hg~20101225/src/vapi/config.vapi
error: rest-0.7 not found in specified Vala API directories or GObject-Introspection GIR directories
error: rest-extras-0.7 not found in specified Vala API directories or GObject-Introspection GIR directories
Compilation failed: 2 error(s), 0 warning(s)
make[3]: *** [src/stream_abstract.c] Error 1
make[3]: Leaving directory `/tmp/buildd/pino-0.3+hg~20101225/obj-i486-linux-gnu'
make[2]: *** [CMakeFiles/pino.dir/all] Error 2
make[2]: Leaving directory `/tmp/buildd/pino-0.3+hg~20101225/obj-i486-linux-gnu'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/tmp/buildd/pino-0.3+hg~20101225/obj-i486-linux-gnu'
dh_auto_build: make -j1 returned exit code 2
make: *** [build] Error 2
dpkg-buildpackage: error: debian/rules build gave error exit status 2
E: Failed autobuilding of package
I: unmounting /var/cache/pbuilder/ccache filesystem

I checked and found out that librest doesn’t ships the gir files so downloaded sources for librest and made a patched version that ships gir files (rest and rest-extras) but nothing changed.

Any suggests, anyone?