7
Developing for Different Platforms
One of the main reasons Go is such a powerful language for building a command-line application is how easy it is to develop an application that can be run on multiple machines. Go provides several packages that allow developers to write code that interacts with the computer independent of the specific operating system. These packages include os, time, path, and runtime. In the first section, we will discuss some commonly used functions in each of these packages and then provide some simple examples to pair with the explanations.
To further drill down the importance of these files, we will revisit the audiofile code and implement a couple of new features that utilize some of the methods that exist in these ...
Get Building Modern CLI Applications in Go now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.