Can't add file attachments

Bug #457940 reported by seba
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
mutt (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

Binary package hint: mutt

Welcome,

I have following problem with my desktop working under 9.10 Beta.

On my 8.04 i had using mutt for sending email with attachment.
Now i can't get it to work.

When i try execute following command

Code:

 mutt -a 'test.txt' -s 'subject' <email address hidden> <'test'

i got answer
Code:

bash: test: No such file or directory

But the ls shows

Code:

/tmp/test$ ls
test.txt

Bash script:
time=`date`
backup_file="/backup_dir/$(date +%d%m%y).zip"
mutt -s "Backup $time" -a "$backup_file" admin@xxx </backup_dir/content.txt

This don't work also in 9.10.

ProblemType: Bug
Architecture: i386
CheckboxSubmission: acd4f3f0e3d549f6197752c11b793c2d
CheckboxSystem: edda5d4f616ca792bf437989cb597002
Date: Thu Oct 22 08:59:15 2009
DistroRelease: Ubuntu 9.10
NonfreeKernelModules: nvidia
Package: mutt 1.5.20-4ubuntu1
ProcEnviron:
 PATH=(custom, user)
 LANG=pl_PL.UTF-8
 SHELL=/bin/bash
ProcVersionSignature: Ubuntu 2.6.31-14.48-generic
SourcePackage: mutt
Uname: Linux 2.6.31-14-generic i686

Revision history for this message
seba (5-admin-starepro-info) wrote :
Revision history for this message
Rob W. Brooks (rob-atomicpenguin) wrote :

I'd like to help with this bug, but I'll need little more information from you. In your first example you report that you are seeing:

bash: test: No such file or directory.

This is referring to your expected content of the message and not the attachment. (Try changing <'test' to <'example' in your first example.)

Can you provide the error response to your second example? If the error message begins with "bash" it means the shell (Bourne Again SHell (bash)) is reporting a problem with the command.

Revision history for this message
seba (5-admin-starepro-info) wrote :

Hello,

I use single quote and < 'test' because i want put word "test" inside e-mail content.

But i think it don't understand me.

When i run this:
mutt -a 'test.txt' -s 'subject' admin@xxx<'example'
I got:
bash: example: No such file or directory

But it doesn't work even if want put txt file.

LANG=en_EN.UTF-8 mutt -a 'test.txt' -s 'subject' admin@xxx <test.txt
Can't stat admin@xxx No such file or directory
admin@xxx: unable to attach file.
administrator@xxx-desktop:~/Desktop$

The test file exist
ls test.txt
output
test.txt

I think something wrong with that comands
mutt -a 'test.txt' -s 'subject' admin@xxx <test.txt

I swear it was working before. Maybe someone could try test it.
It's look like wrong order of parameters... but it was working...

Regards

Revision history for this message
Andrew McCarthy (andrewmccarthy) wrote :

It appears that how "-a" works has changed slightly. Previously you'd have to put a -- after the last filename only if there were two or more attachments: "mutt -a file1 file2 -- <email address hidden>". Now the -- is required for any number of attachments, even one: "mutt -a file -- <email address hidden>". Also, "-a" must be the last command-line option used before the e-mail address. See the man page for details. Can you try changing the line in your script to:

mutt -s "Backup $time" -a "$backup_file" -- admin@xxx </backup_dir/content.txt

and see how it goes?

Changed in mutt (Ubuntu):
status: New → Incomplete
Revision history for this message
seba (5-admin-starepro-info) wrote :

Welcome.

Thank you Andrew McCarthy now it's start working after adding "--" after attachments.

That's good news.

I think it can be marked as solved.
Regards

Revision history for this message
Andrew McCarthy (andrewmccarthy) wrote :

Great, closing the bug!

Changed in mutt (Ubuntu):
status: Incomplete → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.