aboutsummaryrefslogtreecommitdiffstats
path: root/toggle-term.sh
diff options
context:
space:
mode:
Diffstat (limited to 'toggle-term.sh')
-rwxr-xr-xtoggle-term.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/toggle-term.sh b/toggle-term.sh
index ab5f87f..ace5978 100755
--- a/toggle-term.sh
+++ b/toggle-term.sh
@@ -49,7 +49,7 @@ toggle_split() {
# *
# *
panes_list="$($TMUX_CMD list-panes -F '#{window_flags}')"
- pane_count="$(echo "${panes_list}" | wc -l | bc)"
+ pane_count="$(echo "${panes_list}" | wc -l | sed 's/^[[:space:]]*//g')"
if [ "${pane_count}" = 1 ]; then
# And when we only have 1 pane, we want to split it into two
# and open a new one at the current path of the first pane.