Wrapping Up
Let's wrap up this chapter.
We'll cover the following
Summary
In this chapter:
- We designed and built a flexible tool that uses other tools and commands to execute specialized tasks in an automated way.
- We executed external commands, managed their error conditions, captured their output, and handled long-running processes appropriately.
- We tested our application using two different strategies: using a test helper to build a temporary local infrastructure, and mocking the external command.
Finally, we ensured our application handles the operating system signal in a clean way to correctly communicate the status to downstream applications and to prevent data loss.
What will we learn next?
In the next chapter, we’ll use the Cobra CLI framework to help us develop a command-line network port scanner by generating the boilerplate code for the application and handling flags and configuration in a more comprehensive way.
Get hands-on with 1400+ tech skills courses.