Skip to content

Instantly share code, notes, and snippets.

@rodrigo-brito
Created November 9, 2017 13:00
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rodrigo-brito/e54fe74161a0162868f205e873e1b774 to your computer and use it in GitHub Desktop.
Save rodrigo-brito/e54fe74161a0162868f205e873e1b774 to your computer and use it in GitHub Desktop.
inFile, _ := os.Open(path)
defer inFile.Close()
scanner := bufio.NewScanner(inFile)
scanner.Split(bufio.ScanLines)
for scanner.Scan() {
line := fscanner.Text()
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment