Saturday, November 5, 2016

Software Development Principles: KISS

Supposedly the band KISS used the acronym for the way that they constructed their songs.  KISS stands for Keep It Simple Stupid.  When applied to software development, the goal is to create applications that are easy to follow and maintain.  On the surface, this sounds like something that would be easy to do when developing software.  However, this is one of the most difficult principles to actually apply.
 
Not all developers fit this stereotype but most of us feel that learning new popular frameworks and software patterns are fun.  It is also nice to show off what we have learned by applying it as quickly as possible in code.  Sometimes there is a good fit between what is new and cool and a business need but not always.  I have seen time and time again where a developer wants to learn a new framework/pattern/library and they throw it into the project, unnecessarily over complicating it.  I am guilty of this myself.  Since I have a lot of experience with regular expressions, I sometimes use them even when there is a more simple solution.  Scott Hanselman has a saying, if you solve a problem with a regular expression, you now have two problems.  As an architect it is also easy to get into a pattern of over architecting a solution, creating layers where none are required. 

There was once a developer that I worked with that added a new front end framework to a solution.  It was cool, it was slick; but it was nearly impossible to read the code.  The people that came along later to maintain it could not understand it and they had to re-write it.  Over complicating software costs time.  Over complicating software costs money.

So how do you balance learning new frameworks while trying to keep software simple?  There is a saying, KISS as long as possible.  Imagine you are the one that will be coming along 10 years later to add new features to the application you are working on now.  Do yourself and every other developer that comes along to maintain it a favor by writing as simply as possible.  Shift your heart and your mind.  The purpose of writing code well is to solve a business problem, not to puff yourself up. 

You can apply the KISS principle to other areas as well.
  • Keep your Software Development Life Cycle process as simple as possible.  The level of Ceremony should correspond to the risk of the software.  If you are building software for a Fighter ejection seat, the Ceremony will be much higher than if you are building software to manage deals at a car dealership.  Most of the software that we create is not life threatening if it does not work perfectly. 
  • Do not create long drawn out requirements where the business rules are repeated throughout the document.  Requirements are good if they can be easily understood by the business, developers, and testers; not if the printed version is hefty.  Requirements are done when the developer has enough information to implement and testers have enough information to test.
  • Do not test what is already being tested.  Get with the developers to find out what they are testing and spend your time writing test scripts for what is not tested. 
  • Keep your life as simple as possible.  Don’t buy things that you won’t use.  In fact, if you haven’t used something in 10 years, donate it to the poor.  Don’t do things that are a complete waste of time.  Do things that have a positive impact that lasts. 



The KISS principle goes hand in hand with Single Responsibility Principle and YAGNI which we will cover later.       

Monday, April 11, 2016

Rapidly Setting Up an Azure PC with Chocolatey

Azure is a great platform.  It is easy to spin up developer and test machines.  Microsoft has default installs of Visual Studio but there is currently no way to select other software.  Silent installs are nothing new but Chocolatey takes it a step further to be a distribution point of installers.  Think of Chocolatey as NuGet but with applications instead.  With Chocolatey and Azure you can rapidly install the software that you need to work effectively.  This also works great if you purchase a new PC or laptop or decide to Nuke and Pave a machine.   
    

To install Chocolatey open an admin command window and execute this statement:

@powershell -NoProfile -ExecutionPolicy Bypass -Command "iex ((new-object net.webclient).DownloadString('https://chocolatey.org/install.ps1'))" && SET PATH=%PATH%;%ALLUSERSPROFILE%\chocolatey\bin


To make installing applications easier with Chocolately, I created a batch file to be called by a parent batch file called InstallApp.bat.  It has standard parameters of -y which is to accept all defaults.

cinst %1 -y


I then created the parent batch file with a list of the applications I wanted to install before installing Visual Studio.  If Visual Studio is already pre-installed on an Azure machine you can simply create one big batch file.

REM Media
call InstallApp paint.net
call InstallApp foxitreader
call InstallApp cutepdf
call InstallApp evernote
call InstallApp imgburn
call InstallApp zim
call InstallApp anyvideoconverter
call InstallApp notepadplusplus.install
call InstallApp picpick.portable
call InstallApp todoist

