mirror of
https://github.com/AuxXxilium/yet-another-bench-script.git
synced 2024-11-23 23:01:02 +07:00
added warning if missing 'C' locale (issue #24)
This commit is contained in:
parent
1a56f57811
commit
f93aa1660a
12
yabs.sh
12
yabs.sh
@ -1,7 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Yet Another Bench Script by Mason Rowe
|
||||
# Initial Oct 2019; Last update Oct 2021
|
||||
# Initial Oct 2019; Last update Nov 2021
|
||||
#
|
||||
# Disclaimer: This project is a work in progress. Any errors or suggestions should be
|
||||
# relayed to me via the GitHub project page linked below.
|
||||
@ -15,7 +15,7 @@
|
||||
|
||||
echo -e '# ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## #'
|
||||
echo -e '# Yet-Another-Bench-Script #'
|
||||
echo -e '# v2021-10-09 #'
|
||||
echo -e '# v2021-11-29 #'
|
||||
echo -e '# https://github.com/masonr/yet-another-bench-script #'
|
||||
echo -e '# ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## #'
|
||||
|
||||
@ -23,7 +23,13 @@ echo -e
|
||||
date
|
||||
|
||||
# override locale to eliminate parsing errors (i.e. using commas as delimiters rather than periods)
|
||||
export LC_ALL=C
|
||||
if locale -a | grep ^C$ > /dev/null ; then
|
||||
# locale "C" installed
|
||||
export LC_ALL=C
|
||||
else
|
||||
# locale "C" not installed, display warning
|
||||
echo -e "\nWarning: locale 'C' not detected. Test outputs may not be parsed correctly."
|
||||
fi
|
||||
|
||||
# determine architecture of host
|
||||
ARCH=$(uname -m)
|
||||
|
Loading…
Reference in New Issue
Block a user