Using Unix pipes with Go

Using Unix pipes with Go

šŸ“… — šŸ§® 709 words — šŸ·ļø tech go unix tutorial open-source

Header by Alan Levine CC BY 2.0

Go has made it easy to work with Unix operations, it comes with the platform-independent built-in package os to interface with the operating system.

They offer nice features such as os.Stdin and os.Stdout, wrappers of type os.File around the OS’s common standard streams.

The os/exec package is also great. It allows you to run Unix-tools from within your Go application.

Package exec runs external commands. It wraps os.StartProcess to make it easier to remap stdin and stdout, connect I/O with pipes, and do other adjustments.

šŸ’¬ Read more
Black and white picture of Gerben Jacobs
Hi!

Iā€™m a 36-year-old software engineer from The Netherlands. My interests lie with (web)development, databases, design patterns, social media, communities, APIs and open data.

Check out my project-based site at gerben.dev

I don't have an About page, but I do have a Now page.

Tags

agile 1 go 3 open-source 4 personal 11 php 5 roi-stock-portfolio 3 scandinavia-2013 3 stocks 3 tech 19 tutorial 1 unix 1 web 1 youtube 1

Socials

Meta