Skip to content

Instantly share code, notes, and snippets.

@avallete
Created July 13, 2019 12:11
Show Gist options
  • Select an option

  • Save avallete/1d5a250aaf0893b380470802489e78be to your computer and use it in GitHub Desktop.

Select an option

Save avallete/1d5a250aaf0893b380470802489e78be to your computer and use it in GitHub Desktop.
TERMStresser
#!/bin/bash
# Test to run the programme with all availables TERM into the terminal
# USAGE: ./script_term_test.sh "./lem-in < maps/test_2.map 1"
RED=$(printf "\e[31m")
GREEN=$(printf "\e[32m")
YELLOW=$(printf "\e[33m")
BLUE=$(printf "\e[34m")
MAGENTA=$(printf "\e[35m")
CYAN=$(printf "\e[36m")
WHITE=$(printf "\e[37m")
RESET=$(printf "\e[m")
for var in `toe -a | awk -F " " '{print $1}'`
do
env TERM=$var $1>&-
echo -n "Test TERM==$var: "
if [ `echo $?` != 0 ]; then
echo "${RED}ERROR${RESET}"
else
echo "${CYAN}SUCCESS${RESET}"
fi
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment