Twitter has become a big part the online lives of a lot of people in the recent months. Twitter har blitt en stor del den elektroniske livet til mange mennesker i de siste månedene. Although in itself Twitter is a pretty simple service, which makes it easy for just about everyone to use it, it ships with an API which has helped people port it to just about every platform. Selv i seg selv Twitter er en ganske enkel tjeneste som gjør det enkelt for nesten alle til å bruke det, leveres den med en API som har hjulpet folk port den til omtrent alle plattformer. Twitter has been ported to web browsers, to cellphones, and apparently even Twitter har blitt oversatt til nettlesere, for mobiltelefoner, og tilsynelatende også washing machines vaskemaskiner haven't been spared. har ikke vært spart. The Linux command line has always been a favorite of geeks. Linux kommandolinje har alltid vært en favoritt for geeks. Here's a trick that's great fun, and could be useful if required. Her er et triks som er veldig moro, og kunne være nyttig hvis nødvendig.
Let's see how to post an update to your Twitter account right from the Linux command line. La oss se hvordan å legge inn en oppdatering til din Twitter-konto rett fra Linux kommandolinjen. This will also work on the MacOS X command line. Dette vil også arbeide på MacOS X kommandolinjen. Enter the following command in your terminal interface, replacing username and password with your Twitter account credentials, and status="Tweeting from the Linux command line" with your own message. Skriv inn følgende kommando i Terminal-grensesnitt, og erstatte brukernavn og passord med din Twitter-konto legitimasjon, og status = "Tweeting fra Linux kommandolinjen" med din egen melding.
# curl -u username:password -d status="Tweeting from the Linux command line" http://twitter.com/statuses/update.xml > /dev/null # Curl-u brukernavn: passord-D-status = "Tweeting fra Linux kommandolinjen" http://twitter.com/statuses/update.xml> / dev / null
So if your Twitter username is fuzzycat17 and you password is fur123ball the above command will look like this: Så hvis din Twitter-brukernavn er fuzzycat17 og du passordet er fur123ball ovenfor kommandoen vil se slik ut:
# curl -u fuzzycat17:fur123ball -d status="Tweeting from the Linux command line" http://twitter.com/statuses/update.xml > /dev/null # Curl-u fuzzycat17: fur123ball-D-status = "Tweeting fra Linux kommandolinjen" http://twitter.com/statuses/update.xml> / dev / null
Running this command will result in a new Tweet being posted from your account containing the words Tweeting from the Linux command line Kjører denne kommandoen vil resultere i en ny Tweet blir lagt ut fra kontoen din inneholder ordene Tweeting fra Linux kommandolinjen
Now go check your Twitter home page to see if the Tweet was posted correctly. Nå går sjekke din Twitter-hjemmeside for å se om Tweet ble gjort riktig.
As I said, this trick could be completely for geekish fun, or could be put to good use. Som jeg sa, kan dette trikset være helt for geekish moro, eller kan komme til praktisk bruk. You could integrate this command into shell script to notify you of something. Du kunne integrere denne kommandoen til shell script for å varsle deg om noe.
Happy Tweeting. Happy Tweeting.























Its cool tips, thx. Dens avkjøle tips, thx. How to make a script that implements these steps? Hvordan lage et skript som implementerer disse trinnene?
Can I assume that aa direct message or @ reply would simply be added to the sent string? Kan jeg anta at aa direkte melding eller @ svar ville bare bli lagt til den sendte strengen? For example curl -u fuzzycat17:fur123ball -d status=”@somename Tweeting from the Linux command line” For eksempel curl-u fuzzycat17: fur123ball-D-status = "@ somename Tweeting fra Linux kommandolinjen" http://twitter.com/statuses/update.xml http://twitter.com/statuses/update.xml > /dev/null; or status=”d somename . > / Dev / null; eller status = "d somename. . . . . ” "
True? Sant?