Command line submit node
Drush has a php-script argument which will allow you to run a PHP file with any code in it. Since Drush performs a bootstrap and includes the usual files required at Drupal runtime before running your script, you have all of the Drupal API available to you in your custom script.

If you need to submit any arbitrary form you can pre-populate a $form_state array and then submit the values using drupal_execute (see its API documentation). Getting to know what values to pre-populate in $form_state can be tricky, but this line can help you out:

drupal_set_message('&lt;pre&gt;' . print_r($form_state, TRUE) . '&lt;/pre&gt;';


Place this in the submit handler function for to the form you'd like to programatically submit and then run through the form once in your browser. Upon submitting that form, you should get a print out the $form_state structure that you would need to mimic. Be weary on live sites though, users will be able to see that debug message too!

If you're just needing to submitting nodes then you could even use node_save() directly which is a bit simpler. How to do this is detailed on another question, How to create nodes using node_save?