02/

directory
v0.0.0-...-6ea799e Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 26, 2022 License: MIT

README

Techniques we will learn

  • concatenate
  • CLI pipeline - output to a file with >

Code we will use from the standard library

os.Create

This allows us to create a file.

func Create(name string) (*File, error)

defer

The defer keyword allows us to defer the execution of a statement until the function in which we have placed the defer statement returns.


io.Copy

This allows us to copy from from a source to a destination.

func Copy(dst Writer, src Reader) (written int64, err error)

strings.NewReader

NewReader returns a new Reader reading from s.

func NewReader(s string) *Reader

os.Args

Args is a variable from package os. Args hold the command-line arguments, starting with the program name.

var Args []string

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL