BTI(1)
π bti β the BTI(1) manual, but make it a group chat π
okay so bestie, welcome to BTI(1), aka the manual page for bti. she's small, she's mighty, she tweets from your terminal. let's get into it π«Ά
β¨ NAME β¨
bti β send a tweet to twitter.com from the command line π¦π
β¨ SYNOPSIS β¨
bti [--account account] [--password password] [--action action]
[--user screenname] [--host HOST_NAME] [--proxy PROXY:PORT]
[--logfile LOGFILE] [--config CONFIGFILE] [--replyto ID]
[--retweet ID] [--page PAGENUMBER] [--bash] [--shrink-urls]
[--debug] [--dry-run] [--verbose] [--version] [--help]
β¨ DESCRIPTION β¨
bti sends a tweet message to twitter.com. that's it. that's the whole personality. simple, iconic, no notes π
π OPTIONS π
--account accountβ tellsbtiwhich twitter.com account name to use π«Ά--password passwordβ the password for your twitter.com account. keep it cute, keep it secret π€«--action actionβ which thing do you wanna do?? valid options are:"update"to send a message,"friends"to see your friends timeline,"public"to track the public timeline,"replies"to see replies to your messages,"user"to see a specific user's timeline, and"direct"to send a direct message to a friend. the default is"update"β¨--user screennameβ when the action is"user", this is whose messages you wanna see. when the action is"direct", this is the receiver of the DM (and bestie, the sender must be following the receiver, that's the rule π)--host HOST_NAMEβ which host you're sending your message to. valid options are"twitter", to send to twitter.com.- if you don't specify a host, it defaults to sending to twitter.com π«
--proxy PROXY:PORTβ an http proxy value. not required, only needed if your system is behind an http proxy π- if
--proxyisn't specified but the environment variablehttp_proxyis set, thenhttp_proxygets used instead. she's flexible like that.
- if
--logfile LOGFILEβ a logfile forbtito write status messages to. heads up:LOGFILEis relative to your home directory, not an absolute path to a file. important detail, don't skip it π--config CONFIGFILEβ a config file forbtito read from. by defaultbtigoes looking in~/.btifor config values, but you can override that default location by pointing at a specific file with this option π--replyto IDβ the status ID of a single post you wanna create a threaded reply to.- for twitter, this gets ignored unless your message starts with the
@nameof the owner of the post with that status ID π - for status.net, this can link any two messages into context with each other. status.net will also link a message that contains an
@namewithout this, without regard to context. yeah. she does that.
- for twitter, this gets ignored unless your message starts with the
--retweet IDβ the status ID of a single post you wanna retweet π--shrink-urlsβ scans the tweet text for valid URL patterns and passes each one through the suppliedbti-shrink-urlsscript. that script hands the URL to a web service that shrinks it, which makes it way more suitable for micro-blogging π- the URL shrinking services available are:
http://2tu.us/(the default) andhttp://bit.ly/http://j.mp - peep the documentation for
bti-shrink-urlsfor the configuration options π
- the URL shrinking services available are:
--debugβ prints a whole bunch of debugging messages to stdout. a lot. a whole bunch. you've been warned π--page PAGENUMBERβ when the action is to retrieve updates, it usually only grabs one page. use this option and you can specify the page number π¦--dry-runβ does every single step that would normally happen for a given action, but will not connect to the service to post or retrieve data. it's the rehearsal, not the show β¨--verboseβ verbose mode. prints status IDs and timestamps π--bashβ adds the working directory and a'$'in the tweet message to help specify it's coming from a command line. and like, don't put the working directory and the'$'in the tweet message yourself, okay? let her do it.- this option implies
--backgroundπ
- this option implies
--backgroundβ does not report back any errors that might have happened while sending the message, and sends it in the background, returning immediately so you can keep doing your thing πββοΈ--versionβ print version number π’--helpβ print help text π«Ά
β¨ DESCRIPTION β¨
okay so bti gives you an easy way to send tweet messages directly from the command line or from any script. it reads the message on standard input, and it uses the account and password settings either from the command line options or from a config file, and then it sends the message out π
her primary focus? letting you log everything you type into a bash shell, in a crazy "this is what I'm doing right now!!" type of way, letting the world follow along with you as you constantly move between directories and refresh your email queue to see if anything interesting is going on. main character energy, honestly π
to hook bti up to your bash shell, export the following variable:
PROMPT_COMMAND='history 1 | sed -e "s/^\s*[0-9]*\s*//" | bti --bash'
this example assumes you already have ~/.bti set up with your account and password info in it β otherwise you can just specify them as an option π
π CONFIGURATION π
the account and password can be stored in a configuration file in the user's home directory, in a file named .bti. the structure of this file is as follows:
accountβ the twitter.com account name you wanna use to send this message with.passwordβ the twitter.com password for the account you wanna use to send this message with.--action actionβ specify the action you wanna perform. valid options are"update"to send a message,"friends"to see your friends timeline,"public"to track the public timeline,"replies"to see replies to your messages, and"user"to see a specific user's timeline.--user screennameβ specify the user whose messages you wanna see while the action is"user".hostβ the host you wanna use to send the message to. valid options are"twitter", or"custom"to specify your own server.proxyβ the http proxy needed to send data out to the Internet.logfileβ the logfile name forbtito write what happened to. this file is relative to the user's home directory. if this file isn't specified here or on the command line, no logging will be written to the disk πreplytoβ the status ID to which all notices will be linked to.- there is no sane reason for a need to have this set in a config file. one such reason is to have all your messages as children to a particular status. (her words, not mine π)
shrink-urlsβ setting this variable to'true'or'yes'enables the URL shrinking feature. this is equivalent to using the--shrink-urlsoption β¨verboseβ setting this variable to'true'or'yes'enables verbose mode π£οΈ
there's an example config file in /usr/share/doc/bti/examples/bti.example that shows the structure of the file π
configuration options have the following priority:
- command line option
- config file option
- environment variables
for example, command line options always override any config file option, or any environment variables. unless a config file is specified by the command line. at that point, the new config file is read, and any previous options set by a command line option would be overridden. the way that a later config file just swoops in and takes over?? it's giving plot twist πͺοΈ
π AUTHOR π
written by Greg Kroah-Hartman <greg@kroah.com> and Amir Mohammad Saied <amirsaied@gmail.com>. legends, honestly π«Ά
and that's the whole page, bestie!! this was bti from May 2008, living in the BTI(1) section of your manual pages. go forth and tweet from your terminal, you absolute icon π
β¨π
π¦ where this page comes from
- debian bookworm: bti 034-6+b1 Β· GPL-2.0-only
- debian trixie: bti 034-6+b3 Β· GPL-2.0-only
- ubuntu jammy: bti 034-6 Β· GPL-2.0-only
- ubuntu noble: bti 034-6build2 Β· GPL-2.0-only
- ubuntu questing: bti 034-6build3
- ubuntu resolute: bti 034-6build4 Β· GPL-2.0-only
- ubuntu stonking: bti 034-7 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms