[lib] args parsing fun