export into config
This commit is contained in:
6
config
Normal file
6
config
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# Number of clients, maximum 2
|
||||||
|
CLIENTS=1
|
||||||
|
|
||||||
|
EVENT="Chaospott"
|
||||||
@@ -1,6 +1,13 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
DEVICE=/dev/ttyUSB2
|
|
||||||
function init() {
|
function init() {
|
||||||
|
|
||||||
|
if [ -n "$PRINTDEVICE" ]; then
|
||||||
|
export DEVICE="$PRINTDEVICE"
|
||||||
|
else
|
||||||
|
export DEVICE=/dev/ttyUSB2
|
||||||
|
fi
|
||||||
|
|
||||||
stty -F $DEVICE 1:0:80000dbd:0:3:1c:7f:15:4:5:1:0:11:13:1a:0:12:f:17:16:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0
|
stty -F $DEVICE 1:0:80000dbd:0:3:1c:7f:15:4:5:1:0:11:13:1a:0:12:f:17:16:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0:0
|
||||||
|
|
||||||
# \x1b\x47 - Double Strike
|
# \x1b\x47 - Double Strike
|
||||||
|
|||||||
@@ -1,10 +1,13 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
export LANG=C
|
export LANG=C
|
||||||
export EVENT=DiVOC
|
|
||||||
export TERM=vt220
|
export TERM=vt220
|
||||||
|
|
||||||
export DIALOGRC=dialogrc
|
export DIALOGRC=dialogrc
|
||||||
|
|
||||||
|
source ./config
|
||||||
|
|
||||||
|
export PRINTDEVICE="/dev/ttyUSB$CLIENTS"
|
||||||
|
|
||||||
LOCKFILE=/tmp/c3govlock
|
LOCKFILE=/tmp/c3govlock
|
||||||
TMP=/tmp/$RANDOM
|
TMP=/tmp/$RANDOM
|
||||||
BT="c3gov - v0.5"
|
BT="c3gov - v0.5"
|
||||||
@@ -388,7 +391,7 @@ function askForFunnyUserCreds() {
|
|||||||
askPw 12 "Login" "Password:" ""
|
askPw 12 "Login" "Password:" ""
|
||||||
password=$(cat $TMP)
|
password=$(cat $TMP)
|
||||||
|
|
||||||
if [ -f .pw/$username ]; then
|
if [ -f ".pw/$username" ]; then
|
||||||
if [ "$password" != $(cat .pw/$username) ]; then
|
if [ "$password" != $(cat .pw/$username) ]; then
|
||||||
clear
|
clear
|
||||||
echo "Wrong credentials."
|
echo "Wrong credentials."
|
||||||
|
|||||||
Reference in New Issue
Block a user