About 25,200,000 results
Open links in new tab
  1. c++ - What does int argc, char *argv [] mean? - Stack Overflow

    The variables are named argc (argument count) and argv (argument vector) by convention, but they can be given any valid identifier: int main(int num_args, char** arg_strings) is equally valid.

  2. dockerfile - How do I set environment variables during the "docker ...

    When building a Docker image from the commandline, you can set ARG values using –build-arg: $ docker build --build-arg some_variable_name=a_value Running that command, with the above …

  3. How can I pass a list as a command-line argument with argparse?

    I am trying to pass a list as an argument to a command line program. Is there an argparse option to pass a list as option? parser.add_argument('-l', '--list', type=list, acti...

  4. python - Use of *args and **kwargs - Stack Overflow

    So I have difficulty with the concept of *args and **kwargs. So far I have learned that: *args = list of arguments - as positional arguments **kwargs = dictionary - whose keys become separate keyw...

  5. docker - Using ARG and ENV in Dockerfile - Stack Overflow

    Feb 28, 2020 · ARG before the first FROM are only useful to allow variables in the FROM line and to supply defaults, but can't be used otherwise. This is further discussed under Understand how ARG …

  6. How to pass arguments to a Dockerfile? - Stack Overflow

    I am using RUN instruction within a Dockerfile to install a rpm RUN yum -y install samplerpm-2.3 However, I want to pass the value "2.3" as an argument. My RUN instruction should look something li...

  7. Argparse: Required arguments listed under "optional arguments"?

    Parameters starting with - or -- are usually considered optional. All other parameters are positional parameters and as such required by design (like positional function arguments). It is possible to …

  8. How to get an environment variable value into Dockerfile during …

    Mar 19, 2019 · The ARG defines a variable to be used inside the dockerfile in subsequent commands. The ENV defines an environment variable which is passed to the container.

  9. What's the best way to parse command line arguments?

    What's the easiest, tersest, and most flexible method or library for parsing Python command line arguments?

  10. arguments - Python going with argv or *arg? - Stack Overflow

    Aug 17, 2012 · So there is no "choice" between sys.argv and *arg. *arg is syntax used for unpacking a list (or other sequence) to pass as multiple arguments to a call. You can use this syntax when …