Share feature

This commit is contained in:
localhost_frssoft 2022-04-06 19:01:10 +03:00
parent 6f44f2b493
commit ff21d3087b

View file

@ -122,7 +122,7 @@ peertube_menu_video()
echo '_____'
fulldescr="\nFull description"
fi
menu_video_choice=$(echo "Play$fulldescr\nBack\nMain menu" | fzy)
menu_video_choice=$(echo "Play$fulldescr\nShare\nBack\nMain menu" | fzy)
case $menu_video_choice in
"Main menu") sub2_menu=0 && sub_menu=0 ;;
"Back") sub2_menu=0 ;;
@ -145,6 +145,12 @@ peertube_menu_video()
"Full description")
fulldesc=$(peertube_api_get_fulldescription $1)
echo "$fulldesc" | less -e ;;
"Share")
echo "Link: https://$instance/w/$1"
echo "Direct links:"
echo "$(echo $get_video | jj -l "$hls"files.#.resolution.label)"
echo "$(echo $get_video | jj -l "$hls"files.#.fileUrl)" ;;
esac
done
}
@ -173,7 +179,7 @@ peertube_menu_stream()
echo '_____'
fulldescr="\nFull description"
fi
menu_video_choice=$(echo "Play\nWait mode$fulldescr\nBack\nMain menu" | fzy)
menu_video_choice=$(echo "Play\nWait mode$fulldescr\nShare\nBack\nMain menu" | fzy)
case $menu_video_choice in
"Main menu") sub2_menu=0 && sub_menu=0 ;;
"Back") sub2_menu=0 ;;
@ -199,7 +205,13 @@ peertube_menu_stream()
;;
"Full description")
fulldesc=$(peertube_api_get_fulldescription $1)
echo "$fulldesc" | less -e ;;
echo "$fulldesc" | less -e ;;
"Share")
echo "Link: https://$instance/w/$1"
echo "Direct links:"
echo "$(echo $get_video | jj -l "$hls"files.#.resolution.label)"
echo "$(echo $get_video | jj -l "$hls"files.#.fileUrl)" ;;
esac
done
}