<?pypixml version="1.0" encoding="UTF-8"?>
<feed
  xmlns="http://www.w3.org/2005/Atom"
  xmlns:thr="http://purl.org/syndication/thread/1.0"
  xml:lang="en"
   >
  <title type="text">/code - a blog</title>
  <subtitle type="text">Programming 'n stuff</subtitle>

  <updated>2012-01-15T22:32:41Z</updated>
  <generator uri="http://blogofile.com/">Blogofile</generator>

  <link rel="alternate" type="text/html" href="http://asktherelic.com/code" />
  <id>http://asktherelic.com/code/feed/atom/</id>
  <link rel="self" type="application/atom+xml" href="http://asktherelic.com/code/feed/atom/" />
  <entry>
    <author>
      <name></name>
      <uri>http://asktherelic.com/code</uri>
    </author>
    <title type="html"><![CDATA[Interesting Trends in Vim]]></title>
    <link rel="alternate" type="text/html" href="http://asktherelic.com/2012/01/15/interesting-trends-in-vim" />
    <id>http://asktherelic.com/2012/01/15/interesting-trends-in-vim</id>
    <updated>2012-01-15T14:31:28Z</updated>
    <published>2012-01-15T14:31:28Z</published>
    <category scheme="http://asktherelic.com/code" term="Vim" />
    <summary type="html"><![CDATA[Interesting Trends in Vim]]></summary>
    <content type="html" xml:base="http://asktherelic.com/2012/01/15/interesting-trends-in-vim"><![CDATA[<p>Something I've noticed lately with vim plugins are that miniscripts and smaller vim tweaks, any sort of vim functionality, are being packaged and shared as a proper vim plugins via git, not just big IDE style plugins. This may not be an entirely new idea, but I think it's becoming more of the norm to use pathogen and git submodules to share everything vim related, rather than copying and pasting actual code, I think the idea of managing everything via git, github, and git submodules is pretty neat.</p>
<ul>
<li>Thanks to <a href="https://github.com/tpope/vim-pathogen">Pathogen</a>, plugins can remain separate from your main configuration, which great decreases the friction of trying new plugins and keeping your existing plugins organized.</li>
<li>Thanks to git, plugins have revision history and stable versions (tags).</li>
<li>Thanks to github, plugins have easy and stable endpoints to install from, to get updates from, and to complain about for bugs. Additionally, forking makes it easy to fix bugs yourself or make any tweaks you want, while still keeping everything in git.</li>
<li>Thanks to <a href="http://vimcasts.org/episodes/synchronizing-plugins-with-git-submodules-and-pathogen/">git submodules</a>, you can store your list of installed vim plugins, update them when necessary, and share them between multiple machines.</li>
<li>With <a href="https://github.com/gmarik/vundle">vundle</a> or <a href="https://github.com/MarcWeber/vim-addon-manager">vim-addon-manager</a>, you can search and install new plugins, all from within vim.</li>
</ul>
<h3>The Theory</h3>
<p>My dotfiles and vimrc have been in source control for years. I've always kept a selection of vim plugins in my dotfiles repo, specific versions of plugins that I know work together. Pathogen was an easy switch and made it much easier to try new plugins and figure out if a new plugin played well with my current configuration.</p>
<p>With git submodules and keeping everything in git, I've come to realize, you get all of that and more. Want to try a new plugin? Download it to your vim bundle directory and give it a try. Git status will show you that it's an untracked directory and you haven't added it your dotfiles yet. When you decide you like it, you can add it as a submodule and checkout version X, which you know works correctly with your system. </p>
<p>Want to try out the latest dev version? Is there even a newer version to try? Pull latest in that plugin's git repo and see if there are updates. If you like those updates, commit the latest version in the git submodules, otherwise reset everything to the last known working state.</p>
<p>Want to fix something in the plugin? Like some new features, but want to keep some of the old features? Fork the plugin, delete the official submodule from your dotfiles, and checkout your fork as a submodule. Everything can remain in git still.</p>
<h3>The Practice</h3>
<p>One of the best examples I've seen recently was a <a href="http://stackoverflow.com/questions/8168320/can-vim-highlight-matching-html-tags-like-notepad">Stack Overflow question</a> a few months back. Someone asked how to add highlighting to paired html tags. The answer was a <a href="https://github.com/gregsexton/MatchTag">simple plugin</a> that added that exact functionality. Not source code or a link to a vim wiki, but a full plugin, that with the setup I just described, is a one-step process to try out.</p>
<p>I feel plugins have traditionally been complex things in vim, but by having this easy and module process available and understood, more cool plugins will be made. Looks like it's time to <a href="http://learnvimscriptthehardway.stevelosh.com/">Learn Vimscript the Hard Way</a> and start writing my own plugins now!</p>]]></content>
  </entry>
  <entry>
    <author>
      <name></name>
      <uri>http://asktherelic.com/code</uri>
    </author>
    <title type="html"><![CDATA[Backup Everything You Did Last Year]]></title>
    <link rel="alternate" type="text/html" href="http://asktherelic.com/2012/01/02/backup-everything-you-did-last-year" />
    <id>http://asktherelic.com/2012/01/02/backup-everything-you-did-last-year</id>
    <updated>2012-01-02T08:58:59Z</updated>
    <published>2012-01-02T08:58:59Z</published>
    <category scheme="http://asktherelic.com/code" term="Life" />
    <summary type="html"><![CDATA[Backup Everything You Did Last Year]]></summary>
    <content type="html" xml:base="http://asktherelic.com/2012/01/02/backup-everything-you-did-last-year"><![CDATA[<p>A habit I've developed over the last few years is to backup all of my online
artifacts and identities once the year ends. Maybe I'm just a bit paranoid, but
in this day and age with more and more things being stored in the cloud, control
and access to your data is being shifted to faceless servers and scripts that
can disconnect you quite easily with little recourse. Whether it's a TOS
violation, a change in a company's policy, or just <a href="http://mashable.com/2009/09/25/bank-sues-google/">something else
screwy</a>, it's not something to
worry about daily, but it's better to be prepared.</p>
<p>It's not all gloom and doom: having a local backup of your data is great for
searching and viewing in ways that the original provider didn't think about. I
think it's cool to be able see how emails I get year over year. A benefit of
being in this day and age is that storage is cheap: storing everything you've
ever created and done online is entirely possible.</p>
<h2>What To Backup</h2>
<p>I started out with emails and figuring out to organize things. I then moved onto
email contacts, chat logs, Delicious bookmarks, and social site data. As of
late, I've been working on receipts and finances, trying to move to toward
existing entirely paper free! Here are some ideas, feel free to add suggestions
in the comments.</p>
<ul>
<li>Email</li>
<li>Contacts (from GMail, Facebook, or LinkedIn)</li>
<li>Chatlogs (Adium)</li>
<li>Bookmarks (Delicious, Pinboard)</li>
<li>Social site data (Twitter, FB, LinkedIn, Google+, Reddit)</li>
<li>Pictures (Flickr, Picasa)</li>
</ul>
<h2>How To Backup</h2>
<p>Having a simple way to backup your data and having easy access to your data from
a website is also another important social topic that has come up the last
couple years. Having open APIs and an easy way to export your data is something
you should look for and if a website doesn't have one, you should ask why not.
Facebook didn't even have an export ability until the middle of 2010. Here some
sites and tools that I've been using to help me:</p>
<ul>
<li>
<p><a href="http://mail.google.com">Google Mail</a>:
  <a href="http://www.gmail-backup.com/">http://www.gmail-backup.com/</a> is my recommended
  tool for backing up GMail. Unfortunately it's closed source but the site has
  been around for years and the software has seemed reputable enough. It has a
  simple GUI or CLI interface that allows you to select date ranges to backup;
  all email from 2010, and it works for me.</p>
<p>Once you download the 0.107 version, you can backup all 2011 email with a command like this: (you might need an app password if you have 2-step auth enabled)</p>
<p><code>$ ./gmail-backup.sh backup email-2011 &lt;EMAIL&gt; &lt;PASSWORD&gt; 20110101 20111231</code></p>
</li>
<li>
<p>Gmail Contacts: While logged into GMail, you can go to the Contacts window and
  export your contacts in multiple formats.</p>
</li>
<li>
<p>All your Google data: Google is quite good about being open, but has a wide
  range of services, which don't all have the same ease of exportability. While
  logged in, go to
  <a href="https://plus.google.com/u/0/settings/exportdata">https://plus.google.com/u/0/settings/exportdata</a>
  and you should be able to backup your G+, Picasa, and most other data Google
  has on you.</p>
</li>
<li>
<p><a href="http://adium.im/">Adium</a> is an open source OSX chat client which keeps XML
  logs of all your conversations, which includes your FB and GChat accounts if
  you have them enabled. All logs should be kept at <code>~/Library/Application
  Support/Adium 2.0/Users/Default/Logs</code>. Since it's hard to pull out specific
  date ranged logs, I just back the whole log folder each year.</p>
</li>
<li>
<p><a href="http://pinboard.in/">Pinboard</a>: I switched from Delicious this year and have
  been quite happy with Pinboard for my online bookmarking needs. To export, go
  to <a href="http://pinboard.in/export/">http://pinboard.in/export/</a></p>
</li>
</ul>
<p>For most social sites, there is a lot of money in owning your data and every
site has a different obtuse backup policy. My friend
<a href="https://twitter.com/#!/synack">Jeremy</a> has created a one stop shop for easily
and safely backing up your data from FB, Twitter, LinkedIn, Gowalla, and Google+
which I would recommend: <a href="http://export.synack.me/">http://export.synack.me/</a></p>
<p>Another interesting idea for controlling your online data is what
<a href="https://www.greplin.com/">Greplin</a> provides: simple instant search of all your
online data. You can easily look across all of your data, although I don't think
exporting that data is something they offer.</p>
<h2>Final Thoughts</h2>
<p>Once you have all this data, don't skimp on your own physical backups. Storing
all of your financial and personal data unencrypted in one place is a hacker's
dream. This is something I am still exploring: I use OSX's built-in DMG
encryption, but that is not too portable. </p>
<p>Also look into <a href="https://www.dropbox.com/">Dropbox</a> for having access to your
data across all your machines or <a href="http://www.backblaze.com/">Backblaze</a> for
having a simple external backup of everything on your laptop.</p>]]></content>
  </entry>
  <entry>
    <author>
      <name></name>
      <uri>http://asktherelic.com/code</uri>
    </author>
    <title type="html"><![CDATA[2012 Python Meme]]></title>
    <link rel="alternate" type="text/html" href="http://asktherelic.com/2011/12/31/2012-python-meme" />
    <id>http://asktherelic.com/2011/12/31/2012-python-meme</id>
    <updated>2011-12-31T14:43:50Z</updated>
    <published>2011-12-31T14:43:50Z</published>
    <category scheme="http://asktherelic.com/code" term="Life" />
    <summary type="html"><![CDATA[2012 Python Meme]]></summary>
    <content type="html" xml:base="http://asktherelic.com/2011/12/31/2012-python-meme"><![CDATA[<p>I wanted to do some kind of reflection this year, so may as well hop on the bandwagon.</p>
<h3>What’s the coolest Python application, framework or library you have discovered in 2011?</h3>
<p><strong>Fabric</strong>. For a good six months of this year, I was managing everything
server-wise at my last job through Fabric and learned a good deal about it,
<a href="/2011/02/17/dynamic-fabric-commands-for-managing-cloud-servers/">hacking in some features</a> and
<a href="/2011/06/22/fabric-for-python-automation/">giving a presentation</a> on it at the
local <a href="http://pghpython.org/">Pittsburgh users group</a>. It's great to be able to
automate things and to have that ability in Python.</p>
<h3>What new programming technique did you learn in 2011?</h3>
<p>I can't think of a specific area I focused on, but overall: I've broaden my
knowledge of Python unit testing, deployment, and project packaging. I've also
ben diving deep into background processing with
<a href="http://celeryproject.org/">Celery</a> lately, which really interests me.</p>
<h3>What’s the name of the open source project you contributed the most in 2011? What did you do?</h3>
<p>Unfortunately, I don't think I have contributed back too much.
<a href="https://github.com/askedrelic/journal">Journal</a>, a Python script for keeping a
CLI journal, was probably my most complete project for the year, but I haven't
been hacking on it recently. Reaching out more via Github and interacting more
with other developers is my goal for next year.</p>
<h3>What was the Python blog or website you read the most in 2011?</h3>
<p><a href="http://news.ycombinator.com/">HackerNews</a>. After moving to San Francisco,
getting a job via the monthly job threads, and meeting up with people from the
site, I've really come to enjoy the dialogue available on programming and
Python.</p>
<h3>What are the three top things you want to learn in 2012?</h3>
<ul>
<li>Logging, metrics, and monitoring. Or applying the latest techniques and practices in production: using JSON for logged messages, realtime monitoring and alerting, longterm  storage, indexing, and searching.</li>
<li>A new language.  I know a great deal about Python, but it's time to start fresh. Haskell has always been high on my list, but I've never set specific goals and forced myself to start anything. Time to change that.</li>
<li>More Python? I've been diving into packaging once again, but maybe I should try and figure out how to help fix what I don't like about Python. I'm looking forward to attending PyCon US 2012 this year, hoping to get some great ideas.</li>
</ul>
<h3>What are the top software, app or lib you wish someone would write in 2012?</h3>
<p>Unify/fix Python packaging? More Python3 releases? I still need to convert all
my scripts to Python3. I have a bunch of Github improvements I'd love see
happen, but maybe with the v3 API I can hack them in myself.</p>
<p>Want to do your own list? Here’s how:</p>
<ul>
<li>copy-paste the questions and answer to them in your blog</li>
<li>tweet it with the <a href="https://twitter.com/#!/search/%232012pythonmeme">#2012pythonmeme</a> hashtag</li>
</ul>]]></content>
  </entry>
  <entry>
    <author>
      <name></name>
      <uri>http://asktherelic.com/code</uri>
    </author>
    <title type="html"><![CDATA[Book Review - Design For Hackers]]></title>
    <link rel="alternate" type="text/html" href="http://asktherelic.com/2011/12/30/book-review---design-for-hackers" />
    <id>http://asktherelic.com/2011/12/30/book-review---design-for-hackers</id>
    <updated>2011-12-30T16:54:02Z</updated>
    <published>2011-12-30T16:54:02Z</published>
    <category scheme="http://asktherelic.com/code" term="BookReviews" />
    <summary type="html"><![CDATA[Book Review - Design For Hackers]]></summary>
    <content type="html" xml:base="http://asktherelic.com/2011/12/30/book-review---design-for-hackers"><![CDATA[<p><span class="aligncenter">
<img alt="design for hackers" src="/pic/design-for-hackers.jpg" />
</span></p>
<p><a href="http://www.amazon.com/gp/product/1119998956/ref=as_li_ss_tl?ie=UTF8&amp;tag=asktherelic-20&amp;linkCode=as2&amp;camp=1789&amp;creative=390957&amp;creativeASIN=1119998956">Design For Hackers</a><br />
David Kadavy<br />
ISBN: 1119998956</p>
<h3>What’s The Point?</h3>
<p>Design, layout, fonts, and color theory for websites and web applications.
Kadavy covers all the main points of design, how design affects how we use
things, and through understanding your design decisions, how you can make
better decisions.</p>
<h3>How Was It?</h3>
<p>A useful and interesting read! The hacker in me likes well organized and
straightforward things. Each of the main elements of design were given a
chapter and covered thoroughly: what they are, how they work and why they exist
in a historical context. There were plenty of visual examples that were current
and useful.</p>
<p>Typography and fonts were given special preference, given the importance and
history, and a practical guide for using them in most situations was given in
an appendix.</p>
<h3>Who Should Read It?</h3>
<p>Programmers and hackers new to the topic. As an overall guide to design, it's a
great starting point and covers the bases, but is not a detailed guide on any
topic.</p>
<h3>Notes:</h3>
<p>I met the author through a <a href="http://www.grubwithus.com/">GrubWithUs</a> group meal.
He was using group meals as a kind of book tour and it was an interesting
experience to eat and discuss the book together! I also got my copy signed!</p>]]></content>
  </entry>
  <entry>
    <author>
      <name></name>
      <uri>http://asktherelic.com/code</uri>
    </author>
    <title type="html"><![CDATA[Version 1.0 of Comcast Bandwidth Usage]]></title>
    <link rel="alternate" type="text/html" href="http://asktherelic.com/2011/11/08/version-1.0-of-comcast-bandwidth-usage" />
    <id>http://asktherelic.com/2011/11/08/version-1.0-of-comcast-bandwidth-usage</id>
    <updated>2011-11-08T01:01:01Z</updated>
    <published>2011-11-08T01:01:01Z</published>
    <category scheme="http://asktherelic.com/code" term="Life" />
    <summary type="html"><![CDATA[Version 1.0 of Comcast Bandwidth Usage]]></summary>
    <content type="html" xml:base="http://asktherelic.com/2011/11/08/version-1.0-of-comcast-bandwidth-usage"><![CDATA[<p>After receiving some patches on GitHub this weekend and renewing my interest in this project, I've decided to tag a 1.0 version of my <a href="https://github.com/askedrelic/comcast-bw/">Comcast Bandwidth Usage</a> script! After being stable for atleast a year and combined with these new feature, it's probably worth finally tagging a stable version.</p>
<p>What's new in 1.0?</p>
<ul>
<li>Android Notifications of your usage via <a href="http://nma.usk.bz/">Notify My Android</a></li>
<li>The ability to easily run the script on Heroku instead of your own server</li>
<li>Now using standard config.ini configuration for your Comcast username/password</li>
</ul>
<p>What's already there; what is this script?</p>
<ul>
<li>A simple way to scrape your current bandwidth usage from Comcast's website with the ability to specific warn you if are coming close to the 250GB soft limit</li>
</ul>
<p>Download 1.0 <a href="https://github.com/askedrelic/comcast-bw/zipball/v1.0">now</a> (zip).</p>
<h3>Upgrading</h3>
<p>If you have already been running script, it might be easiest to download the 1.0 and re-enter your Comcast login into the config.ini. The previous method of editing the script itself was pretty bad and left a lot of room for errors with source control.</p>
<h3>Android Notifications</h3>
<p>With commits from <a href="https://github.com/Adalan">Adalan</a>, you can now add your API key from <a href="http://nma.usk.bz/">Notify My Android</a> and will be able to get your usage notifications via a push notification to your phone.</p>
<p>Attach the <code>-a</code> flag when running the script to enable these notifications.</p>
<h3>Running On Heroku</h3>
<p>This is a unique feature of the script, but was an idea I wanted to try: not everyone has a server running 24x7 or a place where they can easily run Python scripts like this daily.</p>
<p>With Heroku's new Cedar stack, while oriented for running web applications, you can run any Python script on a daily schedule for free. It took a bit of hacking detailed <a href="/2011/11/05/unix-style-cron-on-heroku's-cedar-stack">here</a>, but wasn't impossible.</p>
<p>See the <a href="https://github.com/askedrelic/comcast-bw/blob/master/HEROKU_USAGE.markdown">HEROKU_USAGE.markdown</a> document and try running the script on Heroku!</p>
<p>Until bandwidth limits disappear, enjoy the script!</p>]]></content>
  </entry>
  <entry>
    <author>
      <name></name>
      <uri>http://asktherelic.com/code</uri>
    </author>
    <title type="html"><![CDATA[Unix Style Cron on Heroku's Cedar Stack]]></title>
    <link rel="alternate" type="text/html" href="http://asktherelic.com/2011/11/05/unix-style-cron-on-heroku's-cedar-stack" />
    <id>http://asktherelic.com/2011/11/05/unix-style-cron-on-heroku's-cedar-stack</id>
    <updated>2011-11-05T15:40:02Z</updated>
    <published>2011-11-05T15:40:02Z</published>
    <category scheme="http://asktherelic.com/code" term="Life" />
    <summary type="html"><![CDATA[Unix Style Cron on Heroku's Cedar Stack]]></summary>
    <content type="html" xml:base="http://asktherelic.com/2011/11/05/unix-style-cron-on-heroku's-cedar-stack"><![CDATA[<p>I've been playing with Heroku for a project and wanted to use the default
<code>cron</code> addon to run a Python script and only email if that script printed
anything to stdout; regular Unix style.</p>
<p><a href="https://github.com/askedrelic/heroku-cedar-cron">This repo is my attempt that</a>.</p>
<p>Overall, I definitely accomplished what I set out to do! I've been very impressed with Heroku's Cedar stack and how flexible it is. It's awesome being able to script the creation of an enviroment and instantly see if my script is working or not.</p>
<p>With that repo, you can basically use Heroku as a free cron running system you control. The whole stack is free and if you just have to run something once a day, that's still free. If you don't have a VPS or a server running 24x7, you can now push stuff onto Heroku and not have to worry about keeping it online, it will just work.</p>]]></content>
  </entry>
  <entry>
    <author>
      <name></name>
      <uri>http://asktherelic.com/code</uri>
    </author>
    <title type="html"><![CDATA[A Return To Normal]]></title>
    <link rel="alternate" type="text/html" href="http://asktherelic.com/2011/10/26/a-return-to-normal" />
    <id>http://asktherelic.com/2011/10/26/a-return-to-normal</id>
    <updated>2011-10-26T22:35:39Z</updated>
    <published>2011-10-26T22:35:39Z</published>
    <category scheme="http://asktherelic.com/code" term="Life" />
    <summary type="html"><![CDATA[A Return To Normal]]></summary>
    <content type="html" xml:base="http://asktherelic.com/2011/10/26/a-return-to-normal"><![CDATA[<p>The last few months have been a bit hectic: a few weeks traveling through NYC
and DC, a new job in San Francisco, a cross country drive, and a few apartment
moves. Thankfully, my life has finally reached the point where I am comfortable
again and can start coding and writing in peace. My new job has kept me
quite busy, but what little free time I find, I try and make good use of.</p>
<p>I found an article through HackerNews recently that, while quite old, still
seemed quite relevent and impressed me greatly: <a href="http://www.paulgraham.com/hamming.html">"You and Your Research,"</a> a
transcription of a talk given by Richard Hamming in 1986, the year I was born.</p>
<p>Of the many great quotes and ideas in his talk, this stood out to me:</p>
<p><code>"You should do your job in such a fashion that others can build on top of it"</code></p>
<p>That is the best way to describe my goal for this blog, along with the code in
my github repos. It's time to accomplish great things.</p>]]></content>
  </entry>
  <entry>
    <author>
      <name></name>
      <uri>http://asktherelic.com/code</uri>
    </author>
    <title type="html"><![CDATA[Journal 0.2.0 Released!]]></title>
    <link rel="alternate" type="text/html" href="http://asktherelic.com/2011/08/18/journal-0.2.0-released!" />
    <id>http://asktherelic.com/2011/08/18/journal-0.2.0-released!</id>
    <updated>2011-08-18T16:14:08Z</updated>
    <published>2011-08-18T16:14:08Z</published>
    <category scheme="http://asktherelic.com/code" term="Life" />
    <summary type="html"><![CDATA[Journal 0.2.0 Released!]]></summary>
    <content type="html" xml:base="http://asktherelic.com/2011/08/18/journal-0.2.0-released!"><![CDATA[<p>I'm releasing v0.2.0 of Journal today, a Python command line tool that I've
created to help with keeping a journal for work/personal stuff! Check PyPi for
the latest or do an upgrade install with pip, <code>pip install -U journal</code>.</p>
<p>Main changes include:</p>
<ul>
<li>Support for viewing entries on a specific date and over a specific time period</li>
<li>The ability to create multiple entries at once from the command line</li>
<li>Python 2.5 compatibility (thanks to <a href="http://pypi.python.org/pypi/tox">Tox</a>)</li>
</ul>
<p>Read on for more details.</p>
<h3>Viewing Existing Entries</h3>
<p>I'm hesitant to add a full human-date parsing library as a dependency, since I
don't need specific time based or future based dates, so I rolled my own. The
date formats currently supported include:</p>
<ol>
<li>previous day increments: "1 day ago", "a day ago", "5 days ago", "yesterday", or "today"</li>
<li>specific American date formats: "8/15", "8/15/2011", "5-6-2011", or "August 15"</li>
</ol>
<p>So you can now view specific entries for a day by using the flag <code>--view</code>.
Short tags work with these dates.</p>
<pre><code>$ journal --view "yesterday"
$ journal --view "12 days ago"
$ journal --view "8/14"
# Easiest way to view today
$ journal -vt
</code></pre>
<p>And you can view all entries since a specific previous date, using the flag
<code>--since</code>. This is sparse output, dates without entries will be skipped
quietly.</p>
<pre><code>$ journal --since "yesterday"
$ journal --since "7 days ago"
</code></pre>
<p>I am still thinking over adding week and month dates to the mix, along with
any other reasonable human time formats. The <code>--view</code> and <code>--since</code> flags
are modeled after Git's log command, I'm thinking about adding in a
<code>--until</code> flag also, for doing specific ranges. Although, adding a week date
range might cover that need better.</p>
<p>Viewing entries over multiple days might provide lots of output, so I would
recommend using <code>less</code> or <code>more</code> to paginate.</p>
<pre><code>$ journal --since "100 days ago" | less
</code></pre>
<h3>Adding Multiple Entries</h3>
<p>You can add multiple entries at a time from the command line, which will get
added together in the journal.</p>
<pre><code>$ journal "Foo was compeleted" "Bar was completed, after foo"
$ tail ~/.journal/2011.08.18.txt
Thu 10:52:01 2011-08-18
-Foo was compeleted
-Bar was completed, after foo
</code></pre>
<p>I felt simplifying multiple entry was useful, but a <a href="https://twitter.com/electroly/status/104205241360199680">friend on Twitter</a>
remarked that using quotes felt limiting. I'm starting to agree with him and
may change the main entry mode back to "single entry" mode, but capturing all
args and not require quotes. It adds issues with semi-colons or single
quotes getting caught by your shell, but maybe it's worth it? This process is
also leading me toward a config file, with sensible defaults, but configurable
options for those interested.</p>
<h3>The Future</h3>
<p>I think for the next version, better listing options of existing journal
entries would be useful. Having a config file to control entry options and date
formatting preferences perhaps. Have thoughts on what you like or don't like?
Let me know in the comments!</p>]]></content>
  </entry>
  <entry>
    <author>
      <name></name>
      <uri>http://asktherelic.com/code</uri>
    </author>
    <title type="html"><![CDATA[Journaling]]></title>
    <link rel="alternate" type="text/html" href="http://asktherelic.com/2011/08/16/journaling" />
    <id>http://asktherelic.com/2011/08/16/journaling</id>
    <updated>2011-08-16T00:32:46Z</updated>
    <published>2011-08-16T00:32:46Z</published>
    <category scheme="http://asktherelic.com/code" term="Life" />
    <summary type="html"><![CDATA[Journaling]]></summary>
    <content type="html" xml:base="http://asktherelic.com/2011/08/16/journaling"><![CDATA[<p>I'm releasing 0.1 of Journal, a simple Python CLI tool to help with keeping a
journal for work/personal stuff! Inspired by Peter Lyons' <a href="http://peterlyons.com/leveling_up.html">article on career
development</a>, I decided to write up a
script to help manage things. </p>
<p>The idea from Lyons' article is to keep a chronological log of everything you
do at your job. This mirrors my own experiences with working so
far: keeping meticulously notes of what I'm doing is always helpful and not
too much extra work, since I always carry a notebook around with me for this
purpose. Now I can keep things digital! </p>
<h3>Install</h3>
<p>The script is located on Github here:
<a href="https://github.com/askedrelic/journal">https://github.com/askedrelic/journal</a></p>
<p>You can install with:</p>
<pre><code>$ pip install journal
</code></pre>
<p>The journal command should now be available on your command line and you can
journal like so:</p>
<pre><code>$ journal "Task foo completed"
</code></pre>
<p>and a ~/.journal/[CURRENT DATE].txt file will be created using the current
date, with a timestamp and your entry. Just continue to enter your tasks
through the days and weeks and build a record of your work.</p>
<h3>Thought Process</h3>
<p>For interest, here was my progression of work in creating this tool:</p>
<ol>
<li>
<p>Creating a journal using Bash isn't really that hard: </p>
<p>(bsd style for OSX)</p>
<p><code>$ echo -e `date`"\n-work completed\n" &gt;&gt; ~/`date "+%Y-%m-%d.txt"`</code></p>
</li>
<li>
<p>I looked for existing projects that may have already solved this problem.</p>
<p>I found <a href="https://github.com/fabrik42/work_log">work_log</a>, a Ruby script
more oriented for tracking time. I got some good ideas for how the CLI
interface should work, but this program didn't quite solve my problem.</p>
<p>There are existing blogging solutions, but a blog is heavy-weight and
mostly something you manage through the web. I prefer KISS and keeping
things on the console. </p>
</li>
<li>
<p>Then I rolled my own!</p>
</li>
</ol>]]></content>
  </entry>
  <entry>
    <author>
      <name></name>
      <uri>http://asktherelic.com/code</uri>
    </author>
    <title type="html"><![CDATA[PyOhio2011]]></title>
    <link rel="alternate" type="text/html" href="http://asktherelic.com/2011/08/09/pyohio2011" />
    <id>http://asktherelic.com/2011/08/09/pyohio2011</id>
    <updated>2011-08-09T10:22:31Z</updated>
    <published>2011-08-09T10:22:31Z</published>
    <category scheme="http://asktherelic.com/code" term="Life" />
    <summary type="html"><![CDATA[PyOhio2011]]></summary>
    <content type="html" xml:base="http://asktherelic.com/2011/08/09/pyohio2011"><![CDATA[<p>I attended PyOhio this past weekend, a great Python conference which I was pleasantly surprised existed! After moving to Pittsburgh last year, I've been looking around for meetups and ways to meet other developers. I found Ruby, Javascript, and Python user groups but this was the first major conference I've seen in the area. I attended with a friend I met from my local <a href="http://twitter.com/#!/pghpy" title="Pittsburgh Python Usergroup">Pittsburgh Python usergroup</a> and had a blast. I would definitely recommend attending!</p>
<p>Several highlights for me included:</p>
<ul>
<li>
<p>The talk about cmd2, an interactive command line. Expanding the command line and making things easier for myself and others has always interested me. It had some interesting ideas on how I would almost want Fabric to work. <a href="http://python.mirocommunity.org/video/4378/pyohio-2011-interactive-comman">View the talk here</a>.</p>
</li>
<li>
<p>Speaking of Fabric, there was a talk given on that also. Fabric seems to be popping up everywhere, I've even given a talk myself, <a href="/2011/06/22/fabric-for-python-automation">viewable here</a>! It was great to be able to compare to my talk: it seems best to give a quick rundown of Fabric and then dive into examples. Fabric's power seems hard to explain and easier to show.</p>
</li>
<li>
<p>The talk on switching from PHP to Python from Emma was great, I love high level "lessons learned" style talks. <a href="http://ontwik.com/python/php-to-python-with-no-regrets/">View it here</a>.</p>
</li>
<li>
<p>One talk which I missed in person, but am glad for the great recorded videos, is the talk SQLAlchemy. It's a useful tool but seems to have such a steep learning curve. More help climbing that curve is great. <a href="http://python.mirocommunity.org/video/4392/pyohio-2011-sqlalchemy-tutoria">View it here</a>.</p>
</li>
<li>
<p>I won a book on algorithms in Python! Algorithms are something I've been meaning to brush up on and I love Python, so must be serendipity? <a href="https://www.amazon.com/dp/1430232374/ref=as_li_ss_til?tag=asktherelic-20&amp;camp=213381&amp;creative=390973&amp;linkCode=as4&amp;creativeASIN=1430232374&amp;adid=1JWVPAFHPE3SK2M7MXMQ&amp;" title="Python Algorithms">This is the book</a>, it's been great reading so far.</p>
</li>
</ul>
<p>I'm still flipping through some of the talks I missed, definitely some good material produced from this talk and definitely worth attending next year!</p>]]></content>
  </entry>
</feed>

