Automatic new directory for new files

I am looking for some way to have a tidy folder system.

My idea is, when I create a new file for latex to automatically create a new folder under the same name inside my working directory and put all files in that folder (.aux, .pdf, .tex, .loc etc). It might be the case that some package does that, but I am relatively new to this.

Do you know any way of achieving something like this?

-
Welcome to TeX.sx! We typically do not include greetings or thanks in Q-A. Upvoting comments or answers is the preferred way to show appreciation. –  Peter Jansson Jan 18 '13 at 14:55

latex has the -output-directory option. In Linux with the bash shell you can use the shell script
#!/bin/sh
name=basename $1 .tex if [ ! -d "$name" ]; then
mkdir $name fi latex -output-directory$name $1  Save the above code to somewhere in your $PATH called newlatex.sh and remember to chmod it 700. Then from the directory in which you placed the .tex file call
$newlatex.sh filename.tex  or $ newlatex.sh filename