| 1 | ;;; reformatter-autoloads.el --- automatically extracted autoloads (do not edit) -*- lexical-binding: t -*- |
| 2 | ;; Generated by the `loaddefs-generate' function. |
| 3 | |
| 4 | ;; This file is part of GNU Emacs. |
| 5 | |
| 6 | ;;; Code: |
| 7 | |
| 8 | (add-to-list 'load-path (or (and load-file-name (directory-file-name (file-name-directory load-file-name))) (car load-path))) |
| 9 | |
| 10 | |
| 11 | |
| 12 | ;;; Generated autoloads from reformatter.el |
| 13 | |
| 14 | (autoload 'reformatter-define "reformatter" |
| 15 | "Define a reformatter command with NAME. |
| 16 | |
| 17 | When called, the reformatter will use PROGRAM and any ARGS to |
| 18 | reformat the current buffer. The contents of the buffer will be |
| 19 | passed as standard input to the reformatter, which should output |
| 20 | them to standard output. A nonzero exit code will be reported as |
| 21 | failure, and the output of the command to standard error will be |
| 22 | displayed to the user. |
| 23 | |
| 24 | The macro accepts the following keyword arguments: |
| 25 | |
| 26 | PROGRAM (required) |
| 27 | |
| 28 | Provides a form which should evaluate to a string at runtime, |
| 29 | e.g. a literal string, or the name of a variable which holds |
| 30 | the program path. |
| 31 | |
| 32 | ARGS |
| 33 | |
| 34 | Command-line arguments for the program. If provided, this is a |
| 35 | form which evaluates to a list of strings at runtime. Default |
| 36 | is the empty list. This form is evaluated at runtime so that |
| 37 | you can use buffer-local variables to influence the args passed |
| 38 | to the reformatter program: the variable `input-file' will be |
| 39 | lexically bound to the path of a file containing the text to be |
| 40 | reformatted: see the keyword options INPUT-FILE, STDIN and |
| 41 | STDOUT for more information. |
| 42 | |
| 43 | STDIN |
| 44 | |
| 45 | When non-nil (the default), the program is passed the input |
| 46 | data on stdin. Set this to nil when your reformatter can only |
| 47 | operate on files in place. In such a case, your ARGS should |
| 48 | include a reference to the `input-file' variable, which will be |
| 49 | bound to an input path when evaluated. |
| 50 | |
| 51 | STDOUT |
| 52 | |
| 53 | When non-nil (the default), the program is expected to write |
| 54 | the reformatted text to stdout. Set this to nil if your |
| 55 | reformatter can only operate on files in place, in which case |
| 56 | the contents of the temporary input file will be used as the |
| 57 | replacement text. |
| 58 | |
| 59 | INPUT-FILE |
| 60 | |
| 61 | Sometimes your reformatter program might expect files to be in |
| 62 | a certain directory or have a certain file extension. This option |
| 63 | lets you handle that. |
| 64 | |
| 65 | If provided, it is a form which will be evaluated before each |
| 66 | run of the formatter, and is expected to return a temporary |
| 67 | file path suitable for holding the region to be reformatted. |
| 68 | It must not produce the same path as the current buffer's file |
| 69 | if that is set: you shouldn't be operating directly on the |
| 70 | buffer's backing file. The temporary input file will be |
| 71 | deleted automatically. You might find the functions |
| 72 | `reformatter-temp-file-in-current-directory' and |
| 73 | `reformatter-temp-file' helpful. |
| 74 | |
| 75 | MODE |
| 76 | |
| 77 | Unless nil, also generate a minor mode that will call the |
| 78 | reformatter command from `before-save-hook' when enabled. |
| 79 | Default is t. |
| 80 | |
| 81 | GROUP |
| 82 | |
| 83 | If provided, this is the custom group used for any generated |
| 84 | modes or custom variables. Don't forget to declare this group |
| 85 | using a `defgroup' form. |
| 86 | |
| 87 | LIGHTER |
| 88 | |
| 89 | If provided, this is a mode lighter string which will be used |
| 90 | for the \"-on-save\" minor mode. It should have a leading |
| 91 | space. The supplied value will be used as the default for a |
| 92 | generated custom variable which specifies the mode lighter. |
| 93 | Default is nil, ie. no lighter. |
| 94 | |
| 95 | KEYMAP |
| 96 | |
| 97 | If provided, this is the symbol name of the \"-on-save\" mode's |
| 98 | keymap, which you must declare yourself. Default is no keymap. |
| 99 | |
| 100 | EXIT-CODE-SUCCESS-P |
| 101 | |
| 102 | If provided, this is a function object callable with `funcall' |
| 103 | which accepts an integer process exit code, and returns non-nil |
| 104 | if that exit code is considered successful. This could be a |
| 105 | lambda, quoted symbol or sharp-quoted symbol. If not supplied, |
| 106 | the code is considered successful if it is `zerop'. |
| 107 | |
| 108 | (fn NAME &key PROGRAM ARGS (MODE t) (STDIN t) (STDOUT t) INPUT-FILE LIGHTER KEYMAP GROUP (EXIT-CODE-SUCCESS-P \\='zerop))" nil t) |
| 109 | (register-definition-prefixes "reformatter" '("reformatter-")) |
| 110 | |
| 111 | ;;; End of scraped data |
| 112 | |
| 113 | (provide 'reformatter-autoloads) |
| 114 | |
| 115 | ;; Local Variables: |
| 116 | ;; version-control: never |
| 117 | ;; no-byte-compile: t |
| 118 | ;; no-update-autoloads: t |
| 119 | ;; no-native-compile: t |
| 120 | ;; coding: utf-8-emacs-unix |
| 121 | ;; End: |
| 122 | |
| 123 | ;;; reformatter-autoloads.el ends here |