;;; Commentary: ;; `croc' is a front end to croc(1) . ;; ;; * Receiving a File with M-x croc ;; ;; You can receive a file from croc(1) directly to a buffer inside ;; Emacs (there will be no file on disk) with `croc'; you'll be ;; prompted for the code. You can override the default relay with a ;; prefix argument; see also the user option `croc-relay'. ;; ;; If Emacs can guess a better mode than `fundamental-mode' for the ;; received file, you'll be prompted to approve the choice. If ;; croc(1) provided a filename for the incoming data, the buffer file ;; name will be initialized to it; otherwise, the buffer name will be ;; `*croc*' (with a possible generation number appended). You ;; can save the file to disk if you want to. In either ;; case, the `default-directory' for the new buffer will be the one ;; from the buffer from which you ran `croc'. ;; ;; * Sending Data in General ;; ;; Data will be sent asynchronously (you can have any number of ;; transfers going at the same time); killing the `*croc*' process ;; buffer (which will happen if you forcibly exit Emacs) will ;; terminate the croc process and hence your file transfer. The relay ;; used will be as per `croc-relay'. ;; ;; When croc is ready, a `*croc*' buffer will pop up; this buffer ;; contains the croc(1) output and so includes the code you'll pass on ;; to your recipient. You can bury this buffer; there's no need to ;; stare at it until the file is sent. This buffer will also pop up ;; whenever the process status changes and a message about the change ;; will be appended, so you'll know when the file transfer is finished ;; or if the process dies for some reason. ;; ;; The buffer is in `croc-send-mode' and in addition to the usual ;; `special-mode' scrolling commands, has the following handy key ;; bindings: ;; ;; c :: `croc-copy-command' :: copy the recipient's croc command to the kill ring ;; d :: `croc-delete' :: delete (kill) the croc data-sending process ;; l :: `list-processes' :: list and manipulate all Emacs sub-processes ;; q :: `croc-quit' :: cleanup the croc buffer after the data is sent ;; s :: `croc-status' :: display the status of the croc process ;; z :: `croc-bury' :: delete any windows on this croc buffer ;; ;; * Sending a File with M-x croc-send-file ;; ;; You can send a file from Emacs with `croc-send-file'. You'll be ;; prompted for the file name. ;; ;; * Sending a Buffer with M-x croc-send-text ;; ;; Prompts for a string and sends it using `croc send --text'. ;; ;; * Sending a Region with M-x croc-send-region ;; ;; This sends the region using `croc send --text'. ;; ;; * Sending a Buffer with M-x croc-send-buffer ;; ;; Prompts for a buffer and sends it using `croc send --text'. Note ;; that trying to send a huge buffer this way may have argv-size problems.