From 24ee5d96bd762bbd7f4baec65a086fbdad223f2c Mon Sep 17 00:00:00 2001 From: Hector Date: Fri, 25 Feb 2022 21:53:38 +0000 Subject: [PATCH] refactor: rename project module Rename the project module to include the full project URL instead of just the name. This better aligns with Go best-practices. --- src/cfg/basicAuth.go | 2 +- src/collector/f2b/collector.go | 4 ++-- src/collector/f2b/socket.go | 2 +- src/collector/textfile/collector.go | 2 +- src/exporter.go | 8 ++++---- src/go.mod | 2 +- 6 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/cfg/basicAuth.go b/src/cfg/basicAuth.go index bc5408f..991861e 100644 --- a/src/cfg/basicAuth.go +++ b/src/cfg/basicAuth.go @@ -1,6 +1,6 @@ package cfg -import "fail2ban-prometheus-exporter/auth" +import "gitlab.com/hectorjsmith/fail2ban-prometheus-exporter/auth" type hashedBasicAuth struct { username string diff --git a/src/collector/f2b/collector.go b/src/collector/f2b/collector.go index a125adb..2b502d6 100644 --- a/src/collector/f2b/collector.go +++ b/src/collector/f2b/collector.go @@ -1,9 +1,9 @@ package f2b import ( - "fail2ban-prometheus-exporter/cfg" - "fail2ban-prometheus-exporter/socket" "github.com/prometheus/client_golang/prometheus" + "gitlab.com/hectorjsmith/fail2ban-prometheus-exporter/cfg" + "gitlab.com/hectorjsmith/fail2ban-prometheus-exporter/socket" "log" ) diff --git a/src/collector/f2b/socket.go b/src/collector/f2b/socket.go index 189ea09..0473cd1 100644 --- a/src/collector/f2b/socket.go +++ b/src/collector/f2b/socket.go @@ -1,8 +1,8 @@ package f2b import ( - "fail2ban-prometheus-exporter/socket" "github.com/prometheus/client_golang/prometheus" + "gitlab.com/hectorjsmith/fail2ban-prometheus-exporter/socket" "log" ) diff --git a/src/collector/textfile/collector.go b/src/collector/textfile/collector.go index 0acc5a2..7b43cb0 100644 --- a/src/collector/textfile/collector.go +++ b/src/collector/textfile/collector.go @@ -1,8 +1,8 @@ package textfile import ( - "fail2ban-prometheus-exporter/cfg" "github.com/prometheus/client_golang/prometheus" + "gitlab.com/hectorjsmith/fail2ban-prometheus-exporter/cfg" "log" ) diff --git a/src/exporter.go b/src/exporter.go index 5b2c837..95af1e0 100644 --- a/src/exporter.go +++ b/src/exporter.go @@ -1,13 +1,13 @@ package main import ( - "fail2ban-prometheus-exporter/auth" - "fail2ban-prometheus-exporter/cfg" - "fail2ban-prometheus-exporter/collector/f2b" - "fail2ban-prometheus-exporter/collector/textfile" "fmt" "github.com/prometheus/client_golang/prometheus" "github.com/prometheus/client_golang/prometheus/promhttp" + "gitlab.com/hectorjsmith/fail2ban-prometheus-exporter/auth" + "gitlab.com/hectorjsmith/fail2ban-prometheus-exporter/cfg" + "gitlab.com/hectorjsmith/fail2ban-prometheus-exporter/collector/f2b" + "gitlab.com/hectorjsmith/fail2ban-prometheus-exporter/collector/textfile" "log" "net/http" "os" diff --git a/src/go.mod b/src/go.mod index 23d3a9e..29a9e96 100644 --- a/src/go.mod +++ b/src/go.mod @@ -1,4 +1,4 @@ -module fail2ban-prometheus-exporter +module gitlab.com/hectorjsmith/fail2ban-prometheus-exporter go 1.15