Skip to content

Commit

Permalink
Changed option macros to macro.
Browse files Browse the repository at this point in the history
  • Loading branch information
cmacmackin committed Jun 25, 2015
1 parent af5a99a commit 590bc63
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions example-project-file.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ predocmark: >
media_dir: ./media
docmark_alt: #
predocmark_alt: <
macros: TEST
LOGIC=.true.
macro: TEST
LOGIC=.true.

This is a project which I wrote. This file will provide the documents. I'm
writing the body of the text here. It contains an overall description of the
Expand Down
10 changes: 5 additions & 5 deletions ford/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ def main():
parser.add_argument("--exclude",action="append",help="any files which should not be included in the documentation")
parser.add_argument("--exclude_dir",action="append",help="any directories whose contents should not be included in the documentation")
parser.add_argument("-e","--extensions",action="append",help="extensions which should be scanned for documentation (default: f90, f95, f03, f08)")
parser.add_argument("-m","--macros",action="append",help="preprocessor macro (and, optionally, its value) to be applied to files in need of preprocessing.")
parser.add_argument("-m","--macro",action="append",help="preprocessor macro (and, optionally, its value) to be applied to files in need of preprocessing.")
parser.add_argument("-w","--warn",dest='warn',action='store_true',
help="display warnings for undocumented items")
parser.add_argument("--no-warn",dest='warn',action='store_false',
Expand Down Expand Up @@ -103,7 +103,7 @@ def main():
u'project_sourceforge',u'project_url',u'display',u'version',
u'year',u'docmark',u'predocmark',u'docmark_alt',u'predocmark_alt',
u'media_dir',u'favicon',u'warn',u'extra_vartypes',u'page_dir',
u'source',u'exclude_dir',u'macros',u'preprocess']
u'source',u'exclude_dir',u'macro',u'preprocess']
defaults = {u'project_dir': u'./src',
u'extensions': [u"f90",u"f95",u"f03",u"f08",u"F90",
u"F95",u"F03",u"F08"],
Expand All @@ -121,11 +121,11 @@ def main():
u'favicon': 'default-icon',
u'extra_vartypes': [],
u'source': 'false',
u'macros': [],
u'macro': [],
u'preprocess': 'true',
u'warn': 'false',
}
listopts = [u'extensions',u'display',u'extra_vartypes',u'project_dir',u'exclude',u'exclude_dir',u'macros']
listopts = [u'extensions',u'display',u'extra_vartypes',u'project_dir',u'exclude',u'exclude_dir',u'macro']

for option in options:
if hasattr(args,option) and getattr(args,option):
Expand Down Expand Up @@ -181,7 +181,7 @@ def main():
proj_data['display'], proj_data['exclude'], proj_data['exclude_dir'],
proj_data['docmark'], proj_data['predocmark'], proj_data['docmark_alt'],
proj_data['predocmark_alt'], warn, proj_data['extra_vartypes'],
fpp_ext, proj_data['macros'])
fpp_ext, proj_data['macro'])
if len(project.files) < 1:
print("Error: No source files with appropriate extension found in specified directory.")
sys.exit(1)
Expand Down

0 comments on commit 590bc63

Please sign in to comment.