From 77901bb05dbf75e92dd8974ccb23053bb3b2dabf Mon Sep 17 00:00:00 2001 From: xengineering Date: Wed, 16 Mar 2022 20:54:19 +0100 Subject: Add docstrings --- main.go | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'main.go') diff --git a/main.go b/main.go index 9c45241..672bb8d 100644 --- a/main.go +++ b/main.go @@ -1,5 +1,7 @@ // vim: shiftwidth=4 tabstop=4 noexpandtab +// stlscope is a file viewer for the STL file format. It is based on Go +// and OpenGL. package main import ( @@ -9,11 +11,13 @@ import ( "io/ioutil" ) +// cliArgs contains all data given via command line arguments. type cliArgs struct { filePath string debugOutput bool } +// main represents the whole functionality of stlscope. func main() { // read command line arguments and mute log if necessary @@ -50,6 +54,7 @@ func main() { } } +// read reads the command line arguments given to stlscope to a cliArgs struct. func (args *cliArgs) read() { flag.BoolVar(&args.debugOutput, "debug", false, "enable to print log output") -- cgit v1.2.3-70-g09d2