Skip to content

Commit

Permalink
docs: update README.md with example usage
Browse files Browse the repository at this point in the history
  • Loading branch information
bradleybonitatibus committed Jan 3, 2024
1 parent 1ab172b commit 92ec32f
Showing 1 changed file with 20 additions and 1 deletion.
21 changes: 20 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,23 @@ into well-structured data.

## Usage

TODO: show usage
```go
package main

import (
"log"
"github.com/bradleybonitatibus/frostparse"
)

func main() {
p := frostparse.New(
frostparse.WithLogFile("C:\\Program Files (x86)\\World of Warcraft 3.3.5a\\Logs\\WoWCombatLog"),
)
_data, err := p.Parse()
if err != nil {
log.Fatal("failed to parse combatlog: ", err)
}
// handle []*frostparse.CombatLogRecord how you please
}

```

0 comments on commit 92ec32f

Please sign in to comment.