Merge pull request #4 from chnyda/master

Fix reclass parser to include OPT_IGNORE_CLASS_NOTFOUND
diff --git a/reclass/adapters/salt.py b/reclass/adapters/salt.py
index f4f331b..e2f415c 100755
--- a/reclass/adapters/salt.py
+++ b/reclass/adapters/salt.py
@@ -105,14 +105,16 @@
                               inventory_base_uri=options.inventory_base_uri,
                               nodes_uri=options.nodes_uri,
                               classes_uri=options.classes_uri,
-                              class_mappings=class_mappings)
+                              class_mappings=class_mappings,
+                              ignore_class_notfound=options.ignore_class_notfound)
         else:
             data = top(minion_id=None,
                        storage_type=options.storage_type,
                        inventory_base_uri=options.inventory_base_uri,
                        nodes_uri=options.nodes_uri,
                        classes_uri=options.classes_uri,
-                       class_mappings=class_mappings)
+                       class_mappings=class_mappings,
+                       ignore_class_notfound=options.ignore_class_notfound)
 
         print output(data, options.output, options.pretty_print)
 
diff --git a/reclass/config.py b/reclass/config.py
index 17d0dc6..6a49809 100644
--- a/reclass/config.py
+++ b/reclass/config.py
@@ -29,6 +29,9 @@
     ret.add_option('-c', '--classes-uri', dest='classes_uri',
                    default=defaults.get('classes_uri', OPT_CLASSES_URI),
                    help='the URI to the classes storage [%default]')
+    ret.add_option('-i', '--ignore-class-notfound', dest='ignore_class_notfound',
+                   default=defaults.get('ignore_class_notfound', OPT_IGNORE_CLASS_NOTFOUND),
+                   help='decision for not found classes [%default]')
     return ret
 
 
diff --git a/reclass/defaults.py b/reclass/defaults.py
index fb04c83..3892a89 100644
--- a/reclass/defaults.py
+++ b/reclass/defaults.py
@@ -16,6 +16,7 @@
 OPT_CLASSES_URI = 'classes'
 OPT_PRETTY_PRINT = True
 OPT_OUTPUT = 'yaml'
+OPT_IGNORE_CLASS_NOTFOUND = False
 
 CONFIG_FILE_SEARCH_PATH = [os.getcwd(),
                            os.path.expanduser('~'),