Apr 26 2009

Twitter Weekly Updates for 2009-04-26

Manfred Pürro @ 16:40
  • Share/Bookmark

Tags:


Apr 20 2009

PHP Devel with Emacs: Syntax errors

Manfred Pürro @ 10:17

While developing it’s nice to have a on-the-fly syntax checker. With emacs thats quite easy. Just add the following to your .emacs


;; Flymake PHP Extension

"(provide 'flymake-php)"

(require 'flymake)

(defun flymake-php-init ()
"Use php to check the syntax of the current file."
(let* ((temp (flymake-init-create-temp-buffer-copy 'flymake-create-temp-inplace))
(local (file-relative-name temp (file-name-directory buffer-file-name))))
(list "php" (list "-f" local "-l"))))

(add-to-list 'flymake-err-line-patterns
'("\\(Parse\\|Fatal\\) error: +\\(.*?\\) in \\(.*?\\) on line \\([0-9]+\\)$" 3 4 nil 2))

(add-to-list 'flymake-allowed-file-name-masks '("\\.php$" flymake-php-init))

(add-hook 'php-mode-hook (lambda () (flymake-mode 1)))
(define-key php-mode-map '[M-S-up] 'flymake-goto-prev-error)
(define-key php-mode-map '[M-S-down] 'flymake-goto-next-error)

and there you are…
emacs-flymake-phpmp-t400

If you now have a syntax error, flymake tells you by highligting the line in red! (here it’s a missing ‘)’.

Have fun

  • Share/Bookmark

Tags: , , ,


Apr 19 2009

Twitter Weekly Updates for 2009-04-19

Manfred Pürro @ 16:40
  • BBQ at my future house… Feeling great after a looong day. #
  • Joikuspot.com turns you phone into a mobile wlan access point. Features i love on a real phone… #
  • Phidget rfid reader arrived… Yay… Can’t wait to play with it… Anyone wants to lend me his rfid passport? :P #
  • http://twitpic.com/3iof6 – Yeeeeeaaaaahhh!!! Damn thing is running again. Summer can come #
  • Share/Bookmark

Tags:


Apr 12 2009

Twitter Weekly Updates for 2009-04-12

Manfred Pürro @ 16:40
  • listens to johndoetale, come to their CD launch in BadBonn on 2 Mai http://is.gd/r9WG #
  • RT @webmardi. tonight is the night! showmasters are getting ready.. the audince is eager.. come and join us at http://liip.to/web_of_things #
  • failing again with flux, at least i almost getting used to it… #
  • dear Flux, i hate you. I don’t wanna play with you anymore… let’s go out und buy some beer for tonights webmardi #
  • i think that’s the uglies, most stupid car i’ve ever seen http://twitpic.com/2yla4 #
  • Just bought a new phone. Nokia e71 rocks. Using twittix for mobile twittering. Ou how i missed a real keyboard… #
  • E71 a real phone. Voip preinstalled and multitasking of course. i get a notice on new tweets if i want. Sry iphone, too much restrictions #
  • Just visited my new flat. can begin moving in next week already. Great. Welcome you old house with garden… #
  • Share/Bookmark

Tags:


Apr 08 2009

Gnu/Linux with a MS Natural Ergonomic 4000 Keyboard

Manfred Pürro @ 13:58

Hello folks. Just some little Infos und how to get the special keys of the Microsoft Natural Ergonomic 4000 Keyboard running under linux. There is a handy tool called xbindkeys to do such things. with xbindkeys you can find out the keycodes for every button you like… Just type “xbindkeys -k” into terminal and press the button you want to know the keycode for… The code then gets printed in the Terminal…

All you have to do now is to extend the .xbindkeysrc file in your home directory (create it if it’s not already there).
In this File you put in the Command you want to launch an associate it with the keycode.
Like this:

What? Example of Line in .xbindkeysrc
Comment ;-) # Microsoft Ergonomic 4000 Web/Home Button
Command “firefox”
Keycode m:0×10 + c:180

now start xbindkeys in your terminal… and voila… key bound to your custom command :-D

If you use Gnome you could now add xbindkeys to autolaunch (Its in System->Settings->Session).
For your convienience i’ll provide you my custom .xbindkeysrc. It has also a binding for the ThinkVantage Button on a Thinkpad T400 (it launches a terminal now ;-) )

put the following into .xbindkeysrc in your home directory!

#
# Custom .xbindkeysrc
#
# .xbindkeysrc from http://www.puerro.net/2009/04/linux-ms-natural-ergonomic-4000-keyboard/

# Microsoft Ergonomic 4000 Favorite 1
"emacs"
m:0x10 + c:192

# Microsoft Ergonomic 4000 Favorite 2
"thunar"
m:0x10 + c:193

# Microsoft Ergonomic 4000 Favorite 3
"gnome-terminal"
m:0x10 + c:194

# Microsoft Ergonomic 4000 Favorite 4
#"gnome-terminal"
# m:0x10 + c:195

# Microsoft Ergonomic 4000 Favorite 5
"gnome-terminal"
m:0x10 + c:196

# Microsoft Ergonomic 4000 Web/Home Button
"firefox"
m:0x10 + c:180

# Sroll Lock becomes Screen Lock ;-)
"gnome-screensaver-command --lock"
m:0x10 + c:78

#mp 04.01.2008 thinkpad button
"gnome-terminal"
m:0x0 + c:156

# see http://www.puerro.net/2009/02/thinkpad-t400-switching-monitors/
#automatic xrandr yai... Alt+F6
"/home/mp/scripts/detectvga.sh"
m:0x18 + c:72

Have Fun! :-D

  • Share/Bookmark

Tags: , ,


Apr 06 2009

webmardi fribourg: second edition

Manfred Pürro @ 7:39

Morgen am 7. April 2009 findet nun  der zweite webmardi statt. Das Thema ist diesmal Web of Things präsentiert von Vlad Trifa und Dominique Guinard.
Diesmal treffen wir uns wieder in den Liip Büro’s an der Fonderie 7 in Fribourg.

Eine gute Gelegenheit zum kennenlernen neuer Themen und neuer Leute (aka Networking :-P ) aus dem Web.  Mehr Informationen wie immer auf dem webmardi wiki.

Ein gemütliches Apero, ein kleiner Vortrag und danach eventuell ein Bier im Transformateur… Es gibt also nicht s zu verlieren. Die erste Edition war ein voller Erfolg, lasst auch die zweite zu einem Erfolg werden. Insgesamt eine gute Sache fürs Web in Fribourg.

Die dritte Edition im Mai wird dann voraussichtlich von Xavier Bertschy gehosted. Für diesen Event brauchts noch Themen. Wenn Du also eine gute Idee hast melde dich beim Master of webmardi Pierre Spring.

Ich freue mich euch am webmardi begrüssen zu dürfen.

bis dann, Manfred Pürro

  • Share/Bookmark

Tags: , ,


Apr 05 2009

Twitter Weekly Updates for 2009-04-05

Manfred Pürro @ 16:40
  • Share/Bookmark

Tags: