refactor(go): adapt imports for go.mod consistency

This commit is contained in:
maxlandon 2023-01-05 21:57:38 +01:00 committed by Jan De Dobbeleer
parent 10668b72e9
commit 02c557f42e
175 changed files with 400 additions and 400 deletions

View file

@ -4,8 +4,8 @@ import (
"fmt" "fmt"
"strings" "strings"
"github.com/jandedobbeleer/oh-my-posh/regex" "github.com/jandedobbeleer/oh-my-posh/src/regex"
"github.com/jandedobbeleer/oh-my-posh/shell" "github.com/jandedobbeleer/oh-my-posh/src/shell"
"github.com/mattn/go-runewidth" "github.com/mattn/go-runewidth"
) )

View file

@ -4,8 +4,8 @@ import (
"fmt" "fmt"
"strings" "strings"
"github.com/jandedobbeleer/oh-my-posh/regex" "github.com/jandedobbeleer/oh-my-posh/src/regex"
"github.com/jandedobbeleer/oh-my-posh/shell" "github.com/jandedobbeleer/oh-my-posh/src/shell"
"github.com/mattn/go-runewidth" "github.com/mattn/go-runewidth"
) )

View file

@ -3,7 +3,7 @@ package ansi
import ( import (
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/shell" "github.com/jandedobbeleer/oh-my-posh/src/shell"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -3,7 +3,7 @@ package ansi
import ( import (
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/shell" "github.com/jandedobbeleer/oh-my-posh/src/shell"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -5,7 +5,7 @@ import (
"strconv" "strconv"
"strings" "strings"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/gookit/color" "github.com/gookit/color"
) )

View file

@ -2,7 +2,7 @@
package ansi package ansi
import "github.com/jandedobbeleer/oh-my-posh/platform" import "github.com/jandedobbeleer/oh-my-posh/src/platform"
func GetAccentColor(env platform.Environment) (*RGB, error) { func GetAccentColor(env platform.Environment) (*RGB, error) {
return nil, &platform.NotImplemented{} return nil, &platform.NotImplemented{}

View file

@ -3,7 +3,7 @@ package ansi
import ( import (
"errors" "errors"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/gookit/color" "github.com/gookit/color"
) )

View file

@ -7,7 +7,7 @@ import (
"path/filepath" "path/filepath"
"strings" "strings"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )

View file

@ -5,8 +5,8 @@ import (
"path/filepath" "path/filepath"
"strings" "strings"
"github.com/jandedobbeleer/oh-my-posh/engine" "github.com/jandedobbeleer/oh-my-posh/src/engine"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )

View file

@ -3,10 +3,10 @@ package cli
import ( import (
"fmt" "fmt"
"github.com/jandedobbeleer/oh-my-posh/ansi" "github.com/jandedobbeleer/oh-my-posh/src/ansi"
"github.com/jandedobbeleer/oh-my-posh/engine" "github.com/jandedobbeleer/oh-my-posh/src/engine"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/shell" "github.com/jandedobbeleer/oh-my-posh/src/shell"
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )

View file

@ -3,8 +3,8 @@ package cli
import ( import (
"fmt" "fmt"
"github.com/jandedobbeleer/oh-my-posh/engine" "github.com/jandedobbeleer/oh-my-posh/src/engine"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )

View file

@ -4,10 +4,10 @@ import (
"fmt" "fmt"
"time" "time"
"github.com/jandedobbeleer/oh-my-posh/ansi" "github.com/jandedobbeleer/oh-my-posh/src/ansi"
"github.com/jandedobbeleer/oh-my-posh/engine" "github.com/jandedobbeleer/oh-my-posh/src/engine"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/shell" "github.com/jandedobbeleer/oh-my-posh/src/shell"
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )

View file

@ -3,8 +3,8 @@ package cli
import ( import (
"fmt" "fmt"
"github.com/jandedobbeleer/oh-my-posh/font" "github.com/jandedobbeleer/oh-my-posh/src/font"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )

View file

@ -5,8 +5,8 @@ import (
"strings" "strings"
"time" "time"
"github.com/jandedobbeleer/oh-my-posh/ansi" "github.com/jandedobbeleer/oh-my-posh/src/ansi"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
color2 "github.com/gookit/color" color2 "github.com/gookit/color"
"github.com/spf13/cobra" "github.com/spf13/cobra"

View file

@ -3,9 +3,9 @@ package cli
import ( import (
"fmt" "fmt"
"github.com/jandedobbeleer/oh-my-posh/engine" "github.com/jandedobbeleer/oh-my-posh/src/engine"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/shell" "github.com/jandedobbeleer/oh-my-posh/src/shell"
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )

View file

@ -3,8 +3,8 @@ package cli
import ( import (
"fmt" "fmt"
"github.com/jandedobbeleer/oh-my-posh/engine" "github.com/jandedobbeleer/oh-my-posh/src/engine"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )

View file

@ -3,7 +3,7 @@ package cli
import ( import (
"strings" "strings"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )

View file

@ -4,9 +4,9 @@ import (
"sync" "sync"
"time" "time"
"github.com/jandedobbeleer/oh-my-posh/ansi" "github.com/jandedobbeleer/oh-my-posh/src/ansi"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/shell" "github.com/jandedobbeleer/oh-my-posh/src/shell"
) )
// BlockType type of block // BlockType type of block

View file

@ -10,11 +10,11 @@ import (
"strings" "strings"
"time" "time"
"github.com/jandedobbeleer/oh-my-posh/ansi" "github.com/jandedobbeleer/oh-my-posh/src/ansi"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/jandedobbeleer/oh-my-posh/segments" "github.com/jandedobbeleer/oh-my-posh/src/segments"
"github.com/jandedobbeleer/oh-my-posh/template" "github.com/jandedobbeleer/oh-my-posh/src/template"
"github.com/gookit/config/v2" "github.com/gookit/config/v2"
"github.com/gookit/config/v2/json" "github.com/gookit/config/v2/json"

View file

@ -3,10 +3,10 @@ package engine
import ( import (
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/ansi" "github.com/jandedobbeleer/oh-my-posh/src/ansi"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/segments" "github.com/jandedobbeleer/oh-my-posh/src/segments"
"github.com/gookit/config/v2" "github.com/gookit/config/v2"
"github.com/mitchellh/mapstructure" "github.com/mitchellh/mapstructure"

View file

@ -5,10 +5,10 @@ import (
"strings" "strings"
"time" "time"
"github.com/jandedobbeleer/oh-my-posh/ansi" "github.com/jandedobbeleer/oh-my-posh/src/ansi"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/shell" "github.com/jandedobbeleer/oh-my-posh/src/shell"
"github.com/jandedobbeleer/oh-my-posh/template" "github.com/jandedobbeleer/oh-my-posh/src/template"
) )
type Engine struct { type Engine struct {

View file

@ -4,10 +4,10 @@ import (
"errors" "errors"
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/ansi" "github.com/jandedobbeleer/oh-my-posh/src/ansi"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/shell" "github.com/jandedobbeleer/oh-my-posh/src/shell"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -30,8 +30,8 @@ import (
"strings" "strings"
"unicode/utf8" "unicode/utf8"
"github.com/jandedobbeleer/oh-my-posh/ansi" "github.com/jandedobbeleer/oh-my-posh/src/ansi"
"github.com/jandedobbeleer/oh-my-posh/regex" "github.com/jandedobbeleer/oh-my-posh/src/regex"
"github.com/esimov/stackblur-go" "github.com/esimov/stackblur-go"
"github.com/fogleman/gg" "github.com/fogleman/gg"

View file

@ -6,8 +6,8 @@ import (
"path/filepath" "path/filepath"
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/ansi" "github.com/jandedobbeleer/oh-my-posh/src/ansi"
"github.com/jandedobbeleer/oh-my-posh/shell" "github.com/jandedobbeleer/oh-my-posh/src/shell"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -4,9 +4,9 @@ import (
"fmt" "fmt"
"strings" "strings"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/jandedobbeleer/oh-my-posh/segments" "github.com/jandedobbeleer/oh-my-posh/src/segments"
) )
const ( const (

View file

@ -3,9 +3,9 @@ package engine
import ( import (
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -1,9 +1,9 @@
package engine package engine
import ( import (
"github.com/jandedobbeleer/oh-my-posh/ansi" "github.com/jandedobbeleer/oh-my-posh/src/ansi"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/shell" "github.com/jandedobbeleer/oh-my-posh/src/shell"
) )
// New returns a prompt engine initialized with the // New returns a prompt engine initialized with the

View file

@ -1,6 +1,6 @@
package engine package engine
import "github.com/jandedobbeleer/oh-my-posh/platform" import "github.com/jandedobbeleer/oh-my-posh/src/platform"
func shouldHideForWidth(env platform.Environment, minWidth, maxWidth int) bool { func shouldHideForWidth(env platform.Environment, minWidth, maxWidth int) bool {
if maxWidth == 0 && minWidth == 0 { if maxWidth == 0 && minWidth == 0 {

View file

@ -3,7 +3,7 @@ package engine
import ( import (
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -7,11 +7,11 @@ import (
"strings" "strings"
"time" "time"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/jandedobbeleer/oh-my-posh/segments" "github.com/jandedobbeleer/oh-my-posh/src/segments"
"github.com/jandedobbeleer/oh-my-posh/shell" "github.com/jandedobbeleer/oh-my-posh/src/shell"
"github.com/jandedobbeleer/oh-my-posh/template" "github.com/jandedobbeleer/oh-my-posh/src/template"
c "golang.org/x/text/cases" c "golang.org/x/text/cases"
"golang.org/x/text/language" "golang.org/x/text/language"

View file

@ -4,10 +4,10 @@ import (
"encoding/json" "encoding/json"
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/jandedobbeleer/oh-my-posh/segments" "github.com/jandedobbeleer/oh-my-posh/src/segments"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -1,4 +1,4 @@
module github.com/jandedobbeleer/oh-my-posh module github.com/jandedobbeleer/oh-my-posh/src
go 1.19 go 1.19

View file

@ -6,8 +6,8 @@ import (
"io" "io"
"net/http" "net/http"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
const ( const (

View file

@ -4,8 +4,8 @@ import (
"fmt" "fmt"
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
mock2 "github.com/stretchr/testify/mock" mock2 "github.com/stretchr/testify/mock"

View file

@ -5,8 +5,8 @@ import (
"errors" "errors"
"io" "io"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type Request struct { type Request struct {

View file

@ -4,8 +4,8 @@ import (
"net" "net"
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
mock2 "github.com/stretchr/testify/mock" mock2 "github.com/stretchr/testify/mock"

View file

@ -1,6 +1,6 @@
package main package main
import "github.com/jandedobbeleer/oh-my-posh/cli" import "github.com/jandedobbeleer/oh-my-posh/src/cli"
var ( var (
Version = "development" Version = "development"

View file

@ -4,7 +4,7 @@ import (
"bytes" "bytes"
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/cli" "github.com/jandedobbeleer/oh-my-posh/src/cli"
) )
func BenchmarkInit(b *testing.B) { func BenchmarkInit(b *testing.B) {

View file

@ -5,8 +5,8 @@ import (
"io/fs" "io/fs"
"time" "time"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/platform/battery" "github.com/jandedobbeleer/oh-my-posh/src/platform/battery"
mock "github.com/stretchr/testify/mock" mock "github.com/stretchr/testify/mock"
) )

View file

@ -5,8 +5,8 @@ import (
"strconv" "strconv"
"strings" "strings"
"github.com/jandedobbeleer/oh-my-posh/platform/cmd" "github.com/jandedobbeleer/oh-my-posh/src/platform/cmd"
"github.com/jandedobbeleer/oh-my-posh/regex" "github.com/jandedobbeleer/oh-my-posh/src/regex"
) )
func mapMostLogicalState(state string) State { func mapMostLogicalState(state string) State {

View file

@ -19,10 +19,10 @@ import (
"sync" "sync"
"time" "time"
"github.com/jandedobbeleer/oh-my-posh/log" "github.com/jandedobbeleer/oh-my-posh/src/log"
"github.com/jandedobbeleer/oh-my-posh/platform/battery" "github.com/jandedobbeleer/oh-my-posh/src/platform/battery"
"github.com/jandedobbeleer/oh-my-posh/platform/cmd" "github.com/jandedobbeleer/oh-my-posh/src/platform/cmd"
"github.com/jandedobbeleer/oh-my-posh/regex" "github.com/jandedobbeleer/oh-my-posh/src/regex"
process "github.com/shirou/gopsutil/v3/process" process "github.com/shirou/gopsutil/v3/process"
) )

View file

@ -6,9 +6,9 @@ import (
"strings" "strings"
"time" "time"
"github.com/jandedobbeleer/oh-my-posh/regex" "github.com/jandedobbeleer/oh-my-posh/src/regex"
"github.com/jandedobbeleer/oh-my-posh/platform/battery" "github.com/jandedobbeleer/oh-my-posh/src/platform/battery"
) )
func mapMostLogicalState(state string) battery.State { func mapMostLogicalState(state string) battery.State {

View file

@ -5,7 +5,7 @@ package platform
import ( import (
"time" "time"
"github.com/jandedobbeleer/oh-my-posh/platform/battery" "github.com/jandedobbeleer/oh-my-posh/src/platform/battery"
) )
func (env *Shell) BatteryState() (*battery.Info, error) { func (env *Shell) BatteryState() (*battery.Info, error) {

View file

@ -9,7 +9,7 @@ import (
"unicode/utf16" "unicode/utf16"
"unsafe" "unsafe"
"github.com/jandedobbeleer/oh-my-posh/regex" "github.com/jandedobbeleer/oh-my-posh/src/regex"
"golang.org/x/sys/windows" "golang.org/x/sys/windows"
) )

View file

@ -3,8 +3,8 @@ package properties
import ( import (
"fmt" "fmt"
"github.com/jandedobbeleer/oh-my-posh/ansi" "github.com/jandedobbeleer/oh-my-posh/src/ansi"
"github.com/jandedobbeleer/oh-my-posh/regex" "github.com/jandedobbeleer/oh-my-posh/src/regex"
) )
type Properties interface { type Properties interface {

View file

@ -3,8 +3,8 @@ package segments
import ( import (
"path/filepath" "path/filepath"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type Angular struct { type Angular struct {

View file

@ -4,8 +4,8 @@ import (
"fmt" "fmt"
"strings" "strings"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type Aws struct { type Aws struct {

View file

@ -3,8 +3,8 @@ package segments
import ( import (
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -6,8 +6,8 @@ import (
"path/filepath" "path/filepath"
"strings" "strings"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type Az struct { type Az struct {

View file

@ -1,8 +1,8 @@
package segments package segments
import ( import (
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type AzFunc struct { type AzFunc struct {

View file

@ -5,9 +5,9 @@ import (
"path/filepath" "path/filepath"
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -1,9 +1,9 @@
package segments package segments
import ( import (
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/platform/battery" "github.com/jandedobbeleer/oh-my-posh/src/platform/battery"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type Battery struct { type Battery struct {

View file

@ -10,8 +10,8 @@ import (
"sort" "sort"
"time" "time"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
// segment struct, makes templating easier // segment struct, makes templating easier

View file

@ -5,8 +5,8 @@ import (
"testing" "testing"
"time" "time"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -3,8 +3,8 @@ package segments
import ( import (
"encoding/json" "encoding/json"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type Cds struct { type Cds struct {

View file

@ -5,9 +5,9 @@ import (
"path/filepath" "path/filepath"
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -1,8 +1,8 @@
package segments package segments
import ( import (
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type Cf struct { type Cf struct {

View file

@ -3,8 +3,8 @@ package segments
import ( import (
"regexp" "regexp"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type CfTarget struct { type CfTarget struct {

View file

@ -5,8 +5,8 @@ import (
"os/exec" "os/exec"
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -5,9 +5,9 @@ import (
"path/filepath" "path/filepath"
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -1,8 +1,8 @@
package segments package segments
import ( import (
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type Cmake struct { type Cmake struct {

View file

@ -3,8 +3,8 @@ package segments
import ( import (
"strings" "strings"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type Cmd struct { type Cmd struct {

View file

@ -3,8 +3,8 @@ package segments
import ( import (
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -3,8 +3,8 @@ package segments
import ( import (
"strings" "strings"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type Connection struct { type Connection struct {

View file

@ -4,9 +4,9 @@ import (
"fmt" "fmt"
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -1,8 +1,8 @@
package segments package segments
import ( import (
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type Crystal struct { type Crystal struct {

View file

@ -1,8 +1,8 @@
package segments package segments
import ( import (
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
var ( var (

View file

@ -1,8 +1,8 @@
package segments package segments
import ( import (
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type Deno struct { type Deno struct {

View file

@ -1,9 +1,9 @@
package segments package segments
import ( import (
"github.com/jandedobbeleer/oh-my-posh/constants" "github.com/jandedobbeleer/oh-my-posh/src/constants"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type Dotnet struct { type Dotnet struct {

View file

@ -3,10 +3,10 @@ package segments
import ( import (
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/constants" "github.com/jandedobbeleer/oh-my-posh/src/constants"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -4,8 +4,8 @@ import (
"fmt" "fmt"
"strconv" "strconv"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
lang "golang.org/x/text/language" lang "golang.org/x/text/language"
"golang.org/x/text/message" "golang.org/x/text/message"

View file

@ -4,8 +4,8 @@ import (
"testing" "testing"
"time" "time"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -3,8 +3,8 @@ package segments
import ( import (
"strconv" "strconv"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type Exit struct { type Exit struct {

View file

@ -3,9 +3,9 @@ package segments
import ( import (
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -1,8 +1,8 @@
package segments package segments
import ( import (
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type Flutter struct { type Flutter struct {

View file

@ -5,8 +5,8 @@ import (
"strings" "strings"
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -4,8 +4,8 @@ import (
"errors" "errors"
"path" "path"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"gopkg.in/ini.v1" "gopkg.in/ini.v1"
) )

View file

@ -4,8 +4,8 @@ import (
"path" "path"
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
mock2 "github.com/stretchr/testify/mock" mock2 "github.com/stretchr/testify/mock"

View file

@ -7,9 +7,9 @@ import (
"strconv" "strconv"
"strings" "strings"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/jandedobbeleer/oh-my-posh/regex" "github.com/jandedobbeleer/oh-my-posh/src/regex"
"gopkg.in/ini.v1" "gopkg.in/ini.v1"
) )

View file

@ -8,9 +8,9 @@ import (
"strings" "strings"
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -4,8 +4,8 @@ import (
"encoding/json" "encoding/json"
"errors" "errors"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type gitVersion struct { type gitVersion struct {

View file

@ -4,8 +4,8 @@ import (
"errors" "errors"
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/alecthomas/assert" "github.com/alecthomas/assert"
mock2 "github.com/stretchr/testify/mock" mock2 "github.com/stretchr/testify/mock"

View file

@ -1,8 +1,8 @@
package segments package segments
import ( import (
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"golang.org/x/mod/modfile" "golang.org/x/mod/modfile"
) )

View file

@ -6,9 +6,9 @@ import (
"os" "os"
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -1,8 +1,8 @@
package segments package segments
import ( import (
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type Haskell struct { type Haskell struct {

View file

@ -5,9 +5,9 @@ import (
"fmt" "fmt"
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -3,9 +3,9 @@ package segments
import ( import (
"net" "net"
"github.com/jandedobbeleer/oh-my-posh/http" "github.com/jandedobbeleer/oh-my-posh/src/http"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type ipData struct { type ipData struct {

View file

@ -5,7 +5,7 @@ import (
"net" "net"
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
mock2 "github.com/stretchr/testify/mock" mock2 "github.com/stretchr/testify/mock"

View file

@ -3,8 +3,8 @@ package segments
import ( import (
"errors" "errors"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type ITerm struct { type ITerm struct {

View file

@ -3,7 +3,7 @@ package segments
import ( import (
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -3,8 +3,8 @@ package segments
import ( import (
"fmt" "fmt"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type Java struct { type Java struct {

View file

@ -4,8 +4,8 @@ import (
"fmt" "fmt"
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -1,8 +1,8 @@
package segments package segments
import ( import (
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type Julia struct { type Julia struct {

View file

@ -1,8 +1,8 @@
package segments package segments
import ( import (
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type Kotlin struct { type Kotlin struct {

View file

@ -3,8 +3,8 @@ package segments
import ( import (
"path/filepath" "path/filepath"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"gopkg.in/yaml.v3" "gopkg.in/yaml.v3"
) )

View file

@ -6,9 +6,9 @@ import (
"path/filepath" "path/filepath"
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -4,10 +4,10 @@ import (
"errors" "errors"
"fmt" "fmt"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/jandedobbeleer/oh-my-posh/regex" "github.com/jandedobbeleer/oh-my-posh/src/regex"
"github.com/jandedobbeleer/oh-my-posh/template" "github.com/jandedobbeleer/oh-my-posh/src/template"
) )
const ( const (

View file

@ -3,9 +3,9 @@ package segments
import ( import (
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View file

@ -1,8 +1,8 @@
package segments package segments
import ( import (
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
) )
type Lua struct { type Lua struct {

View file

@ -5,9 +5,9 @@ import (
"strings" "strings"
"testing" "testing"
"github.com/jandedobbeleer/oh-my-posh/mock" "github.com/jandedobbeleer/oh-my-posh/src/mock"
"github.com/jandedobbeleer/oh-my-posh/platform" "github.com/jandedobbeleer/oh-my-posh/src/platform"
"github.com/jandedobbeleer/oh-my-posh/properties" "github.com/jandedobbeleer/oh-my-posh/src/properties"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

Some files were not shown because too many files have changed in this diff Show more