Danmarks weblog-portal - søg, find og følg med i den danske blogosfære
pinds.com
spiritual entrepreneurship, personal growth, internet, food, politics.
- Website
-
http://pinds.com/
Glyphicons for Rails
I love using Jan Kova?ík’s Glyphicons in my web app. So much so that I’ve created a set of helpers to allow me to say things like 1 <%= glyphicon :remove %> and 1 <%= link_to_glyphicon :remove, ? %> Here’s the code. You’ll find: A Rake task to create the required data structures. The output of that Rake task (glyphicons.rb). And finally the helper that allo
af Lars Pind
Gasping and talking and sharing
Seth Godin over at The Domino Project: But the most important thing an author can do is write a breakthrough book, one that makes readers gasp and talk and share. And the second most important thing an author can do is build a tribe, a significant connection with a growing number of people.
af Lars Pind
Smart, patient and confident
PandoDaily on Mark Zuckerberg in the light of today’s Facebook S-1 filing: Zuckerberg didn?t just wait. He obsessively learned what being a CEO was about. He surrounded himself by people who had strengths he didn?t and absorbed from them like a sponge. Unlike nearly every other Internet wunderkind who came before him, he didn?t hire the grown-up to run the company. He became the grown-up to
af Lars Pind
Here?s to the crazy ones ? Spiritual Entrepreneurship North America Tour 2012
Four and a half years ago, I started my “spiritual path”, with the help of a teacher who had worked closely with Eckhart Tolle. During that process, I had the big realization that the things I learned about life through that spiritual work was directly relevant to my life as an entrepreneur. And thus, my concept of spiriutal entrepreneurship was born. So what does “spiritual entr
af Lars Pind
Flying
About a year ago (a year minus three days to be exact), I boarded a plane from Denmark to the US. Right now, I’m sitting on a plane, making the same trip. Back a year ago, I left my wife and two kids to make a new life for myself in the US. Not that I wanted to leave my kids. I still don”t. About ten years ago, I lived in the US for a two and a half years with my then girlfriend, now e
af Lars Pind
Find all ruby files with special characters that don?t yet have the # encoding magic comment set
I’m playing with upgrading zenbilling to Ruby 1.9.3, and need to add the magic encoding comment to the source files that need it. Here’s my poor man’s way of doing it in the shell: grep "[ÆØÅæøå]" `grep -rL "^# encoding" ./**/*.rb` It’s searching for the presence of one of the Danish characters in any ruby file that doesn’t have the # encoding magic comment. I guess I
af Lars Pind
Fixing IE gradients with Rails 3.1 and SCSS
I kept getting my CSS gradients in IE 9 messed up by the Rails 3.1 Asset Pipeline. The symptom was that the colors were off – way off! Like purple instead of white or gray. It took me several hours to get this to work, so I figured I’d share the solution. The colors were off because IE’s progid:DXImageTransform.Microsoft.gradient filter doesn’t understand normal CSS colors
af Lars Pind
Show error traces in production in Rails 3.1
I wanted to be able to see error traces in the browser when I’m the one visiting. Here’s my hack, dropped into config/initalizers/ 1 2 3 4 5 6 7 if Rails.env == 'production' class ActionDispatch::Request def local? App.developer_ips.include?(remote_ip) end end end App.developer_ips is an array of IP addresses that I typically work from.
af Lars Pind
Logging in production with Rails
I use the Rails server logs primarily to dig through a user’s interaction with the site across requests to track down intricate bugs, like how did the user manage to get the system into this state which it shouldn’t be in. But using the default Rails logs to do this piece of detective work is horrible. I’m using the Hodel3000CompliantLogger, which prefixes each log line with the
af Lars Pind
