sending mail

How do I send an email with a subject and an attachment from a command prompt?

hi

to send mail with attachment

i believe u need to have MIME email packages
example: mutt

[there could be better and optimistic solution also .....]

Try mailx in combination with uuencode.

This will encode your binary attachment in ascii which finally need to be decoded at receiving end.

Read the FAQ on email