Skip to content

Commit

Permalink
fix(shell): disable shell on freebsd (#2522)
Browse files Browse the repository at this point in the history
  • Loading branch information
Codelax authored Sep 21, 2022
1 parent 85d7683 commit c6867f1
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 0 deletions.
4 changes: 4 additions & 0 deletions internal/core/shell.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
//go:build !freebsd
// +build !freebsd

// shell is disabled on freebsd as current version of github.com/pkg/term@v1.1.0 is not compiling
package core

import (
Expand Down
19 changes: 19 additions & 0 deletions internal/core/shell_disabled.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
//go:build freebsd
// +build freebsd

package core

import (
"context"
"fmt"
"os"

"github.com/spf13/cobra"
)

func RunShell(ctx context.Context, printer *Printer, meta *meta, rootCmd *cobra.Command, args []string) {
err := printer.Print(fmt.Errorf("shell is currently disabled on freebsd"), nil)
if err != nil {
_, _ = fmt.Fprintln(os.Stderr, err)
}
}

0 comments on commit c6867f1

Please sign in to comment.