Articles by Scott Motte


Hacker in LA. I believe the future is bright. It's up to us to build it - as programmers we get a big say. Follow me on twitter @motdotla.

Follow Scotty

Create your First Heroku Buildpack

Technical
heroku-buildpack-mupdf

Did you know you can install custom software on Heroku? You can, using buildpacks. In this tutorial, I show you how to write a custom buildpack. I’ll use MuPDF, a handy utility to convert PDFs to PNGs, as an example. Replace the MuPDF parts with the binary you want. Create the Binary Before we can create the buildpack, we need to create the binary on the Heroku server environment. Make the binary. Begin by creating a heroku app. heroku create buildpack-stager heroku run bash –app buildpack-stager Then ssh into the server. heroku run bash –app buildpack-stager Make the binary. curl -O https://mupdf.googlecode.com/files/mupdf-1.3-source.tar.gz tar -xvzf mupdf-1.3-source.tar.gz cd mupdf-1.3-source make DESTDIR=/app make install Cool, that installs everything to /app/usr/local. Archive the binary.


Hello World with Apex

Technical
apex-hello-world-8

Salesforce is extremely popular software. It is used by large and small companies alike, and its Salesforce1 Platform allows you as a developer to create applications in the cloud. You write code on the Salesforce1 Platform in a language called Apex. It is similar to Java. Most of the tutorials for getting started with Apex use the Force.com IDE. I’m not a fan of IDEs. In this tutorial, I am going to show you how to write an Apex Hello World app without using an IDE. Let’s begin. Setup Salesforce.com Create a salesforce.com developer account. You’ll receive an email from Salesforce with a link to confirm. Click it. On the next screen, set your password. Yeah, it’s an odd flow,


Host Your Own Disposable Email App

Technical
Personal-mailinator

I like Mailinator. I use it all the time. However, it has had some downtime recently at inopportune times for me. My friend Joël had the idea of creating one’s own disposable email like Mailinator’s. In this post, I’m going to show you how to do just that. It turns out it is pretty easy using modern tools. Generate a RequestBin Visit RequestBin and create a bin. Set Up the Inbound Webhook Visit SendGrid’s Parse Webhook Settings. Set the hostname to 1ii55qy1.webhook.email. Set the url to the url of the bin you created above. Send an Email Go to your email and send an email to hi@1ii55qy1.webhook.email. Refresh the request bin page you generated in Step 1. That’s it. You’re


Open Source: Pull Request Driven Development

Technical
sendgrid-contributor-badges

Pull Requests are my favorite feature of GitHub. They are the way I prefer to do development. Avoid Communication Breakdown There is necessarily a lot of discussion that happens when writing code. On a team of one, this discussion happens in your brain. On a local team of two or three, it happens IRL. These approaches work ok, but they break down when the team is remote or four-plus people. So, how do you avoid this breakdown in communication? Often, teams turn to an external tool like Basecamp. I recommend against that. Those conversations live too far away from where the code lives. Your brain and mouse have to travel between each. The better way is to use GitHub’s Pull


How to Launch a Rocket with an Arduino and Node.js

Technical
Hackers prepare a rocket launch

Recently, I had the chance to teach kids how to launch rockets using Arduinos. As you might guess, it was a blast. We wrote a countdown program using Node.js, hooked the program up to an Arduino, and wired up the Arduino. This sent an electrical signal to the rocket engine, igniting it. In this tutorial, I show you how to do the same. Prerequisites You will need the following materials: Arduino Mega 2560 Board. You could use a different Arduino board, but I recommend the Mega. NodeJS installed on your computer. It is relatively easy to install. You can go here to install it. 9 Volt Battery and a 9 Volt Battery clip. Breadboard and Jumper Wires A 5 Volt


Complete Guide to Set Up Raspberry Pi Without a Keyboard and Mouse

Technical
photo 2

Raspberry Pi is a fun little “computer” that is an expandable hardware board with un-ending possibilities for hacking. The one downside is it can be tricky to get started if you don’t have an extra keyboard and mouse hanging around. The following tutorial makes it reasonably easy to set up your Raspberry Pi without a keyboard and mouse. All you need is a Raspberry Pi with a Wifi Adapter and a router with an available ethernet port. From there, it’s a two step process: Install Unix on the SD Card Configure the Raspberry Pi’s Wifi Let’s take those one at a time. Install Unix Your Raspberry Pi comes with a SD card. We’ll install Raspbian, a special Raspberry Pi flavor


