# Why is .mn file being generated?

I am running a Mathematica code inside a shell script, using math -script <filename>.m. But after the script finish its run, I get a duplicate (or backup?) file <filename>.mn . Why is such a file being generated? Is there a way to prevent that?

## migrated from mathematica.meta.stackexchange.comJun 15 '17 at 9:44

This question came from our discussion, support, and feature requests site for users of Wolfram Mathematica.

• I cant reproduce. You should provide system details, and check that this happens with a very simple script that you can post. – george2079 Jun 15 '17 at 13:56

I think it may be related to the Global option for AutoGeneratedPackage.

From interactive Mathematica go to

Format -> Options Inspector


Use the pulldown to set Show option values to Global Preferences

Select

Notebook Options -> File Options -> AutoGeneratePackage -> None

• seems it does not work for me! :( Also could be any terminal option since I'm using it remotely? – hbaromega Jun 27 '17 at 11:06