English
Kamil Dudka

TriloBot Simulator (C++, Qt4, Flex, Readline, Boost)

Detail souboru

Jméno:Stáhnoutterminal.sh [Stáhnout]
Umístění: rob08
Velikost:1.2 KB
Poslední změna:2022-09-09 13:06

Zdrojový kód

#!/bin/sh
# Copyright (C) 2008 Kamil Dudka <xdudka00@stud.fit.vutbr.cz>
#
# This file is part of rob08
#
# rob08 is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# any later version.
#
# rob08 is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with rob08.  If not, see <http://www.gnu.org/licenses/>.
 
SIMULTATOR=build/simulator
VISUALIZER=build/visualizer
TERMINAL=build/terminal
 
# delay to start chat
DT_INIT=4
test "`hostname`" = "nbkamil" && DT_INIT=1
 
# PTY device pair
TERM_MASTER=/dev/ptyp0
TERM_SLAVE=/dev/ttyp0
 
killall $SIMULTATOR 2>/dev/null
killall $TERMINAL 2>/dev/null
make -j check || exit -1
clear
 
$SIMULTATOR $TERM_MASTER | $VISUALIZER &
PID_ROB08=$!
 
# run chat
trap "true" INT
sleep $DT_INIT
$TERMINAL $TERM_SLAVE < `tty`
 
killall --wait -10 $SIMULTATOR
wait