Parameter-Mode-Options.html 7.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111
  1. <html lang="en">
  2. <head>
  3. <title>Parameter Mode Options - avram - a virtual machine code interpreter</title>
  4. <meta http-equiv="Content-Type" content="text/html">
  5. <meta name="description" content="avram - a virtual machine code interpreter">
  6. <meta name="generator" content="makeinfo 4.13">
  7. <link title="Top" rel="start" href="index.html#Top">
  8. <link rel="up" href="User-Manual.html#User-Manual" title="User Manual">
  9. <link rel="prev" href="Filter-Mode-Options.html#Filter-Mode-Options" title="Filter Mode Options">
  10. <link rel="next" href="Command-Line-Syntax.html#Command-Line-Syntax" title="Command Line Syntax">
  11. <link href="http://www.gnu.org/software/texinfo/" rel="generator-home" title="Texinfo Homepage">
  12. <meta http-equiv="Content-Style-Type" content="text/css">
  13. <style type="text/css"><!--
  14. pre.display { font-family:inherit }
  15. pre.format { font-family:inherit }
  16. pre.smalldisplay { font-family:inherit; font-size:smaller }
  17. pre.smallformat { font-family:inherit; font-size:smaller }
  18. pre.smallexample { font-size:smaller }
  19. pre.smalllisp { font-size:smaller }
  20. span.sc { font-variant:small-caps }
  21. span.roman { font-family:serif; font-weight:normal; }
  22. span.sansserif { font-family:sans-serif; font-weight:normal; }
  23. --></style>
  24. </head>
  25. <body>
  26. <div class="node">
  27. <a name="Parameter-Mode-Options"></a>
  28. <p>
  29. Next:&nbsp;<a rel="next" accesskey="n" href="Command-Line-Syntax.html#Command-Line-Syntax">Command Line Syntax</a>,
  30. Previous:&nbsp;<a rel="previous" accesskey="p" href="Filter-Mode-Options.html#Filter-Mode-Options">Filter Mode Options</a>,
  31. Up:&nbsp;<a rel="up" accesskey="u" href="User-Manual.html#User-Manual">User Manual</a>
  32. <hr>
  33. </div>
  34. <h3 class="section">1.4 Parameter Mode Options</h3>
  35. <p><a name="index-parameter-mode-30"></a>The parameter mode options are listed below. Except as otherwise
  36. noted, any combination of parameter mode options may be selected
  37. together, and except as noted, the settings of these options can be
  38. varied without breaking the application.
  39. <dl>
  40. <dt><code>-q, --quiet</code><dd><a name="index-g_t_0040code_007bquiet_007d-command-line-option-31"></a><code>avram</code> normally informs the user when writing an output file with
  41. a short message to standard output. This option suppresses such
  42. messages. This option is compatible with any application and any other
  43. parameter mode option except <samp><span class="option">-a</span></samp>.
  44. <br><dt><code>-a, --ask-to-overwrite</code><dd><a name="index-g_t_0040code_007bask_002dto_002doverwrite_007d-command-line-option-32"></a>Selecting this option will cause <code>avram</code> to ask permission
  45. interactively before overwriting an existing file, and to refrain from
  46. overwriting it without permission, in which case the contents that
  47. were to be written will be lost. This option overrides <samp><span class="option">-q</span></samp> and is
  48. compatible with any other parameter mode option or application.
  49. <br><dt><code>-.EXT</code><dd><a name="index-g_t_0040code_007bEXT_007d-command-line-option-33"></a><a name="index-default-file-extensions-34"></a><a name="index-extensions-35"></a><a name="index-file-name-extensions-36"></a><a name="index-file-name-suffixes-37"></a>An option beginning with a dash followed by a period specifies a
  50. default extension for input file names. If <code>avram</code> doesn't find a
  51. file named on the command line, and the filename doesn't already
  52. contain a period, <code>avram</code> will try to find a file having a similar
  53. name but with the default extension appended. The default extension given
  54. by this option takes precedence over the hard coded default extensions
  55. of <kbd>.fun</kbd> and <kbd>.avm</kbd>. At most one default extension can be supplied. This
  56. option is compatible with any other parameter mode option and
  57. compatible with any application.
  58. <br><dt><code>-d, --default-to-stdin</code><dd><a name="index-g_t_0040code_007bdefault_002dto_002dstdin_007d-command-line-option-38"></a><a name="index-standard-input-39"></a>If no filename parameter appears on the command line (other than the
  59. name of the virtual code file), this option directs <code>avram</code> to read
  60. the contents of standard input as if it were specified as a command line
  61. parameter. (Standard input can also be specified explicitly as a
  62. dash. See <a href="Command-Line-Syntax.html#Command-Line-Syntax">Command Line Syntax</a>.) This option is compatible with any
  63. application and any other parameter mode option except <samp><span class="option">-m</span></samp>.
  64. <br><dt><code>-m, --map-to-each-file</code><dd><a name="index-g_t_0040code_007bmap_002dto_002deach_002dfile_007d-command-line-option-40"></a>Normally <code>avram</code> loads the entire contents of all files named on
  65. the command line into memory so as to evaluate the virtual machine
  66. code application on all of them together. This option can be used to
  67. save memory in the case of applications that operate on multiple files
  68. independently. It causes <code>avram</code> to load only one file at a time
  69. and to perform the relevant evaluation and output before loading the
  70. next one. Application specific options and standard input (if
  71. specified) are read only once and reused. This option is incompatible
  72. with <samp><span class="option">-d</span></samp>, and not necessarily compatible with all applications,
  73. although some may work both with and without it.
  74. <br><dt><code>-i, --interactive</code><dd><a name="index-g_t_0040code_007binteractive_007d-command-line-option-41"></a><a name="index-interactive-applications-42"></a>This option is used in the case of applications that interact with
  75. other programs through shell commands. An application that is meant to
  76. be invoked in this way requires this option and will not work without
  77. it, nor will applications that are not of this type work with it. This
  78. option is implied by <samp><span class="option">-t</span></samp> and <samp><span class="option">-s</span></samp>, and is compatible with any
  79. other parameter mode option.
  80. <br><dt><code>-s, --step</code><dd><a name="index-g_t_0040code_007bstep_007d-command-line-option-43"></a>This option is used in the case of applications that interact with
  81. other programs through shell commands, similarly to <samp><span class="option">-i</span></samp>, and
  82. can substitute for it (see above). The option has the additional
  83. effect of causing shell commands issued by <code>avram</code> on behalf of
  84. the application to be written with their results to standard output,
  85. and to cause <code>avram</code> to pause after displaying each shell command
  86. until a key is pressed. This capability may be useful for debugging
  87. or auditing purposes but does not otherwise alter the effects of the
  88. application. This option is compatible with any other parameter mode
  89. option.
  90. <br><dt><code>-t, --trace</code><dd><a name="index-g_t_0040code_007btrace_007d-command-line-option-44"></a>This option is used in the case of applications that interact with
  91. other programs through shell commands, but only by way of the
  92. <code>interact</code> combinator, for which it provides developers a means
  93. of low level debugging, particularly deadlock detection. When this
  94. option is selected, a verbose trace of all characters exchanged
  95. between the functional transducer and the external application are
  96. written to standard output, along with some additional control flow
  97. diagnostics. This option is compatible with any other parameter mode
  98. option.
  99. <br><dt><code>-p, --parameterized</code><dd><a name="index-g_t_0040code_007bparameterized_007d-command-line-option-45"></a>Normally <code>avram</code> tries to guess whether to operate in filter mode
  100. or parameter mode based on the options used and the parameters. If
  101. there are no parameters and no options, it will default to filter
  102. mode, and try to read standard input. However, if this option is
  103. selected, it will use parameter mode (and therefore not try to read
  104. standard input unless required).
  105. </dl>
  106. </body></html>