How to open a new tab in GNOME Terminal from command line? [closed]
I found the simplest way:
gnome-terminal --tab -e 'command 1' --tab -e 'command 2'
I use tmux
instead of using terminal directly. So what I want is really a single and simple command/shell file to build the development env
with several tmux
windows. The shell code is as below:
#!/bin/bashtabs="adb ana repo"gen_params() { local params="" for tab in ${tabs} do params="${params} --tab -e 'tmux -u attach-session -t ${tab}'" done echo "${params}"}cmd="gnome-terminal $(gen_params)"eval $cmd