fix: aetheel logs now works in foreground mode, tee output to log file on start
This commit is contained in:
14
install.sh
14
install.sh
@@ -1044,7 +1044,8 @@ cd "$AETHEEL_DIR"
|
||||
case "${1:-start}" in
|
||||
start)
|
||||
shift 2>/dev/null || true
|
||||
exec $RUN_CMD "$AETHEEL_DIR/main.py" "$@"
|
||||
mkdir -p "$HOME/.aetheel/logs"
|
||||
exec $RUN_CMD "$AETHEEL_DIR/main.py" "$@" 2>&1 | tee -a "$HOME/.aetheel/logs/aetheel.log"
|
||||
;;
|
||||
setup)
|
||||
exec "$AETHEEL_DIR/install.sh" --setup
|
||||
@@ -1103,7 +1104,16 @@ case "${1:-start}" in
|
||||
esac
|
||||
;;
|
||||
logs)
|
||||
tail -f "$HOME/.aetheel/logs/aetheel.log" 2>/dev/null || echo "No log file found"
|
||||
LOG_FILE="$HOME/.aetheel/logs/aetheel.log"
|
||||
ERR_FILE="$HOME/.aetheel/logs/aetheel.error.log"
|
||||
if [ -f "$LOG_FILE" ]; then
|
||||
tail -f "$LOG_FILE"
|
||||
elif [ -f "$ERR_FILE" ]; then
|
||||
tail -f "$ERR_FILE"
|
||||
else
|
||||
echo "No log files found at ~/.aetheel/logs/"
|
||||
echo "Logs are created when you run 'aetheel start' or the background service is running."
|
||||
fi
|
||||
;;
|
||||
update)
|
||||
cd "$AETHEEL_DIR"
|
||||
|
||||
Reference in New Issue
Block a user