Remember to Floss With an Interactive Reminder Email

Technical
flossedtoday

It’s been over a month since New Year’s Day, but I’m still trying to keep some of my New Year’s resolutions. I’ve found the best way to keep them is to have someone remind you—nag you, really. Likely, your friends don’t want to spend their free moments nagging you though. So, let’s have SendGrid do it instead. Resolve to Be a Flosser You’re likely familiar with sending email through SendGrid, but we can also receive it via the Inbound Parse Webhook. We can combine the two to act like a person reminding us of our New Year’s resolution. How? We’ll send an email each day asking if we did our New Year’s resolution. If we reply “yes,” the app will


Long Live the Informal Hackathon

Community
informal hackathon

The Major League Hackathons—Penn Apps, MHacks, BoilerMake, and HackTech–are great. Go to these. But go to the small hackathons, too. Good things come from the small, informal hackathons. And you can even easily organize one yourself. The very first hackathon was small. I’m stating the obvious, but hackathons did not start as large organized events with multiple sponsors. They started as informal get-togethers. People like you, the makers and creators, got together to create something cool. Where to Start Hold informal hackathons. Get a handful of friends, pick a venue like your co-working space or apartment, and pitch in for some pizza and soda, invite others, and hack for 24 hours. Publicize your event on Meetup.com, tweet it out, and


Keep Your New Year’s Resolution to Code More

Technical
GitHub streaker

The year 2014 is here and with it New Year’s resolutions. My New Year’s resolution is to commit more open source code. Little apps like this one by Nick Quinlan are helping to keep that at the forefront of my mind. Specifically, I want to complete a 30 day GitHub commit streak. I’m bad at remembering to commit so I built an application to remind me. It’s called github-streaker. It checks your GitHub commits each day. If you haven’t made any commits that day, it sends you a reminder email using SendGrid. You can deploy github-streaker in just a few minutes to Heroku. Here are the steps: git clone https://github.com/scottmotte/github-streaker.git cd github-streaker heroku create heroku addons:add scheduler heroku addons:add sendgrid


A Sinatra and Heroku Application Template in 20 Lines

Technical
Blackboard-Checklist

Heroku is a great web publishing platform. Additionally, Sinatra is a great ruby web framework. In this post, I’ll show you how to quickly combine the two. I have created a sinatra-heroku-template app to make it easy on you. All files combined, it is only 20 lines of code. Do the following to get it up and running. git clone git://github.com/scottmotte/sinatra-heroku-cedar-template.git gem install bundler bundle heroku create yourwebapp git push heroku master bundle exec heroku open That’s it. You now have a bare bones Ruby app running in production on Heroku. Add your own code as necessary. Here’s a breakdown the file structure: app.rb defines your routes and is the core of your application config.ru boots your app Gemfile defines


Get Going with Go and Redis

Technical
gopher

Go is a promising language. It’s a strong replacement for Java, it’s similarly productive to writing Python, and it is an excellent tool for writing servers. I’m starting to dive into it in my spare time, and in this blog post I will show you the basics of getting started with Go and Redis together. This tutorial assumes you’re running a flavor of Mac OS X and are comfortable with Terminal. Setup Install Redis Run the following commands on most *nix command lines to download, unpack and install Redis: wget http://download.redis.io/redis-stable.tar.gz tar xvzf redis-stable.tar.gz cd redis-stable make sudo make install Install Go Install Go. As of writing, this was the latest version for Mac. (You can find the list of all


Let’s Deprecate the Password: Email-only Authentication

Best Practices, Product, Technical
handshake-js

Passwords suck. They are hard to remember. The average person re-uses the same password across the majority of their accounts. Can you blame them? It’s easier, and people have lives to live – not passwords to manage. It’s mainly the technorati that use tools like LastPass or 1Password. Passwords also tend to never expire. It is rare a site requires you to change your password – and it’s discouragingly user un-friendly when they do. What if we could remove the password? That would solve the above problems. Let’s try. Introducing Handshake.js I’ve built a solution called Handshake.js that is an attempt at this. It is open source. It works like this. First, you place a small script tag into your