HNHacker News
TopNewBestAskShowJobs

gleitz

358 karma · joined January 14, 2011

Software engineer and senior fortune teller for Hunch. http://gleitzman.com
submissionscomments
gleitz··on Hacker Yoga – Part 0: Arms
<3 hackers <3 yoga
gleitz··on Howdoi – Instant Coding Answers via the Command Line
My worry is that not everyone will have python2.7 so I'd rather stick to "#!/usr/bin/env python". It would be great if this works but it doesn't

#!/usr/bin/env python2

gleitz··on Howdoi – Instant Coding Answers via the Command Line
Nice suggestions! We've got a whole list going on at https://github.com/gleitz/howdoi/issues
gleitz··on Howdoi – Instant Coding Answers via the Command Line
That's a nice search tool. I found that the relevance is not quite as good as Google (for example "howdoi get referrer url php") but this could be used when you enter a query that contains symbols.
gleitz··on Howdoi – Instant Coding Answers via the Command Line
Thanks!
gleitz··on Howdoi – Instant Coding Answers via the Command Line
Excellent. Fork away!
gleitz··on Howdoi – Instant Coding Answers via the Command Line
Does SO provide data dumps like Wikipedia?
gleitz··on Howdoi – Instant Coding Answers via the Command Line
I'm not familiar with the proper way to annotate that. How would I change the hashbang?

#!/usr/bin/env python

gleitz··on Howdoi – Instant Coding Answers via the Command Line
No way to currently contribute answers. Another commenter mentioned cheat.errtheblog.com that uses a wiki system. The downside is that when the wiki fails (like right now) the application breaks.

You may want to just submit a good answer to StackOverflow and make sure it is well written and gets lots of votes.

gleitz··on Howdoi – Instant Coding Answers via the Command Line
"howdoi wittgenstein" is the search of the day. Well done!
gleitz··on Howdoi – Instant Coding Answers via the Command Line
Indeed! If only my L1 cache were as large as my disk...
gleitz··on Howdoi – Instant Coding Answers via the Command Line
Ah yes I should clarify. -p2 picks the second search result from Google, not the second answer to the question.

$ howdoi format dates django templates -l

http://stackoverflow.com/questions/7737146/django-template-d...

$ howdoi format dates django templates -p2 -l

http://stackoverflow.com/questions/1180372/how-to-format-dat...

$ howdoi format dates django templates -p3 -l

http://stackoverflow.com/questions/4087717/django-template-d...

Another improvement might be to list the second and third answers to the currently selected question.

gleitz··on Howdoi – Instant Coding Answers via the Command Line
Thanks for playing with it. Sometimes the first answer isn't the greatest but -p2 or -p3 will get it. In this case the following command gets you closer:

howdoi format dates django templates -p3

Excellent idea for colorization! I've already got that suggestion on the github page -> https://github.com/gleitz/howdoi/issues/4

gleitz··on Howdoi – Instant Coding Answers via the Command Line
An enhancement I've been considering is noticing when users ask for a second or third answer with "-p2" or "-p3". If it happens often and the user never queries again after reading the second answer you can assume it is probably correct and display it to all users as the default response.
gleitz··on Howdoi – Instant Coding Answers via the Command Line
Although not user facing, there is also a DuckDuckGo search endpoint if you don't want to use Google for one reason or another.
gleitz··on Howdoi – Instant Coding Answers via the Command Line
Precisely! You can pass the "-a" flag to print the entire answer or "-l" to get the link itself. "-p2" will give the second answer.

I find myself using the following command quite a bit:

open `howdoi print stack trace python -l`

gleitz··on Howdoi – Instant Coding Answers via the Command Line
Why keep them in your brain when StackOverflow memorizes it for you?
gleitz··on Show HN: WikiMaze
I'll be writing a series of blog posts about the architecture of the game as well as more info about the API at http://blog.wikimaze.me/

At a high level you are mostly right. The incorrect answers are generated using http://www.freebase.com/ (now a Google product)

Lots of pages have to be thrown out, but after analyzing thousands of articles it was relatively straightforward to know when you had a good page versus a bad one.

gleitz··on Show HN: WikiMaze
Sure! You can go to the iframe directly at http://www.wikimaze.me/app
gleitz··on Show HN: WikiMaze
I'll be writing a blog post on the API soon. Stay tuned to http://blog.wikimaze.me
gleitz··on Show HN: WikiMaze
I would have thought that too, but I know there are some superfast edge servers that reroute to their datacenters.
gleitz··on Show HN: WikiMaze
If you want to keep your account "secure", login with Facebook, Twitter, or Google. I know that might turn some people off so I included the username login as well.

Future versions will let you set an optional password to "save" the username.

gleitz··on Show HN: WikiMaze
AppEngine all the way!
gleitz··on Show HN: WikiMaze
I hope it makes everyone filthy smart! It is running on App Engine so the server costs aren't too terrible.

Half of all the proceeds go to Wikipedia for providing such great questions.

https://venmo.com/gleitz?txn=pay&note=for+awesome+trivia...

gleitz··on Show HN: WikiMaze
I hope this will be a fun way for you to discover new and interesting articles.
gleitz··on Show HN: WikiMaze
If you guess incorrectly twice, it will show you the right answer. If you click a third time, it will take you to the Wikipedia article for that answer. Sounds like you got sent to the Wikipedia article but it didn't load?
gleitz··on Show HN: WikiMaze
It saves between 10-20 questions, but it could easily go much higher. The cache.manifest says "even if I am offline, still load the page". The localStorage is a database that holds the questions.

I'll be writing a series of blog posts about the architecture of the game, as well as more info about the API

http://blog.wikimaze.me/

gleitz··on Show HN: WikiMaze
It is also available as an app in the iTunes Store

http://itunes.apple.com/us/app/wikimaze-free/id475157639?ls=...

<3 HTML5 apps!

gleitz··on Show HN: WikiMaze
Great suggestion! Will add that in the next version
gleitz··on Show HN: WikiMaze
The questions are pulled live, but I save old q's so I don't have to crawl the same page twice.
Page 1 of 2Next →