<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Go on Life Long Learning, Thinking, and Curiosity - Tyson Maly Computer Engineer and Technical Manager</title>
    <link>http://www.tysonmaly.com/categories/go/</link>
    <description>Recent content in Go on Life Long Learning, Thinking, and Curiosity - Tyson Maly Computer Engineer and Technical Manager</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en-us</language>
    <lastBuildDate>Mon, 04 Jun 2018 18:42:31 -0400</lastBuildDate>
    
	<atom:link href="http://www.tysonmaly.com/categories/go/index.xml" rel="self" type="application/rss+xml" />
    
    
    <item>
      <title>Test Driven Development With Golang on OSX</title>
      <link>http://www.tysonmaly.com/programming/go/test-driven-developement-with-golang-on-osx/</link>
      <pubDate>Mon, 04 Jun 2018 18:42:31 -0400</pubDate>
      
      <guid>http://www.tysonmaly.com/programming/go/test-driven-developement-with-golang-on-osx/</guid>
      <description>How to do Test Driven Development with Go on OSX You are looking to start using TDD, but you want a simple tool setup to automate running your tests and giving you the red green display. I have been trying out different setups for programming Go with TDD on OSX, and I am going to show you one that is easy to setup. This post will cover the setup you need to code in one screen and have your tests automatically run and output in another screen.</description>
    </item>
    
    <item>
      <title>Go sql examples</title>
      <link>http://www.tysonmaly.com/programming/go/go-sql-examples/</link>
      <pubDate>Thu, 27 Apr 2017 00:28:13 +0000</pubDate>
      
      <guid>http://www.tysonmaly.com/programming/go/go-sql-examples/</guid>
      <description>Go sql examples using sqlx Assume you have two models a type Business and a type Widget in a one to many relationship.
