News for hackers. Stuff that matters.
Re:Ask HN: Little things/tools that improved your work or li... by kirubakaran on Saturday October 10, 2009 @01:48PM (#873541)
Every time I learn something about Emacs or incorporate someone's nifty elisp code, it pays off and keeps paying.

Latest:

  ; CSS color values colored by themselves
  ; http://xahlee.org/emacs/emacs_html.html
  
  (defvar hexcolour-keywords
    '(("#[abcdef[:digit:]]\\{6\\}"
       (0 (put-text-property
           (match-beginning 0)
           (match-end 0)
           'face (list :background 
                       (match-string-no-properties 0)))))))
  
  (defun hexcolour-add-to-font-lock ()
    (font-lock-add-keywords nil hexcolour-keywords))
  
  (add-hook 'css-mode-hook 'hexcolour-add-to-font-lock)
Re:Ask HN: Little things/tools that improved your work or li... by jacquesm on Saturday October 10, 2009 @03:40PM (#873725)
Until you pick one that has the background colour by accident!

Be weird to see that floating semicolon in there.

Re:Ask HN: Little things/tools that improved your work or li... by kirubakaran on Saturday October 10, 2009 @05:52PM (#873906)
The #rrggbb text is still displayed with normal text color. So it will never look like a floating semicolon. Try it. It is not even a problem when #rrggbb color is same as the foreground, as I have (global-hl-line-mode 1)
Re:Ask HN: Little things/tools that improved your work or li... by gruseom on Saturday October 10, 2009 @03:32PM (#873713)
Clever idea! Now I want to hear about some of your other favorites.
Re:Ask HN: Little things/tools that improved your work or li... by kirubakaran on Saturday October 10, 2009 @05:54PM (#873911)
Thank you. [re:Favorites] The best I can do for now: http://github.com/ki/my-dot-emacs/blob/master/dot-emacs.txt
Re:Ask HN: Little things/tools that improved your work or li... by mapleoin on Saturday October 10, 2009 @06:38PM (#873970)
.txt?
Re:Ask HN: Little things/tools that improved your work or li... by kirubakaran on Saturday October 10, 2009 @06:47PM (#873977)
Just a name :) It is ~/.emacs in my machine.

http://github.com/ki/my-dot-emacs/raw/master/dot-emacs.txt

Re:Ask HN: Little things/tools that improved your work or li... by jrockway on Saturday October 10, 2009 @08:38PM (#874103)
You might prefer to manage your dotfiles with something like:

http://github.com/jrockway/dotfiles/tree/master/bin

Re:Ask HN: Little things/tools that improved your work or li... by kirubakaran on Saturday October 10, 2009 @08:53PM (#874122)
Cool. Thanks!