@ -10,15 +10,16 @@ function error {
if [ ! -z "$1" ];then
name="$1"
step=2
editing=yes
else
name=''
step=1
fi
#start on this step:
#step=2
#step=3
#start with this app name:
#name='Chromium Media Edition '
#name='Email Checker '
while true;do
case $step in
@ -53,7 +54,8 @@ With a few simple steps, your project can take advantage of Pi-Apps"\'" features
--field="Name of app:$([ ! -z "$namelocked" ]&&echo ':RO')" "$name" \
--field="Website:" "$(cat "${DIRECTORY}/apps/${name}/website" 2>/dev/null || echo '')" \
"$iconfield" "$iconpath" \
--field="Description:":TXT "$(cat "${DIRECTORY}/apps/${name}/description" 2>/dev/null || cat "${DIRECTORY}/apps/template/description")" \
--field="Description:":TXT "$(cat "${DIRECTORY}/apps/${name}/description" || cat "${DIRECTORY}/apps/template/description")" \
$([ ! -z $editing ]&&echo "--button=Save!${DIRECTORY}/icons/save.png:4") \
--button=Previous!"${DIRECTORY}/icons/back.png":2 \
--button=Next!"${DIRECTORY}/icons/forward.png":0 \
2>/dev/null)"
@ -63,7 +65,7 @@ With a few simple steps, your project can take advantage of Pi-Apps"\'" features
echo "Output: ${output}EOO"
output="$(echo "$output" | tr '|' '\n' )"
if [ $button == 0 ];then
if [ $button == 0 ] || [ $button == 4 ] ;then
#next
name="$(echo "$output" | sed -n '1p')"
website="$(echo "$output" | sed -n '2p')"
@ -136,7 +138,7 @@ Do you want to edit ${name}?" --timeout=10 \
--title="Create App: Step $step" --window-icon="${DIRECTORY}/icons/logo.png" --center --width=310 --height=300 \
--text='Now it'\''s time to make your install script. This will be executed anytime somebody clicks the Install button.
A text editor should have openened and you can create your install script.' \
--field="Run script":FBTN "lxterminal --title="\""Running install script of $name"\"" -e "\""cd $HOME;${DIRECTORY}/apps/${name}/install;echo 'Closing in 10 seconds.';sleep 10"\" \
--field="Run script":FBTN "lxterminal --title="\""Running install script of $name"\"" -e "\""cd $HOME;$'$ {DIRECTORY}/apps/${name}/install' ;echo 'Closing in 10 seconds.';sleep 10"\" \
--field="Shellcheck"!!'Having problems? This utility helps you locate syntax errors.':FBTN "lxterminal --title="\""Shellcheck"\"" -e "\""[ ! -f /usr/bin/shellcheck ]&&sudo apt install -y shellcheck &>/dev/null;shellcheck ${DIRECTORY}/apps/${name}/install;echo 'Press Enter to exit.';read enter"\" \
--button=Previous!"${DIRECTORY}/icons/back.png":2 \
--button=Next!"${DIRECTORY}/icons/forward.png":0 \
@ -169,7 +171,7 @@ A text editor should have openened and you can create your install script.' \
--title="Create App: Step $step" --window-icon="${DIRECTORY}/icons/logo.png" --center --width=310 --height=300 \
--text='Now it'\''s time to make your uninstall script. This will be executed anytime somebody clicks the Uninstall button.
A text editor should have openened... Never mind, you know what to do.' \
--field="Run script":FBTN "lxterminal --title="\""Running uninstall script of $name"\"" -e "\""cd $HOME;${DIRECTORY}/apps/${name}/uninstall;echo 'Closing in 10 seconds.';sleep 10"\" \
--field="Run script":FBTN "lxterminal --title="\""Running uninstall script of $name"\"" -e "\""cd $HOME;$'$ {DIRECTORY}/apps/${name}/uninstall' ;echo 'Closing in 10 seconds.';sleep 10"\" \
--field="Shellcheck"!!'Having problems? This utility helps you locate syntax errors.':FBTN "lxterminal --title="\""Shellcheck"\"" -e "\""[ ! -f /usr/bin/shellcheck ]&&sudo apt install -y shellcheck &>/dev/null;shellcheck ${DIRECTORY}/apps/${name}/uninstall;echo 'Press Enter to exit.';read enter"\" \
--button=Previous!"${DIRECTORY}/icons/back.png":2 \
--button=Next!"${DIRECTORY}/icons/forward.png":0 \
@ -238,8 +240,8 @@ Here'\''s a preview of the Details window:' \
;;
7)
echo "Done!
You app is located at ${DIRECTORY}/apps/${name}
To add your app to the Pi-Apps official repository, just open an issue for Botspot (the developer or Pi-Apps): https://github.com/Botspot/pi-apps/issues/new" | yad --text-info --fontname=12 --wrap --show-uri \
You app is located at <u> ${DIRECTORY}/apps/${name}</u>
To add your app to the Pi-Apps official repository, put that folder in a .ZIP file and open an issue for Botspot (the developer of Pi-Apps): https://github.com/Botspot/pi-apps/issues/new" | yad --text-info --fontname=12 --wrap --show-uri \
--image="${DIRECTORY}/icons/in-progress.png" --image-on-top \
--title="Create App Wizard" --window-icon="${DIRECTORY}/icons/logo.png" --center --width=310 --height=300 \
--button=Previous!"${DIRECTORY}/icons/back.png":0 \