Updated Examples in README.
authorRafał Długołęcki <rafal@dlugolecki.net.pl>
Sun, 26 Apr 2015 12:22:44 +0000 (14:22 +0200)
committerRafał Długołęcki <rafal@dlugolecki.net.pl>
Sun, 26 Apr 2015 12:22:44 +0000 (14:22 +0200)
README

diff --git a/README b/README
index add86148f874625eacb9a9b69dbe4517edf49c95..0bb82e98645ba1296fe1003e8e34b92757757b27 100644 (file)
--- a/README
+++ b/README
@@ -3,10 +3,16 @@ Command, a C++ library for handling command line arguments
 Designing to be used like follows:
 
 Example:
+
+    void some_function(std::string str) {
+        std::cout << "Some function" << std::endl;
+    }
+
     command::Command command(argc, argv, {
         command::Option<std::string>("f", "File path", [](std::string value)->void { cout << "Sth: " << value << endl; }),
         command::Argument<std::string>("File path", []()->void { cout << "Sth: " << value << endl; }),
         command::Option<void>("help", "Help description", [](void)->void { cout << "Sth: " << value << endl; }),
-        command::Option<void>("verbose", "Verbose option description", &myClass->verbose)
+        command::Option<void>("verbose", "Verbose option description", &myClass->verbose),
+        command::Option<void>("verbose", "Verbose option description", some_function)
     });