mirror of
http://gitea.phreedom.club/localhost_frssoft/pleroma-cli
synced 2024-11-23 00:01:26 +00:00
Compare commits
2 commits
6609a6d169
...
2536388308
Author | SHA1 | Date | |
---|---|---|---|
localhost_frssoft | 2536388308 | ||
localhost_frssoft | e4daec319b |
|
@ -467,7 +467,7 @@ statuses_render()
|
|||
next=0
|
||||
force_stop=0
|
||||
while [ "$next" -eq 0 ]; do
|
||||
per_status_menu=$(echo "Next$menuattachments"$s_f_menu"\nFavorite\nReply\nBack" | fzy)
|
||||
per_status_menu=$(echo "Next$menuattachments"$s_f_menu"\nFavorite\nBookmark\nReply\nBack" | fzy)
|
||||
case "$per_status_menu" in
|
||||
"Next") next=1; clear ;;
|
||||
"Media")
|
||||
|
@ -478,6 +478,7 @@ statuses_render()
|
|||
"Share and favorite") share_and_favorite_mode "$id_status" ;;
|
||||
"Share") share_api_status "$id_status" ;;
|
||||
"Favorite") favorite_api_status "$id_status" ;;
|
||||
"Bookmark") bookmark_api_status "$id_status" ;;
|
||||
"Reply") reply_mode "$id_status" ;;
|
||||
"Back") next=1; force_stop=1 ;;
|
||||
esac
|
||||
|
@ -565,6 +566,7 @@ timeline_api()
|
|||
"home") default_curl_opt "$instance_point/timelines/home?limit=$max_statuses&max_id=$1&min_id=$2" ;;
|
||||
"home/local") default_curl_opt "$instance_point/timelines/home?local=true&limit=$max_statuses&max_id=$1&min_id=$2" ;;
|
||||
"favourites") default_curl_opt "$instance_point/favourites?limit=$max_statuses&max_id=$1&min_id=$2" ;;
|
||||
"bookmarks") default_curl_opt "$instance_point/bookmarks?limit=$max_statuses&max_id=$1&min_id=$2" ;;
|
||||
"direct") default_curl_opt "$instance_point/timelines/direct?limit=$max_statuses&max_id=$1&min_id=$2" ;;
|
||||
"public") default_curl_opt "$instance_point/timelines/public?limit=$max_statuses&max_id=$1&min_id=$2" ;;
|
||||
"local") default_curl_opt "$instance_point/timelines/public?local=true&limit=$max_statuses&max_id=$1&min_id=$2" ;;
|
||||
|
@ -695,6 +697,13 @@ favourite_mode()
|
|||
done
|
||||
}
|
||||
|
||||
bookmark_api_status()
|
||||
{
|
||||
mkdir -p -m 711 bookmarks/"$instance"
|
||||
post_request "$instance_point/statuses/$1/bookmark" | jj -p -o "bookmarks/$instance/$1"
|
||||
chmod 600 "bookmarks/$instance/$1"
|
||||
}
|
||||
|
||||
write_api_status()
|
||||
{
|
||||
if [ -n "$mediaattach" ]; then
|
||||
|
@ -840,6 +849,7 @@ menu_timeline='Timelines'
|
|||
notif='Notifications'
|
||||
followingsmenu='Followings'
|
||||
followrequests='Follow requests'
|
||||
my_account='Account'
|
||||
authmake='Auth'
|
||||
backup_restore='Backup/Restore'
|
||||
switchinstance='Switch instance'
|
||||
|
@ -847,20 +857,26 @@ Exit='Exit'
|
|||
|
||||
while true; do
|
||||
if [ -n "$auth" ]; then
|
||||
main_menu=$(echo "$menu_write_status\n$menu_timeline\n$notif\n$followingsmenu\n$followrequests\n$backup_restore\n$switchinstance\n$Exit" | fzy)
|
||||
main_menu=$(echo "$menu_write_status\n$menu_timeline\n$notif\n$my_account\n$switchinstance\n$Exit" | fzy)
|
||||
else
|
||||
main_menu=$(echo "$authmake\n$menu_timeline\n$switchinstance\n$Exit" | fzy)
|
||||
fi
|
||||
case $main_menu in
|
||||
"$menu_write_status") write_status_menu ;;
|
||||
"$menu_timeline")
|
||||
timeline=$(echo 'home\nhome/local\nfavourites\ndirect\nlocal\npublic' | fzy)
|
||||
timeline=$(echo 'home\nhome/local\nfavourites\nbookmarks\ndirect\nlocal\npublic' | fzy)
|
||||
timeline_menu
|
||||
;;
|
||||
"$notif") notif_menu ;;
|
||||
"$followingsmenu") followings_menu ;;
|
||||
"$followrequests") menu_follow_requests ;;
|
||||
"$backup_restore") backup_restore_menu ;;
|
||||
"$my_account")
|
||||
my_account_menu=$(echo "$followingsmenu\n$followrequests\n$backup_restore" | fzy)
|
||||
case $my_account_menu in
|
||||
"$followingsmenu") followings_menu ;;
|
||||
"$followrequests") menu_follow_requests ;;
|
||||
"$backup_restore") backup_restore_menu ;;
|
||||
esac
|
||||
;;
|
||||
|
||||
"$switchinstance")
|
||||
empty=0
|
||||
case $(echo 'Recently used\nChoice from list\nManual input' | fzy) in
|
||||
|
|
Loading…
Reference in a new issue