lunedì 23 novembre 2009

Eclipse Fullscreen plugin

I'm using a plugin really useful: code.google.com/p/eclipse-fullscreen.

Some months ago i've configured gnome to force fullscreen mode to the foreground window pressing alt+f11: with gconf-editor go to /apps/metacity/window_keybindings/ and configure key binging for toggle_fullscreen. That was really necessary for my 10'' netbook (Dell Mini 10v).

But this is a generic solution, for example the fullscreen mode of firefox is far better than using metacity fullscreen (it makes disappear not only the window border, but also the navigation menu, the toolbar and the status bar).
For eclipse is almost the same: metacity fullscreen is really good, but the plugin rocks!

And a useful collateral effect is that in fullscreen mode i do not receive all the notifications from gnome (liferea, updates, rhythmbox..) and i can really get into my "coding flow"..

lunedì 9 novembre 2009

[HOWTO] Trac AccountManagerPlugin

I've just installed AccountManager Trac plugin in one of my trac instances (in this howto i will name it "xyz").


repo:/tmp# svn co http://trac-hacks.org/svn/accountmanagerplugin/0.11 .
repo:/tmp# cd 0.11
repo:/tmp/0.11# python setup.py bdist_egg
repo:/tmp/0.11# cd dist/
repo:/tmp/0.11/dist# mv TracAccountManager-*.egg /path/to/trac/xyz/plugins/


In xyz/conf/trac.ini i have added:


[components]
trac.web.auth.LoginModule = disabled
acct_mgr.web_ui.LoginModule = enabled
acct_mgr.web_ui.RegistrationModule = disabled
acct_mgr.web_ui.emailverificationmodule = disabled
acct_mgr.htfile.HtPasswdStore = enabled

[account-manager]
password_store = HtPasswdStore
password_file = /path/to/trac/xyz/conf/trac.htpasswd


Then i had to edit my apache httpd configuration. On this server i run several trac instances (with the TracEnvParentDir set to /path/to/trac/ ) so my login configuration was:


<Location "/trac/*/login">
    AuthType Basic
    AuthName "Login"
    AuthUserFile /etc/httpd/conf/htpasswd
    Require valid-user
</Location>


Then it became:


<Location ~ /trac/(?!xyz)*/login">
    AuthType Basic
    AuthName "Login"
    AuthUserFile /etc/httpd/conf/htpasswd
    Require valid-user
</Location>


Adding that regex, now i exclude from this directive the path /trac/xyz/login.
Consequently the form login (handled by the AccountManagementPlugin) is only available in xyz instance (with a reserved password file), while the others (including future ones) will use the apache basic authentication.