anchor.diff:  ::  riff command line interface for Windows
   :: ##########################################################################
   
  -set RIFF_VERSION=0.0.2
  -
   :: set local scope for the variables with windows NT shell
  -if [%OS%]==[Windows_NT] setlocal
  +setlocal enabledelayedexpansion
  +
  +if [%RIFF_VERSION%]==[] (
  +    set RIFF_VERSION=0.0.2
  +)
   
   :: handle general help
   if [%1]==[] set _COMMAND=help
  
positive.code: if [%1]==[--name] set key=-n
  if [%1]==[--filename] set key=-f
  if [%1]==[--version] set key=-v
  if [%1]==[--container] set key=-c
  if [%1]==[--tail] set key=-t
  if [%1]==[--help] set key=-h
  if [%key%]==[-n] (
      set match=true
      set FUNCTION=%2
  
negative.code: echo.
  echo Usage:
  echo.
  echo   riff build -u ^<useraccount^> -n ^<name^> -v ^<version^> -f ^<path^> [--push]
  echo.
  echo Options:
  echo.
  echo   -u, --useraccount: the Docker user account to be used for the image repository (defaults to current OS username)
  echo   -n, --name: the name of the function (defaults to the name of the current directory)
  echo   -v, --version: the version of the function (defaults to 0.0.1)
  echo   -f, --filename: filename, directory, or URL for the code or resource (defaults to the current directory)
  echo   --push: push the image to Docker registry
  echo.
  exit /B 0
  
  :print_create_usage
  echo.
  echo Create the resource[s] for the function based on the function source code specified as the filename, using the name
  echo   and version specified for the function image repository and tag. Build the function and deploy it.
  echo.
  echo Usage:
  echo.
  echo   riff create -u ^<useraccount^> -n ^<name^> -v ^<version^> -f ^<source^> -l ^<language^> -p ^<protocol^> -i ^<input-topic^> -o ^<output-topic^> [-a ^<artifact^>] [--handler ^<handler-name^>] [--push]
  echo.
  echo Options:
  echo.
  echo   -u, --useraccount: the Docker user account to be used for the image repository (defaults to current OS username)
  echo   -n, --name: the name of the function (defaults to the name of the current directory)
  echo   -v, --version: the version of the function (defaults to 0.0.1)
  echo   -f, --filename: filename or directory to be used for the function resources, 
  echo                   if a file is specified then the file's directory will be used 
  echo                   (defaults to the current directory)
  echo   -l, --language: the language used for the function source
  echo                   (defaults to filename extension language type or 'shell' if directory specified)
  echo   -p, --protocol: the protocol to use for function invocations
  echo                   (defaults to 'stdio' for shell and python, to 'http' for java and node)
  echo   -i, --input: the name of the input topic (defaults to function name)
  echo   -o, --output: the name of the output topic (no default, only created if specified)
  echo   -a, --artifact: path to the function artifact, source code or jar file
  echo                   (defaults to function name with extension appended based on language: 
  echo                       '.sh' for shell, '.jar' for java, '.js' for node and '.py' for python)
  echo   --handler: the name of the handler, for Java it is the fully qualified class name of the Java class where the function is defined
  echo   --riff-version: the version of riff to use when building containers
  echo   --force: overwrite existing Dockerfile and function definitions
  echo   --push: push the image to Docker registry
  echo.
  exit /B 0
  
  