Yes there is. Like this (quoting your own codepiece):
/usr/local/mysql/bin/mysqldump -uuser -pnone --opt test weight --socket=/var/lib/mysql/mysql.sock --add-drop-table > "test_table_dump_$datevar.sql"
I'm on XP machine now so can't test that but it ought to work. You might want to test with an empty text file first, to make sure it works, but that's the idea. For more information and fancy examples, take a look at linuxcommand.org
, it's a good site and probably has an example there that does the above, takes a date and makes a variable out of it.