Learn You Some Smarts for Great Good!

Like to code? Like to learn? Live in Portland? Well then you ought to join me in my great journey to the dark west hills of the lands of Hillsboro and Intel! I’ll be taking the following grand journey from Portland out to Intel to give a presentation on Pluralsight and teaching, learning, and getting smarts for great good! If you’d like to join me RSVP on the meetup invite here and let me know, I’m happy to transit out to the location with you.

Afterwards, as is standard operating procedure, we’ll have dinner, drinks, and food across the street at . Sure to have good conversation and laughs, as I always endeavor to do.

Ride Out With Me…

If you’re interested in riding out with me, join me at the Old Town China Town MAX Stop at 5:00pm. We’ll depart on the MAX Blue Line out to Hawthorn Farms Intel Campus. Afterwards, if interested I’ll be riding back too after the meet and post-meet meet at Morgy’s Pub & Grill (across the street).

What I’ll be Talking About

Pluralsight is one of the leading online educators of online, video-based, technical content in the world. In my presentation I’ll dive into how Pluralsight maintains integrity of its courses, insures learning, encourages quality, and helps keep the whole system moving forward in a seamless way. This presentation will be a small diversion from the technical components we often discuss as developers and instead a dive into the actual systems of learning, training, and production that are often on the edges of what we see as developers – but benefit greatly from when we want to learn something new! The core three things I’ll be covering include:

  • How video & doing helps us learn quickly.
  • How video is produced and the tools of this trade.
  • How to produce effective technical content to teach.
  • How to effectively use technical content to learn.

Once I finish the talk I’ll provide a wrap up here on the blog. My intention is to do more than merely post the slides, I’ll work to put something together that’s actually useful.

Speaking of Pluralsight

I’m also working on a new course right now! Ok, at this very moment I’m sipping a Black Forest Mocha at Coffee People while typing this blog entry while waiting for arrivals at the airport, but you know what I mean. I’ll have a basic outline and material for that course posted soon. For more on this pending course and other code event happenings, subscribe to the blog (scroll up and click the settings hexagon above) and or follow me on twitter @adron.

Starting an Ubuntu Dev Tools List

I’ve recently setup a completely clean virtual machine for doing web, system, and related development on Ubuntu. Here’s the shortlist of what I’ve installed after a default installation. The ongoing list of tools and related items I have installed on my Linux dev box I’m keeping here, and it will be kept as a living doc, so I’ll change it as I add new tools, apps and related changes. So lemme know what I ought to add to that list and I’ll add it to my docs page here. Here’s what I have so far…

Other To-dos

  • Always run sudo apt-get update once the system is installed. It never hurts to have the latest updates.
  • I always install Chrome as my first app. Sometimes the Ubuntu Software Center flakes out on this, but just try again and it’ll work. I use the 64-bit Chrome btw, as I’ve noticed that the 32-bit often flakes out when attempting installation on my virtual machines. Your mileage may vary.

What this enables…

At this point I can launch into about any language; Java, JavaScript, and a few others with a minimal amount of headache. Since it’s a Linux instance it gives me a full range of Linuxy things at my disposal.

Default Java Installation

  1. Run a ‘sudo apt-get update’.
  2. To install the default Java JRE and the JDK run the following commands.

    sudo apt-get install default-jre
    sudo apt-get install default-jdk
    

Oracle Java v8 Installation

  1. sudo add-apt-repository ppa:webupd8team/java
    sudo apt-get update
    sudo apt-get install oracle-java8-installer
    

WebStorm Installation

  1. I download the application zip from JetBrains and then run

    tar xfz WebStorm-*.tar.gz
    
  2. Next I always move the unzipped content to the directory in which I’d like to have the application stored. It’s good practice to not keep things in the download directory, just sayin’. Generally I put these in my usr/bin directory.

    mv /downloads/WebStorm-* your/desired/spot
    
  3. Now at your terminal, navigate to the path where the application is stored and run the WebStorm.sh executable.

    ./bin/webstorm.sh
    
  4. To add WebStorm to the Quicklaunch, just right click on the icon and select to Lock to Launcher.

