Skip to content

Commit

Permalink
make linter happy
Browse files Browse the repository at this point in the history
  • Loading branch information
umbynos committed Apr 16, 2024
1 parent aad48b0 commit 228c2b2
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 1 deletion.
3 changes: 3 additions & 0 deletions args/args.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@
// a commercial license, send an email to [email protected].
//

// Package args provides functionality to parse command-line arguments.
// It includes a function to parse arguments passed by the user and a variable to check if the version flag is set.
// The package also handles invalid arguments by printing an error message and exiting the program.
package args

import (
Expand Down
7 changes: 6 additions & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
// a commercial license, send an email to [email protected].
//

// Package main implements the serial monitor
package main

import (
Expand Down Expand Up @@ -106,6 +107,7 @@ func NewSerialMonitor() *SerialMonitor {
}

// Hello is the handler for the pluggable-monitor HELLO command
// revive:disable:unused-parameter
func (d *SerialMonitor) Hello(userAgent string, protocol int) error {
return nil
}
Expand Down Expand Up @@ -171,7 +173,10 @@ func (d *SerialMonitor) Close() error {
if !d.openedPort {
return errors.New("port already closed")
}
d.serialPort.Close()
err := d.serialPort.Close()
if err != nil {
return err
}
d.openedPort = false
return nil
}
Expand Down
6 changes: 6 additions & 0 deletions version/version.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,12 @@
// a commercial license, send an email to [email protected].
//

// Package version provides information about the version of the application.
// It includes the version string, commit hash, and timestamp.
// The package also defines a struct `Info` that represents the version information.
// The `newInfo` function creates a new `Info` instance with the provided application name.
// The `String` method of the `Info` struct returns a formatted string representation of the version information.
// The package also initializes the `Version` variable with a default version string if it is empty.
package version

import (
Expand Down

0 comments on commit 228c2b2

Please sign in to comment.