#!/bin/bash

# same location of aigui and cmd_ai

SCRIPT_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"

   input=$(zenity --text-info --editable --title="Input Text" --width=600 --height=400)

   if [ -n "$input" ]; then
         ${SCRIPT_PATH}/cmd_ai -r -g -n charlie "$input" | zenity --text-info --title="Command Output" --width=600 --height=400
   fi
