mirror of
http://gitea.phreedom.club/localhost_frssoft/pleroma-cli
synced 2024-11-22 02:01:27 +00:00
Improvments in reply/write menu
This commit is contained in:
parent
b2da8acfeb
commit
792ce471f0
|
@ -365,6 +365,7 @@ timeline_menu()
|
|||
echo 'Input id'
|
||||
read status_id
|
||||
write_status_menu $status_id
|
||||
indexator=$(expr $max_statuses - 1)
|
||||
;;
|
||||
"Share")
|
||||
echo 'Input id (s - stop)'
|
||||
|
@ -434,8 +435,14 @@ write_status_menu()
|
|||
replyto=$1
|
||||
mediaattach=
|
||||
http_code=
|
||||
sub_menu_lvl=1
|
||||
while [ $sub_menu_lvl -eq 1 ]; do
|
||||
if [ -n "$sub_menu_lvl" ]; then
|
||||
sub_menu_lvl=2
|
||||
level=2
|
||||
else
|
||||
sub_menu_lvl=1
|
||||
level=1
|
||||
fi
|
||||
while [ $sub_menu_lvl -eq $level ]; do
|
||||
clear
|
||||
echo 'Status:'
|
||||
cat tmp_status.md
|
||||
|
@ -452,7 +459,7 @@ write_status_menu()
|
|||
if [ -n "$http_code" ]; then
|
||||
echo "Send state: $http_code"
|
||||
fi
|
||||
wrirepostmenu=$(echo "Write\nSend\nAdd attach\nChange type\nVisiblity\nMain menu" | fzy)
|
||||
wrirepostmenu=$(echo "Write\nSend\nAdd attach\nChange type\nVisiblity\nBack\nMain menu" | fzy)
|
||||
case $wrirepostmenu in
|
||||
"Write") echo > tmp_status.md; $EDITOR tmp_status.md ;;
|
||||
"Send") http_code=$(write_api_status "$(cat tmp_status.md)") ;;
|
||||
|
@ -464,6 +471,7 @@ write_status_menu()
|
|||
"Visiblity")
|
||||
status_visibility=$(echo 'public\nunlisted\nlocal\nprivate\ndirect\nlist' | fzy)
|
||||
;;
|
||||
"Back") sub_menu_lvl=$(expr $level - 1) ;;
|
||||
"Main menu") sub_menu_lvl=0 ;;
|
||||
esac
|
||||
done
|
||||
|
|
Loading…
Reference in a new issue