File tree Expand file tree Collapse file tree 3 files changed +15
-1
lines changed Expand file tree Collapse file tree 3 files changed +15
-1
lines changed Original file line number Diff line number Diff line change 1515// a commercial license, send an email to license@arduino.cc.
1616//
1717
18+ // Package args provides functionality to parse command-line arguments.
19+ // It includes a function to parse arguments passed by the user and a variable to check if the version flag is set.
20+ // The package also handles invalid arguments by printing an error message and exiting the program.
1821package args
1922
2023import (
Original file line number Diff line number Diff line change 1515// a commercial license, send an email to license@arduino.cc.
1616//
1717
18+ // Package main implements the serial monitor
1819package main
1920
2021import (
@@ -106,6 +107,7 @@ func NewSerialMonitor() *SerialMonitor {
106107}
107108
108109// Hello is the handler for the pluggable-monitor HELLO command
110+ // revive:disable:unused-parameter
109111func (d * SerialMonitor ) Hello (userAgent string , protocol int ) error {
110112 return nil
111113}
@@ -171,7 +173,10 @@ func (d *SerialMonitor) Close() error {
171173 if ! d .openedPort {
172174 return errors .New ("port already closed" )
173175 }
174- d .serialPort .Close ()
176+ err := d .serialPort .Close ()
177+ if err != nil {
178+ return err
179+ }
175180 d .openedPort = false
176181 return nil
177182}
Original file line number Diff line number Diff line change 1515// a commercial license, send an email to license@arduino.cc.
1616//
1717
18+ // Package version provides information about the version of the application.
19+ // It includes the version string, commit hash, and timestamp.
20+ // The package also defines a struct `Info` that represents the version information.
21+ // The `newInfo` function creates a new `Info` instance with the provided application name.
22+ // The `String` method of the `Info` struct returns a formatted string representation of the version information.
23+ // The package also initializes the `Version` variable with a default version string if it is empty.
1824package version
1925
2026import (
You can’t perform that action at this time.
0 commit comments