Raw Syntax

The stuff programs are made of

K750: A Solid Wireless Keyboard


I don't normally talk about computer equipment here, but I recently purchased the K750 wireless keyboard by Logitech. It's amazing because it is solar powered and therefore requires no batteries. Their manual says it can remain powered for 3 months in total darkness. I believe they tested this in my office. Also of note, I bought the mac version of the keyboard. However, it also works with my PC, though I had to fool with their software a bit for the function keys to work.

The K750 is also a good deal cheaper than the official Apple wireless keyboard.

Previously I had an older version of the Razer Deathstalker. It was nice, but there were wires everywhere. The K750 is nice and clean, and I haven't noticed any perceptible input lag / delay.

How to Set Up Angular With Rails Part 2


originally posted on the Intridea blog here: http://www.intridea.com/blog/2014/10/14/how-to-set-up-angular-with-rails-part-2

In Part I of our Angular series, we illustrated the process for setting up an Angular app for Rails.

In Part 2 of this series, we'll be creating a basic HR app. This app will allow us to view employee information through an Angular app (edits and updates to be explained in Part 3 of this series). For more details, see code in Github link at the end of post.

How to Set Up Angular With Rails


originally posted on the Intridea blog here: http://www.intridea.com/blog/2014/9/25/how-to-set-up-angular-with-rails

To get started lets create a new rails app.

gem install rails -v 4.1
rails new angular_example

In this app, I chose not to use turbolinks. It's possible to use Angular with Rails and turbolinks, but the Angular app bootstrap process is more complex. I find that turbolinks and Angular serve the same purpose, which is to make the app respond faster. Adding turbolinks, in addition to Angular, adds a lot of complexity and not much benefit.

Learn Emacs: Term, Ansi Term


When I first started using Multi-Term to run my terminal in emacs, much of the documentation I saw on the EmacsWiki referenced both ansi-term and term. This left me somewhat confused as to which I should be using and what the difference was. I ignored this for some time while I got my Multi-Term setup working correctly.

Look It Up

When the time came to find out the truth, I knew I could just ask emacs. I used C-h a to invoke apropros and fed it both ansi-term and term. The output linked me to term.el and I read the source for both methods. It turns out that both methods work similarly, but simply use different buffer names. As EmacsWiki explains, the difference is largely historical at this point. Previously, plain term-mode was less able to display colors than ansi-term.

This is one of the features I like best about emacs. It has a built-in help system that allowed me to search for term related documentation, and eventually led me to the source code implementation of the method in question. All without leaving the editor!

I have some enhancements to my previous post zsh and multi-term in emacs, and the fixes and changes that I implemented all came from reading the source of term.el and referring to EmacsWiki as needed.