Improve sql connection for custom project
It should use my own user, but that won't work on ubuntu right now.
This commit is contained in:
parent
9625065974
commit
e38beec96f
|
@ -8,6 +8,7 @@
|
||||||
let
|
let
|
||||||
|
|
||||||
positionOfCustomerName = if ownLib.onHikari {} then "5" else "7";
|
positionOfCustomerName = if ownLib.onHikari {} then "5" else "7";
|
||||||
|
mysqlUser = if ownLib.onHikari {} then "-u daniels" else "";
|
||||||
|
|
||||||
in writeShellApplication {
|
in writeShellApplication {
|
||||||
name = "custom-project";
|
name = "custom-project";
|
||||||
|
@ -81,10 +82,9 @@ in writeShellApplication {
|
||||||
tmux new-window -n database -t "$session"
|
tmux new-window -n database -t "$session"
|
||||||
tmux send-keys -t "$session:$windowId" "cd $editorPath" C-m
|
tmux send-keys -t "$session:$windowId" "cd $editorPath" C-m
|
||||||
tmux send-keys " renice -n 5 \$\$" C-m
|
tmux send-keys " renice -n 5 \$\$" C-m
|
||||||
|
tmux send-keys "mycli ${mysqlUser} -D "
|
||||||
if [ "$databaseName" != "" ]; then
|
if [ "$databaseName" != "" ]; then
|
||||||
tmux send-keys "mycli -u daniels -D $databaseName" C-m
|
tmux send-keys "$databaseName" C-m
|
||||||
else
|
|
||||||
tmux send-keys "mycli -u daniels -D "
|
|
||||||
fi
|
fi
|
||||||
tmux send-keys C-l
|
tmux send-keys C-l
|
||||||
(( "windowId+=1" ))
|
(( "windowId+=1" ))
|
||||||
|
|
Loading…
Reference in a new issue