From 88b4a4fd4466d2270ec35083bb3959ca17c6d014 Mon Sep 17 00:00:00 2001 From: Benjamin Chausse Date: Sat, 10 Feb 2024 07:24:43 -0500 Subject: Use python for dropdown calc instead of R --- .local/bin/tmux-py | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100755 .local/bin/tmux-py (limited to '.local/bin') diff --git a/.local/bin/tmux-py b/.local/bin/tmux-py new file mode 100755 index 0000000..6076f80 --- /dev/null +++ b/.local/bin/tmux-py @@ -0,0 +1,17 @@ +#!/bin/sh + +session="Python" + +# Check if the session exists, discarding output +# We can check $? for the exit status (zero for success, non-zero for failure) +tmux has-session -t $session 2>/dev/null + +if [ $? != 0 ]; then + # Set up your session + tmux new-session -d -s "$session" python -q + # R -q --no-save + # ([ -e /usr/bin/R ] && R -q --no-save) || python -q +fi + +# Attach to created session +tmux attach-session -t $session -- cgit v1.2.3