parse-options: move unsigned long option parsing out of pack-objects.c
[gitweb.git] / Documentation / technical / api-parse-options.txt
index be50cf4de35c856da051f985eb42c22dbaac88e4..525cb2f87a2a56db7837b7543037da7644b2b65a 100644 (file)
@@ -160,10 +160,6 @@ There are some macros to easily define options:
        `int_var` is set to `integer` with `--option`, and
        reset to zero with `--no-option`.
 
-`OPT_SET_PTR(short, long, &ptr_var, description, ptr)`::
-       Introduce a boolean option.
-       If used, set `ptr_var` to `ptr`.
-
 `OPT_STRING(short, long, &str_var, arg_str, description)`::
        Introduce an option with string argument.
        The string argument is put into `str_var`.
@@ -172,6 +168,12 @@ There are some macros to easily define options:
        Introduce an option with integer argument.
        The integer is put into `int_var`.
 
+`OPT_MAGNITUDE(short, long, &unsigned_long_var, description)`::
+       Introduce an option with a size argument. The argument must be a
+       non-negative integer and may include a suffix of 'k', 'm' or 'g' to
+       scale the provided value by 1024, 1024^2 or 1024^3 respectively.
+       The scaled value is put into `unsigned_long_var`.
+
 `OPT_DATE(short, long, &int_var, description)`::
        Introduce an option with date argument, see `approxidate()`.
        The timestamp is put into `int_var`.