---
title: "Yay Shell Posting! New tools are always …"
author: "mike"
pubDate: "Thu, 30 Jan 2003 15:15:10 GMT"
link: "/posts/2003-01-30-yay-shell-posting-new-tools-are-always-fun-mtsend/"
urlPrev: "/posts/2003-01-30-i-can-just-hear-the-old-soldiers-now/index.md"
urlNext: "/posts/2003-01-31-multnomah-county-passes-antiwar-resolution/index.md"
---


*January 30, 2003*

Yay Shell Posting!

New tools are always fun.  [mtsend.py](http://scott.yang.id.au/archives/000092.php) is a Python script for command-line posting to Movable Type 'blogs.  You just edit a plain text file then feed it to the script.  It also does basic 'blog info retrieval.  I'm working on some scripts to use with the [Mac script menu](http://www.apple.com/applescript/script_menu/) and [BBEdit](http://www.barebones.com/products/bbedit/index.shtml).

For starters, I guess, here's an AppleScript that dumps the contents of BBEdit into a tmp file then pipes that through the script (which requires, unfortunately, piped text and a specified operation via a switch):

tell application "BBEdit"

save front window to "Macintosh HD:Users:mph:.blog.tmp"

do shell script

("cat /Users/mph/.blog.tmp | /Users/mph/bin/mtsend.py -N")

end tell

display dialog "Entry Uploaded"

buttons("OK")

mtsend.py also offers the ability to retrieve a list of categories, recent entry numbers, and a few other things, all of which are pretty good candidates for a little editor-centered automation.

[Drop a line about this](mailto:mike@puddingtime.org?subject=Re%3A%20Yay%20Shell%20Posting%21%0ANew%20tools%20are%20always%20fun.%20mtsend.py%E2%80%A6).

← [I Can Just Hear The Old Soldiers Now](/posts/2003-01-30-i-can-just-hear-the-old-soldiers-now/index.md) · [Multnomah County Passes Antiwar Resolution](/posts/2003-01-31-multnomah-county-passes-antiwar-resolution/index.md) →