REM Web
call InstallApp firefox
call InstallApp googlechrome
call InstallApp flashplayerplugin
call InstallApp skype
call InstallApp teamviewer

REM Utilities
call InstallApp 7zip.install
call InstallApp filezilla
call InstallApp chocolateygui
call InstallApp winmerge
call InstallApp virtualclonedrive
call InstallApp beyondcompare
call InstallApp roboform
call InstallApp javaruntime
call InstallApp truecrypt
call InstallApp windirstat

REM Developer Tools before Visual Studio
call InstallApp tortoisesvn
call InstallApp expresso
call InstallApp ilspy
call InstallApp sliksvn
call InstallApp git.install
call InstallApp tortoisegit
call InstallApp visualstudiocode
call InstallApp baretail
call InstallApp nunit
call InstallApp httrack
call InstallApp xenulinksleuth
After installing Visual Studio I have a set of applications that I like to install:

REM Install After Visual Studio is Installed
call InstallApp visualsvn
call InstallApp resharper-platform
call InstallApp mono


That’s it.  Simply run the batch file and all the software that you need will be downloaded and installed without intervention.  Come back later and your PC will be ready.

Wednesday, January 20, 2016

Developer Conferences 2016

Here is the list of developer conferences for the Midwest and the major U.S. national conferences.  If you would like your conference listed.  Please contact me and I will add it.

CodeMash V2.0.1.6

Jaunary 5-8, Sandusky, Ohio
Conference Only – Thursday and Friday: $300
Conference + Precompiler – Tuesday through Friday: $600
http://codemash.org/


CocoaConf

March 25-26, Chicago, IL
Conference Only:  $550
Conference + Workshop:  $700
http://cocoaconf.com

Code PaLOUsa

Pricing:  $50
March 28-30, Louisville, KY, USA
http://www.codepalousa.com/


Visual Studio Live

March 7-11, Las Vegas, Nevada
May 16-19, Austin, TX
June 13-16, Boston, MA
August 8-12, Redmond, WA
September 26-29, Anaheim, CA
October 3-6, Washington, D.C.
http://vslive.com

Build

March 30-April 1, San Francisco, CA
Previous Pricing for 2015:  $2095
http://www.buildwindows.com/

StirTrek

Price $75
May, Columbus, Ohio
http://www.stirtrek.com/

Microsoft Ignite

September 26-30, Atlanta, GA
(Last Year 2015 Pricing)
Expo Only Pass:  $300
Day Pass:  $500
Full Conference Pass $2,220
http://ignite.microsoft.com

GoTo Conference

May 24-25
Pricing $950 to $2745 depending upon when you register and how many workshop days

http://gotocon.com/chicago-2016/

 

Dev Intersection

Pricing $1595 to $2942 depending upon when you register and how many pre-conference days
May 18-24, Scottsdale, AZ
http://devintersection.com

 

QCon

June 13-17 New York, NY
Price $1645 to $3885 depending upon how early you register
https://qconnewyork.com/

 

PyOhio

Sometime in August
Free
http://www.pyohio.org/

Codestock

Sometime in July, Knoxville, Tennessee
No Pricing Announced Yet:  ~$100
http://www.codestock.org/

Agile 2016

July 25 -29, Washington DC
Price $2399
https://www.agilealliance.org/agile2016/

That Conference

August 8-10, Wisconsin Dells, WI
$399.99
http://www.thatconference.com/

Dev Connections

October 10-13 Las Vegas, NV
Essentials:  $1199
All Access :  $1999
http://www.devconnections.com/

 

CloudDevelop

Sometime in October, Columbus, Ohio
No price announced this year.  Last years price was: $35
http://clouddevelop.org/

Columbus Code Camp

Sometime in October, Columbus, Ohio
Free
http://columbuscodecamp.com/

  

St Louis Day of .NET

Sometime in November, St. Charles, MO
No price announced this year.  Last years price was: $300
http://stldodn.com


Dog Food Conference

October 5th and 6th, Columbus, OH
No price announced yet.  Last year was $50
http://www.dogfoodcon.com