Skip to content

Commit

Permalink
show usage when no flags specified
Browse files Browse the repository at this point in the history
  • Loading branch information
mr-pmillz committed Sep 3, 2024
1 parent bdc60ab commit 8bf2224
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

An End of Life Date API SDK written in Go

This is a fairly simple wrapper around the endoflife.date API
This is a wrapper around the endoflife.date API
[Read the Docs](https://endoflife.date/docs/api)

## Installation
Expand Down
5 changes: 5 additions & 0 deletions cmd/eoldate/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,11 @@ func main() {
os.Exit(0)
}

if eolOptions.Tech == "" {
gologger.Info().Msg("No technologies specified")
flag.Usage()
os.Exit(1)
}
releaseVersions, err := client.GetProduct(eolOptions.Tech)
if err != nil {
fmt.Printf("Error fetching product data: %v\n", err)
Expand Down
2 changes: 1 addition & 1 deletion eoldate.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
"net/http"
)

const CurrentVersion = `v0.0.2`
const CurrentVersion = `v0.0.3`
const EOLBaseURL = "https://endoflife.date/api"

// Options ...
Expand Down

0 comments on commit 8bf2224

Please sign in to comment.