mirror of
http://gitea.phreedom.club/localhost_frssoft/pleroma-cli
synced 2024-11-22 02:01:27 +00:00
added: reply to status
This commit is contained in:
parent
eb2b5846eb
commit
74f7bf9968
|
@ -156,7 +156,7 @@ timeline_menu()
|
|||
indexator=$(expr $indexator - 1)
|
||||
echo '_____'
|
||||
done
|
||||
menu=$(echo 'Prev\nNext\nShare\nThread\nMain menu' | fzy)
|
||||
menu=$(echo 'Prev\nNext\nReply\nShare\nThread\nMain menu' | fzy)
|
||||
case $menu in
|
||||
"Prev")
|
||||
indexator=$(expr $max_statuses - 1)
|
||||
|
@ -172,6 +172,11 @@ timeline_menu()
|
|||
offset=$(jj -i preload 0.id)
|
||||
json=$(timeline_api $offset)
|
||||
;;
|
||||
"Reply")
|
||||
echo 'Input id'
|
||||
read status_id
|
||||
write_status_menu $status_id
|
||||
;;
|
||||
"Share")
|
||||
echo 'Input id (s - stop)'
|
||||
sharemode=1
|
||||
|
@ -208,7 +213,8 @@ write_api_status()
|
|||
curl -s --compressed -H "Authorization: Bearer $auth" --url $instance_point/statuses \
|
||||
--data-urlencode "status=$1" \
|
||||
--data-urlencode "content_type=$content_type" \
|
||||
--data-urlencode "visibility=$status_visibility"
|
||||
--data-urlencode "visibility=$status_visibility" \
|
||||
--data-urlencode "in_reply_to_id=$replyto"
|
||||
}
|
||||
|
||||
write_status_menu()
|
||||
|
@ -216,6 +222,7 @@ write_status_menu()
|
|||
touch tmp_status.md
|
||||
content_type="$default_content_type"
|
||||
status_visibility="$default_visibility"
|
||||
replyto=$1
|
||||
sub_menu_lvl=1
|
||||
while [ $sub_menu_lvl -eq 1 ]; do
|
||||
clear
|
||||
|
@ -225,6 +232,9 @@ write_status_menu()
|
|||
echo "Chars: $(cat tmp_status.md | wc -m)"
|
||||
echo "Visiblity: $status_visibility"
|
||||
echo "Content type: $content_type"
|
||||
if [ -n "$replyto" ]; then
|
||||
echo "Reply to: $replyto"
|
||||
fi
|
||||
wrirepostmenu=$(echo "Write\nSend\nChange type\nVisiblity\nMain menu" | fzy)
|
||||
case $wrirepostmenu in
|
||||
"Write") echo > tmp_status.md; $EDITOR tmp_status.md ;;
|
||||
|
|
Loading…
Reference in a new issue