I'm working on several versions of the same code in FORTRAN 77 and in every code I print the file name and version number, but after so many versions it has become tedious to have to change that line. I was wondering if there is a way for the code to retu its own file name since the file name has the version number in it? The line I have now looks something like this, codevers='testfile_v009' and print *, 'Code Version: ', codevers The only problem with this is that I copy the previous version of the code and make changes to it as the new version but often forget to update those lines in the code.
Any help appreciated! Thanks.
