1
0
Fork
You've already forked mastodon-shell
0
Shell scripts to post to a Mastodon Account
  • Shell 100%
2025年03月04日 12:39:04 -06:00
LICENSE Initial commit 2023年05月09日 22:38:54 -06:00
mastodon-shell-post-media.sh Update mastodon-shell-post-media.sh 2025年03月04日 12:37:13 -06:00
mastodon-shell-post-text.sh Update and rename mastodon-post.sh to mastodon-shell-post-text.sh 2023年05月10日 09:03:19 -06:00
README.md Update README.md 2025年03月04日 12:39:04 -06:00

mastodon-shell

Shell scripts to post to a Mastodon Account or any other Fediverse server with a Mastodon-compatible API

Can post 1 to 4 media attachments with their ALT text

Usage

  • Posting just text: ./mastodon-shell-post-text.sh "Hello world!"

  • Posting text with an image:

./mastodon-shell-post-media.sh "Look at this image with ALT text #hashtag" "image1.jpg" "Description for image 1"

  • Posting text with two images:

./mastodon-shell-post-media.sh "Look at those images with ALT text #hashtag" "image1.jpg" "Description for image 1" "image2.jpg" "Description for image 2"

Configuration

Mastodon API documentation:
* https://docs.joinmastodon.org/methods/statuses/
# Create an application at:
## https://mastodon.example/settings/applications
#ACCESS_TOKEN=""
## FQDN of the mastodon server/instance
#MASTODON_SERVER="mastodon.example.com"
## visibility: String. Sets the visibility of the posted status to public, unlisted, private, direct.
#VISIBILITY="unlisted"
## language: String. ISO 639 language code for this status.
#LANG="en"
## End of configuration