Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Plugin bugged showing "]697;OSClock=]697;PreExec" before everything #407

Open
juanmiret-sn opened this issue Feb 6, 2024 · 0 comments
Open

Comments

@juanmiret-sn
Copy link

Describe the bug
I have a custom plugin that was working just fine for months, and now it's showing "]697;OSClock=]697;PreExec---" in the menubar instead of the icon and every option inside the plugin menu shows "]697;OSClock=]697;PreExec" before the option text

To Reproduce

I'm using this plugim

#!/usr/bin/env zsh

# <swiftbar.hideAbout>true</swiftbar.hideAbout>
# <swiftbar.hideRunInTerminal>true</swiftbar.hideRunInTerminal>
# <swiftbar.hideLastUpdated>true</swiftbar.hideLastUpdated>
# <swiftbar.hideDisablePlugin>true</swiftbar.hideDisablePlugin>
# <swiftbar.hideSwiftBar>true</swiftbar.hideSwiftBar>

function get_connection_profile() {
  conn="$(ifconfig -a | egrep "inet 10\.(80|81|253|254)\." -o)"
  case $conn in
    *10.80.*)
      echo 'us-east-1'
      ;;
    *10.81.*)
      echo 'ps-east-1'
      ;;
    *10.253.*)
      echo 'us-west-2'
      ;;
    *10.254.*)
      echo 'us-east-2'
      ;;
  esac
}

function get_connection_status() {
  ifconfig -a | egrep "inet 10\.(80|81|253|254)\." -o
}

conn=$(get_connection_status)

if [[ -z $conn ]]; then
  echo ':shield.slash.fill: | sfcolor=white sfsize=16'
else
  echo ':shield.fill: | sfcolor=orange sfsize=16'
fi
echo '---'
if [[ -n $conn ]]; then
  echo 'Connected to: ' $(get_connection_profile)
  echo '---'
  echo "Disconnect | bash=~/.shell-helpers/plugmein/unplugme.sh terminal=false"
fi
echo '---'
echo "Connect to us-east-1 | bash=~/.shell-helpers/plugmein/plugmein.sh param0=us-east-1 terminal=true"
echo "Connect to ps-east-1 | bash=~/.shell-helpers/plugmein/plugmein.sh param0=ps-east-1 terminal=true"
echo "Connect to us-west-2 | bash=~/.shell-helpers/plugmein/plugmein.sh param0=us-west-2 terminal=true"
echo "Connect to us-east-2 | bash=~/.shell-helpers/plugmein/plugmein.sh param0=us-east-2 terminal=true"

Screenshots
Screenshot 2024-02-06 at 14 09 17

Environment:

  • macOS version: Sonoma 14.3
  • SwiftBar version: 2.0.1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant