init
This commit is contained in:
20
run-hyun2.sh
Executable file
20
run-hyun2.sh
Executable file
@@ -0,0 +1,20 @@
|
||||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
ENV_FILE="${BIZMAX_ENV_FILE:-$SCRIPT_DIR/.env}"
|
||||
|
||||
if [[ -f "$ENV_FILE" ]]; then
|
||||
set -a
|
||||
# shellcheck disable=SC1090
|
||||
source "$ENV_FILE"
|
||||
set +a
|
||||
fi
|
||||
|
||||
if [[ -z "${BIZMAX_ID:-}" || -z "${BIZMAX_PASSWORD:-}" ]]; then
|
||||
echo "Set BIZMAX_ID and BIZMAX_PASSWORD before running." >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
BIZMAX_BASE_URLS="https://hyun2.bizmax.net" \
|
||||
node --experimental-strip-types "$SCRIPT_DIR/bizmax-download-excel.ts"
|
||||
Reference in New Issue
Block a user