This commit is contained in:
Daniel Langbein 2021-06-17 16:52:12 +02:00
parent bf6924095f
commit cbc4253ca6
3 changed files with 6 additions and 2 deletions

View File

@ -2,7 +2,7 @@
_pkgname=rotate _pkgname=rotate
_reponame=arch _reponame=arch
pkgname="de-p1st-$_pkgname" pkgname="de-p1st-$_pkgname"
pkgver=0.0.4 pkgver=0.0.5
pkgrel=1 pkgrel=1
pkgdesc="Scripts to automate screen rotation" pkgdesc="Scripts to automate screen rotation"
arch=('any') arch=('any')

View File

@ -23,6 +23,10 @@ case "${ORIENTATION_STR}" in
*": left-up"*) *": left-up"*)
ORIENTATION="right"; ORIENTATION="right";
;; ;;
*": undefined"*)
echo "The orientation could not yet be determined. Please rotate the device a bit and try again."
exit 1;
;;
*) *)
echo "Could not parse ORIENTATION_STR!"; echo "Could not parse ORIENTATION_STR!";
echo "${ORIENTATION_STR}"; echo "${ORIENTATION_STR}";

View File

@ -1,7 +1,7 @@
#!/bin/bash #!/bin/bash
# @post: $SCREEN variable and $DEVICES array are set # @post: $SCREEN variable and $DEVICES array are set
source /etc/de-1st-rotate/config.cfg || exit $? source /etc/de-p1st-rotate/config.cfg || exit $?
if [ "$#" -ne "1" ]; then if [ "$#" -ne "1" ]; then
echo "usage: $0 ORIENTATION"; echo "usage: $0 ORIENTATION";