I want to demonstrate two ways that you can load the widgets into a business object using sqlx. I am using postgresql.
package models import ( &#34;database/sql&#34; &#34;github.com/jmoiron/sqlx&#34; &#34;github.com/pkg/errors&#34; &#34;time&#34; ) type Business struct { Id int64 `db:&#34;id&#34; json:&#34;id&#34;` Name string `db:&#34;name&#34; json:&#34;name&#34;` Website sql.NullString `db:&#34;website&#34; json:&#34;</description>
    </item>
    
    <item>
      <title>Golang YAML to map</title>
      <link>http://www.tysonmaly.com/programming/go/golang-yaml-to-map/</link>
      <pubDate>Thu, 16 Mar 2017 02:27:59 +0000</pubDate>
      
      <guid>http://www.tysonmaly.com/programming/go/golang-yaml-to-map/</guid>
      <description>How to convert a YAML file to a map[string]string in Go Use go-yamlconfigfile project to convert simple yaml config files to maps in Go.
When you want to store secrets for your project, you should never keep them in source control. There have been too many documented cases of secrets being leaked because of this. If you are using public version control like github, people can simple scan through your history to find things you may have accidentally released to the public internet.</description>
    </item>
    
    <item>
      <title>How to process xml with invalid utf-8 bytes in Go including ISO 8859 1 encodings</title>
      <link>http://www.tysonmaly.com/programming/go/process-xml-invalid-utf-8-go/</link>
      <pubDate>Fri, 14 Oct 2016 21:33:16 +0000</pubDate>
      
      <guid>http://www.tysonmaly.com/programming/go/process-xml-invalid-utf-8-go/</guid>
      <description>I recently had to process a large number of xml files that were not UTF-8 encoded. They also happened to include characters that were outside the valid ASCII range. I did not really want to keep these invalid characters, and this solution will work for that use case.
If you do need to keep non-ascii characters, this simple solution will not work for you.
The trick to making this work is to create a wrapper around the io.</description>
    </item>
    
    <item>
      <title>Go Closures as Struct Members</title>
      <link>http://www.tysonmaly.com/programming/go/go-closures-struct-members/</link>
      <pubDate>Thu, 13 Oct 2016 11:16:41 +0000</pubDate>
      
      <guid>http://www.tysonmaly.com/programming/go/go-closures-struct-members/</guid>
      <description>How to store closures at runtime inside struct members in the Go programming language. I will also show you how you can change the closure stored as a member inside of your struct at runtime. I have used Perl for many years, and you can easily pass around closures and dynamically redefine classes at run time. You can even create entire classes at run time, I have done this, and it makes some really interesting patterns.</description>
    </item>
    
    <item>
      <title>How to compile libvips on OSX from source for image processing</title>
      <link>http://www.tysonmaly.com/programming/go/compile-libvips-osx-image-processing/</link>
      <pubDate>Fri, 30 Sep 2016 11:23:32 +0000</pubDate>
      
      <guid>http://www.tysonmaly.com/programming/go/compile-libvips-osx-image-processing/</guid>
      <description>Here are the steps needed to compile libvips from source. If you try to install it from homebrew, you will most likely run into a number of errors regarding the dependency gtk-doc. This will frustrate you, and you might abandon the effort. I will show you how to install the latest stable libvips without having to install gtk-doc
I normally do not like to use dependencies like this in my Go project, but the performance of image processing needs to be really good as this type of computing tends to use a ton of resources on a server.</description>
    </item>
    
    <item>
      <title>How to ignore vendor directory in git for Go projects</title>
      <link>http://www.tysonmaly.com/programming/go/ignore-vendor-directory-git/</link>
      <pubDate>Fri, 30 Sep 2016 11:06:03 +0000</pubDate>
      
      <guid>http://www.tysonmaly.com/programming/go/ignore-vendor-directory-git/</guid>
      <description>You accidentally added your vendor directory to git in your Go project. Now when you run git status you see all these modified files under the vendor directory.
Here is a quick command you can use to ignore these changes
First change to your project directory then run this command
git status | perl -ne &amp;#8216;/(vendor.+go)/ &amp;amp;&amp;amp; system &amp;#8220;git update-index &amp;#8211;assume-unchanged $1\n&amp;#8221;;&amp;#8217;
This will take each file mentioned in the status that is in your vendor directory and execute a git command against it to</description>
    </item>
    
    <item>
      <title>Golang Vendoring How to add vendoring to an existing Go project</title>
      <link>http://www.tysonmaly.com/programming/go/golang-vendoring-how-to-add-vendoring-to-an-existing-go-project/</link>
      <pubDate>Thu, 15 Sep 2016 14:46:31 +0000</pubDate>
      
      <guid>http://www.tysonmaly.com/programming/go/golang-vendoring-how-to-add-vendoring-to-an-existing-go-project/</guid>
      <description>How to add Vendoring to an existing Go Project to manage your dependencies In this post I want to discuss how you can add vendoring for your dependencies to an existing Go project that does not currently have a vendor directory.
I am working on a new version of Best Food Near Me. The original version used a version of Go that did not have vendoring support, but it has since been upgraded.</description>
    </item>
    
    <item>
      <title>Using Go and Perl in your Makefile.PL as part of your build process</title>
      <link>http://www.tysonmaly.com/programming/go/using-go-perl-makefile/</link>
      <pubDate>Fri, 17 Jun 2016 15:23:30 +0000</pubDate>
      
      <guid>http://www.tysonmaly.com/programming/go/using-go-perl-makefile/</guid>
      <description>Perl and Golang I want to show you quickly how you can integrate your Go programs into your Perl module process. That is, if you have a go executable program that you want to distribute with your Perl module and you also want to build the go executable as part of your Perl module build process, this is how you can do it.
I am assuming you have Go installed, and I am also assuming you are using ExtUtils::MakeMaker for your Perl module.</description>
    </item>
    
    <item>
      <title>Consul Service Discovery and leader election</title>
      <link>http://www.tysonmaly.com/devops/consul-service-discovery/</link>
      <pubDate>Wed, 18 May 2016 20:10:28 +0000</pubDate>
      
      <guid>http://www.tysonmaly.com/devops/consul-service-discovery/</guid>
      <description>Elect a leader with Consul for your service So I started testing out a service discovery platform called Consul by the company Hashicorp.
The system uses the raft consensus protocol, and you may run into issues with leader election when you try to restart each server node. I did, and before you start spending hours googling around, I am going to tell you what I did to elect a leader in my cluster.</description>
    </item>
    
    <item>
      <title>How to use SASS to generate CSS</title>
      <link>http://www.tysonmaly.com/programming/go/how-to-use-sass/</link>
      <pubDate>Wed, 11 May 2016 15:10:53 +0000</pubDate>
      
      <guid>http://www.tysonmaly.com/programming/go/how-to-use-sass/</guid>
      <description>Using SASS or SCSS to generate CSS with your favorite language I am not big on using grunt or gulp, but I do like the power of what SASS offers, so I am going to explain a simple method on how you can mix sass with your programming language. This method will work with any programming language, but I happen to be using this with Go as I work on the re-design of my food project.</description>
    </item>
    
    <item>
      <title>learning golang</title>
      <link>http://www.tysonmaly.com/programming/go/learning-golang/</link>
      <pubDate>Tue, 26 Apr 2016 15:12:31 +0000</pubDate>
      
      <guid>http://www.tysonmaly.com/programming/go/learning-golang/</guid>
      <description>learning golang , I want to share with you how I taught myself to program in Go. Teaching yourself to program in a new language such as Go is not difficult if you have some experience in C like languages. Choosing to learn Go is a personal choice for some people, and for others it may be part of their job. Some of my main reasons for deciding to learn golang are:</description>
    </item>
    
  </channel>
</rss>