Skip to content

Commit

Permalink
refactor(linux): rename files to better reflect purpose
Browse files Browse the repository at this point in the history
  • Loading branch information
joshuar committed Jun 11, 2023
1 parent c6037e6 commit 5c96287
Show file tree
Hide file tree
Showing 23 changed files with 12 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import (
"github.com/shirou/gopsutil/v3/process"
)

//go:generate stringer -type=appSensorType -output appSensor_types_linux.go -linecomment
//go:generate stringer -type=appSensorType -output appSensorProps.go -linecomment
const (
appStateDBusMethod = "org.freedesktop.impl.portal.Background.GetAppState"
appStateDBusPath = "/org/freedesktop/portal/desktop"
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import (
"github.com/rs/zerolog/log"
)

//go:generate stringer -type=batteryProp -output battery_props_linux.go -linecomment
//go:generate stringer -type=batteryProp -output batterySensorProps.go -linecomment

const (
upowerDBusDest = "org.freedesktop.UPower"
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion internal/linux/dbus_linux.go → internal/linux/dbus.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import (
"github.com/rs/zerolog/log"
)

//go:generate stringer -type=dbusType -output dbusTypes_string.go -linecomment
//go:generate stringer -type=dbusType -output dbusTypesStringer.go -linecomment
const (
sessionBus dbusType = iota // session
systemBus // system
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import (
"github.com/shirou/gopsutil/v3/mem"
)

//go:generate stringer -type=memoryStat -output mem_stats_linux.go -linecomment
//go:generate stringer -type=memoryStat -output memorySensorProps.go -linecomment

const (
memoryTotal memoryStat = iota + 1 // Memory Total
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import (
"github.com/rs/zerolog/log"
)

//go:generate stringer -type=networkProp -output network_connections_props_linux.go
//go:generate stringer -type=networkProp -output networkConnectionSensorProps.go

const (
networkManagerPath = "/org/freedesktop/NetworkManager"
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import (
"github.com/shirou/gopsutil/v3/net"
)

//go:generate stringer -type=networkStat -output network_statistics_stat_linux.go
//go:generate stringer -type=networkStat -output networkStatsSensorProps.go

const (
bytesSent networkStat = iota + 1
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import (
"github.com/rs/zerolog/log"
)

//go:generate stringer -type=powerProp -output power_props_linux.go
//go:generate stringer -type=powerProp -output powerSensorProps.go
const (
powerProfilesDBusPath = "/net/hadess/PowerProfiles"
powerProfilesDBusDest = "net.hadess.PowerProfiles"
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit 5c96287

Please sign in to comment.