IDEA IntelliJ Installation

  1. Follow all the steps listed under WebStorm, it’s the exact same process.

Sublime 3

  1. Go to download the latest v3.
  2. Run the package and it should launch the actual Ubuntu installer, setup Sublime for bash use and get it installed.

(NOTE UPDATED 1/18/2016 > The installer doesn’t seem to get it installed, so I went with this link http://olivierlacan.com/posts/launch-sublime-text-3-from-the-command-line/ which has a good solution.)

I’m so mad!!! My response to the fork of node.js to io.js!

I’m so mad!!!

No, actually I’m not. This is cool.

It’s so confusing! No, it’s actually not. Use your learnings and read this Node Forward and read Max’s @maxogden “What you need to know.” gist.

It’ll be so hard to test this and test with node.js. Not really, again, read the threads there are a million different ways that you’ll be able to setup a clean build against either while keeping both around on your dev machine. Again, repeating myself, this is cool.

Summary for Devs: This is cool. It’s not going to wreck your projects. Just read up on it and it’ll all be a most excellent journey.

Summary for Decision Makers: Read @eranhammer‘s blog post here. TLDR; is, don’t second guess your decision to go with Node.js, don’t flip out about a Node.js or io.js investment, this isn’t anything more than a healthy ecosystem at work. It’ll be cool.

No excuse not to have your branching strategy taken care of, because: git-flow

First, get it installed. This takes less than a minute, at least on a *nix based machine. I’ve no idea what it takes on Windows, but hey, at least it’s available there too! I did a clean curl and install as shown. It took about 14 seconds solely because I wasn’t typing very fast today.

12:28 $ curl -L -O https://raw.github.com/nvie/gitflow/develop/contrib/gitflow-installer.sh
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
100 2145 100 2145 0 0 1732 0 0:00:01 0:00:01 --:--:-- 1732
~
12:28 $ sudo bash gitflow-installer.sh
Password:
### gitflow no-make installer ###
Installing git-flow to /usr/local/bin
Cloning repo from GitHub to gitflow
Cloning into 'gitflow'...
remote: Counting objects: 1407, done.
remote: Total 1407 (delta 0), reused 0 (delta 0)
Receiving objects: 100% (1407/1407), 623.29 KiB | 428.00 KiB/s, done.
Resolving deltas: 100% (689/689), done.
Checking connectivity... done.
Updating submodules
Submodule 'shFlags' (git://github.com/nvie/shFlags.git) registered for path 'shFlags'
Cloning into 'shFlags'...
remote: Counting objects: 454, done.
remote: Total 454 (delta 0), reused 0 (delta 0)
Receiving objects: 100% (454/454), 130.91 KiB | 0 bytes/s, done.
Resolving deltas: 100% (337/337), done.
Checking connectivity... done.
Submodule path 'shFlags': checked out '2fb06af13de884e9680f14a00c82e52a67c867f1'
install: gitflow/git-flow -> /usr/local/bin/git-flow
install: gitflow/git-flow-init -> /usr/local/bin/git-flow-init
install: gitflow/git-flow-feature -> /usr/local/bin/git-flow-feature
install: gitflow/git-flow-hotfix -> /usr/local/bin/git-flow-hotfix
install: gitflow/git-flow-release -> /usr/local/bin/git-flow-release
install: gitflow/git-flow-support -> /usr/local/bin/git-flow-support
install: gitflow/git-flow-version -> /usr/local/bin/git-flow-version
install: gitflow/gitflow-common -> /usr/local/bin/gitflow-common
install: gitflow/gitflow-shFlags -> /usr/local/bin/gitflow-shFlags
~

For installation instructions check out the link here: https://github.com/nvie/gitflow/wiki/Installation

Now that everything is setup. Here’s the quick getting started of creating a repo, linking it up to a remote and working in a repository. The first step is to initialize a new repo.

$ git flow init
Initialized empty Git repository in /Users/adronhall/Coderz/gitflowing/.git/
No branches exist yet. Base branches must be created now.
Branch name for production releases: [master]
Branch name for "next release" development: [develop]

How to name your supporting branch prefixes?
Feature branches? [feature/]
Release branches? [release/]
Hotfix branches? [hotfix/]
Support branches? [support/]
Version tag prefix? []

To note, if I added the -d switch to the command all of the defaults would have been accepted. Since I just created this repository out of the blue, it doesn’t have a remote setup yet. So I’ll add that next.

git remote add origin git@github.com:Adron/git-flow-example.git

When I run a git status I can see that I’m currently on the develop branch of the repo.

$ git status
On branch develop
nothing to commit, working directory clean

From here, I needed to start a feature. I started this with the following command and then created a new Strongloop Loopback API Server Application with the following commands.

Starting a new feature.

$ git flow feature start create_base_app
Switched to a new branch 'feature/create_base_app'

Summary of actions:
- A new branch 'feature/create_base_app' was created, based on 'develop'
- You are now on branch 'feature/create_base_app'

Now, start committing on your feature. When done, use:

git flow feature finish create_base_app

Creating a new Loopback API Server App. For more on setting up a Strongloop Loopback API Server App check out the review I wrote “Framework: Strongloop’s Loopback“.

slc loopback

Now just to make sure everything ran right I ran the server app.

slc run .

With everything running ok I’m going to wrap up the feature with git-flow.

$ git flow feature finish create_base_app
Switched to branch 'develop'
Updating 128accf..18ea6b9
Fast-forward
.editorconfig | 13 +++++++++++++
.jshintignore | 2 ++
.jshintrc | 21 +++++++++++++++++++++
.npmignore | 16 ++++++++++++++++
client/README.md | 3 +++
package.json | 22 ++++++++++++++++++++++
server/boot/authentication.js | 4 ++++
server/boot/explorer.js | 23 +++++++++++++++++++++++
server/boot/rest-api.js | 4 ++++
server/boot/root.js | 6 ++++++
server/config.json | 5 +++++
server/datasources.json | 6 ++++++
server/model-config.json | 29 +++++++++++++++++++++++++++++
server/server.js | 43 +++++++++++++++++++++++++++++++++++++++++++
14 files changed, 197 insertions(+)
create mode 100644 .editorconfig
create mode 100644 .jshintignore
create mode 100644 .jshintrc
create mode 100644 .npmignore
create mode 100644 client/README.md
create mode 100644 package.json
create mode 100644 server/boot/authentication.js
create mode 100644 server/boot/explorer.js
create mode 100644 server/boot/rest-api.js
create mode 100644 server/boot/root.js
create mode 100644 server/config.json
create mode 100644 server/datasources.json
create mode 100644 server/model-config.json
create mode 100644 server/server.js
Deleted branch feature/create_base_app (was 18ea6b9).

Summary of actions:
- The feature branch 'feature/create_base_app' was merged into 'develop'
- Feature branch 'feature/create_base_app' has been removed
- You are now on branch 'develop'

That wraps up the first feature. To push this work out to the remote now, I’ll start a release.

$ git flow release start base_app
Switched to a new branch 'release/base_app'

Summary of actions:
- A new branch 'release/base_app' was created, based on 'develop'
- You are now on branch 'release/base_app'

Follow-up actions:
- Bump the version number now!
- Start committing last-minute fixes in preparing your release
- When done, run:

git flow release finish 'base_app'

At this point I’ll also give the packages.json file an actual version number bump from 0.0.0 to 0.0.1. Now I wrap up the release and push the code to remote. First by pushing the code to the remote.

$ git flow release publish base_app
Counting objects: 30, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (25/25), done.
Writing objects: 100% (28/28), 4.05 KiB | 0 bytes/s, done.
Total 28 (delta 4), reused 0 (delta 0)
To git@github.com:Adron/git-flow-example.git
* [new branch] release/base_app -> release/base_app
Already on 'release/base_app'
Your branch is up-to-date with 'origin/release/base_app'.

Summary of actions:
- A new remote branch 'release/base_app' was created
- The local branch 'release/base_app' was configured to track the remote branch
- You are now on branch 'release/base_app'

Then I wrap up the release. When issuing the command, toward the end VI will launch to provide tag details and commit messages, enter these and save (Enter the message by hitting the i key, then Esc and :w to write the file within VI and :q! to escape after) the files for the release to finish.

$ git flow release finish base_app
Switched to branch 'master'
Merge made by the 'recursive' strategy.
.editorconfig | 13 +++++++++++++
.gitignore | 3 +++
.jshintignore | 2 ++
.jshintrc | 21 +++++++++++++++++++++
.npmignore | 16 ++++++++++++++++
client/README.md | 3 +++
package.json | 22 ++++++++++++++++++++++
server/boot/authentication.js | 4 ++++
server/boot/explorer.js | 23 +++++++++++++++++++++++
server/boot/rest-api.js | 4 ++++
server/boot/root.js | 6 ++++++
server/config.json | 5 +++++
server/datasources.json | 6 ++++++
server/model-config.json | 29 +++++++++++++++++++++++++++++
server/server.js | 43 +++++++++++++++++++++++++++++++++++++++++++
15 files changed, 200 insertions(+)
create mode 100644 .editorconfig
create mode 100644 .jshintignore
create mode 100644 .jshintrc
create mode 100644 .npmignore
create mode 100644 client/README.md
create mode 100644 package.json
create mode 100644 server/boot/authentication.js
create mode 100644 server/boot/explorer.js
create mode 100644 server/boot/rest-api.js
create mode 100644 server/boot/root.js
create mode 100644 server/config.json
create mode 100644 server/datasources.json
create mode 100644 server/model-config.json
create mode 100644 server/server.js
Deleted branch release/base_app (was a086c58).

Summary of actions:
- Latest objects have been fetched from 'origin'
- Release branch has been merged into 'master'
- The release was tagged 'base_app'
- Release branch has been back-merged into 'develop'
- Release branch 'release/base_app' has been deleted

At this point I’ve created a feature and a release for version 0.0.1 of the application I’ve just created. If the application is run the default Strongloop API Loopback Server is viewable, albeit there is nothing being served at the moment. So next I’ll add some models and related items to the server. First, start a new feature.

git flow feature start add_model_flight

Now I’ll add a Loopback model that I’ll call flight. Below that I’ve added several properties to the model including a geopoint, date and several properties that are strings.

$ slc loopback:model
[?] Enter the model name: flight
[?] Select the data-source to attach flight to: db (memory)
[?] Select model's base class: PersistedModel
[?] Expose flight via the REST API? Yes
[?] Custom plural form (used to build REST URL): flights
Let's add some flight properties now.

Enter an empty property name when done.
[?] Property name: name
invoke loopback:property
[?] Property type: string
[?] Required? Yes

Let's add another flight property.
Enter an empty property name when done.
[?] Property name: flightId
invoke loopback:property
[?] Property type: string
[?] Required? Yes

Let's add another flight property.
Enter an empty property name when done.
[?] Property name: notes
invoke loopback:property
[?] Property type: string
[?] Required? No

Let's add another flight property.
Enter an empty property name when done.
[?] Property name: takeoff
invoke loopback:property
[?] Property type: date
[?] Required? Yes

Let's add another flight property.
Enter an empty property name when done.
[?] Property name: from
invoke loopback:property
[?] Property type: geopoint
[?] Required? Yes

Let's add another flight property.
Enter an empty property name when done.

Now I’ll wrap up the feature and move to another feature.

git add -A
git commit -m 'Added the flight model.'
git flow feature finish add_model_flight

Then start a new model with the git-flow feature.

git flow feature start add_model_airport

I now added another model using the Loopback command as shown.

$ slc loopback:model
[?] Enter the model name: airport
[?] Select the data-source to attach airport to: db (memory)
[?] Select model's base class: PersistedModel
[?] Expose airport via the REST API? Yes
[?] Custom plural form (used to build REST URL): airports
Let's add some airport properties now.

Enter an empty property name when done.
[?] Property name: name
invoke loopback:property
[?] Property type: string
[?] Required? Yes

Let's add another airport property.
Enter an empty property name when done.
[?] Property name: code
invoke loopback:property
[?] Property type: string
[?] Required? Yes

Let's add another airport property.
Enter an empty property name when done.
[?] Property name: notes
invoke loopback:property
[?] Property type: string
[?] Required? No

Let's add another airport property.
Enter an empty property name when done.
[?] Property name: location
invoke loopback:property
[?] Property type: geopoint
[?] Required? Yes

Now I wrapped up this feature by committing the files and finishing the feature with git-flow.

git add -A
git commit -m 'Added the airport model.'
git flow feature finish add_model_airport

To finalize this and release my v1_app I’ll start a release.

git flow release start v1_release

Now I’ll publish that release and finalize it by closing the release.

git flow release publish v1_release
git flow release finish v1_release

…and that’s a wrap. For the actual repo and check out the specific git-flow branching path (with my various mistakes along the way that needed to be remerged, check out my github repo here). You can see the branch list that I’ve created here by check out this link and to see the actual branching graph. For more on git-flow be sure to check out the creator’s blog at nvie and for the block post that got this all started “A Successful Git Branching Model“.

Happy hacking, cheers!

Top 4: “Nobody Reads Blogs… Except Everybody Read Blogs”

I know I know, the marketers say it’s all about the single articles now. Nobody reads blogs. Nobody subscribes to blogs. Ya know, except of course for that small percentage of people that do.

…marketing, it’ll make you insane if you’re not careful.

But seriously, here’s a few blogs that are actually worth reading. They’re worth subscribing to and surprisingly, they’re blogs that businesses organize and write. Yes, I have and might be writing for some of them in the future. But I’m honestly basing this list on a few specific criteria:

  • The blog has to include some technical content that is important to getting kick started with their product and getting kick started with other tooling around their space.
  • The blog has to include articles that have industry information that is relevant to conferences, meetups, and other community related activities.

Here’s my list of reads lately:

Codeship Blog – This company provides continuous integration and deployment services. Their services are super easy to get started with, besides having an excellent blog, one ought to try out their CI & CD services. The team is active in the tech communities. They regularly blog about getting Java, Node.js, Rails, Ruby or other stacks up and running, deploying cleanly and deployed to their final destinations.

Orchestrate Blog – The crew at Orchestrate (which I have written for a while back) have a steady stream of awesome flowing from their brains. The blog is chock full of ideas, implementations of various apps, and they are involved via the blog and in person with community events, conferences and the like. It’s a solid blog to be subscribed to.

AWS Blog – I’ve never written for the AWS blog, but I follow it as it is a steady stream of updates about the product and services but also includes other information regularly. They don’t always branch out beyond their space, but they’re so huge and cover so much space, the topics end up being pretty diverse anyway.

New Relic Blog – I write for New Relic on a regular basis. They’ve got a great selection of posts that go up from meetup recaps and notifications, to conference recaps, commentary and follow along of events and of course the technical content for everything from .NET to Java to Nodejs to Ruby on Rails. You name it, they likely have tips, tidbits and tricks every now and then.

There are a few others that I might tack onto this list in the future. But for now, that’s the top 4.