Category: Programming
Tags: #youtube #iprogrammer #gcc #c #command-line
Published: 2019-07-20

Writing a Command Line Utility in C Pt 1

Writing a command-line utility in C requires the understanding of several things beyond the c programming language: command-line parameters, how the parameters are passed into the program, how to parse the parameters in code; and how to use streams for both input and output. This episode is a real-time coding session where, from scratch, I use vim to write a basic C program that demonstrates how to read and interpret the parameters passed to the program via the command-line. I also demonstrate how to explore and understand the parameters through code. Using gcc to compile and link the program along the way, we end up with a command-line utility that can interpret a help switch and accept and process one parameter.

Some useful links are:

The c programming language




Command Line Interface

Don’t forget to like the video and subscribe to the channel!