• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

glynnbird/toot: A very simple Mastodon command-line client for posting toots.

原作者: [db:作者] 来自: 网络 收藏 邀请

开源软件名称(OpenSource Name):

glynnbird/toot

开源软件地址(OpenSource Url):

https://github.com/glynnbird/toot

开源编程语言(OpenSource Language):

JavaScript 100.0%

开源软件介绍(OpenSource Introduction):

toot

A simple command-line utility that allows you to post a "toot" (equivalent of a Tweet) on the Mastodon social network.

Installation

npm install -g toot

Running first time

When you first run toot you will be asked some questions in order for toot to authenticate with your Mastodon service

> toot
Before you start using toot, you need to authenticate with your Mastodon server.
...

You will be asked for:

  • which instance of Mastodon are you posting to? - there are many e.g. toot.cafe
  • what name you want to give your app? - the name you pick here will show up in your Mastodon settings under "Authorized apps"

You will then be asked to visit a long URL in your browser and be prompted for one further piece of information:

  • the code displayed when you visit the URL?

This is a once-only operation. Then your configuration is saved (in ~/.mastodon.json).

Sending a toot

After the inital setup, sending a toot is a breeze:

> toot "I'm sending a Toot from the command-line!"

You can also pipe data from other processes into toot:

> cat longfile.txt | grep 'message' | toot

Options

  • --visibility [direct|private|unlisted|public] - the visibility of the toot
  • --config [path] - location of the config file
  • --help - view help text
  • --version - show version number

e.g.

> toot --visibility private "secret"
> toot --config ~/myconfig.json --visibility unlisted "hello there"

Why would I want this?

Perhaps you want to set up a Mastodon account for servers you are looking after. They can then be easily configured to send status updates:

> 
> toot "$HOSTNAME is going down for maintenance. Farewell dear friends"
> toot "$HOSTNAME is up. I'm back!"

Reconfiguring

If you want to reconfigure Toot from the beginning, simply delete the ~/.mastodon.json file and run toot again to reauthorise.




鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
coolstar/Capella: Capella social media client for Mastodon发布时间:2022-08-17
下一篇:
cambrian-era/mastodon: Radical Town branch of mastodon.发布时间:2022-08-17
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap