* perl-mode @ 2005-02-26 15:56 Dietmar Kehr 2005-02-26 17:50 ` perl-mode Peter J. Acklam 0 siblings, 1 reply; 7+ messages in thread From: Dietmar Kehr @ 2005-02-26 15:56 UTC (permalink / raw) I would like to run the file opend in a buffer with perl, where the error messages are shown in a seperate emacs buffer. How is this possible? I didn't find it with C-h f perlmode. Thanks, dk ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: perl-mode 2005-02-26 15:56 perl-mode Dietmar Kehr @ 2005-02-26 17:50 ` Peter J. Acklam 2005-02-27 13:28 ` perl-mode Dietmar Kehr 0 siblings, 1 reply; 7+ messages in thread From: Peter J. Acklam @ 2005-02-26 17:50 UTC (permalink / raw) Dietmar Kehr <dkehr@gnx.de> wrote: > I would like to run the file opend in a buffer with perl, > where the error messages are shown in a seperate > emacs buffer. How is this possible? > I didn't find it with C-h f perlmode. I don't know of a separate function, but you could always use C-x h M-| p e r l RET Then next time you can use M-p in stead of typing "perl". Peter -- Peter J. Acklam - pjacklam@online.no - http://home.online.no/~pjacklam ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: perl-mode 2005-02-26 17:50 ` perl-mode Peter J. Acklam @ 2005-02-27 13:28 ` Dietmar Kehr 2005-02-28 8:26 ` perl-mode Ilya Zakharevich 2005-02-28 19:26 ` perl-mode Kevin Rodgers 0 siblings, 2 replies; 7+ messages in thread From: Dietmar Kehr @ 2005-02-27 13:28 UTC (permalink / raw) On Sat, 26 Feb 2005 18:50:40 +0100, Peter J. Acklam wrote: > but you could always use > > C-x h M-| p e r l RET > > It doesn't work :-( Can someone explain this construction? ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: perl-mode 2005-02-27 13:28 ` perl-mode Dietmar Kehr @ 2005-02-28 8:26 ` Ilya Zakharevich 2005-02-28 19:26 ` perl-mode Kevin Rodgers 1 sibling, 0 replies; 7+ messages in thread From: Ilya Zakharevich @ 2005-02-28 8:26 UTC (permalink / raw) [A complimentary Cc of this posting was sent to Dietmar Kehr <dkehr@gnx.de>], who wrote in article <pan.2005.02.27.13.28.54.290361@gnx.de>: > > but you could always use > > > > C-x h M-| p e r l RET > > > > > > It doesn't work :-( Is there any reason to use perl-mode over CPerl? Puzzled, Ilya ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: perl-mode 2005-02-27 13:28 ` perl-mode Dietmar Kehr 2005-02-28 8:26 ` perl-mode Ilya Zakharevich @ 2005-02-28 19:26 ` Kevin Rodgers 2005-03-01 11:58 ` perl-mode Dietmar Kehr 1 sibling, 1 reply; 7+ messages in thread From: Kevin Rodgers @ 2005-02-28 19:26 UTC (permalink / raw) Dietmar Kehr wrote: > On Sat, 26 Feb 2005 18:50:40 +0100, Peter J. Acklam wrote: > >>but you could always use >> >> C-x h M-| p e r l RET I would suggest: (add-hook 'perl-mode-hook (lambda () (set (make-local-variable 'compile-command) (format "perl %s" (file-name-nondirectory buffer-file-name))))) and then `M-x compile', which gives you a *compilation* buffer whose error messges you can navigate (instead of a *Shell Command Output* buffer). > It doesn't work :-( > Can someone explain this construction? ,----[ C-h k C-x h ] | C-x h runs the command mark-whole-buffer | which is an interactive compiled Lisp function in `simple'. | (mark-whole-buffer) | | Put point at beginning and mark at end of buffer. | You probably should not use this function in Lisp programs; | it is usually a mistake for a Lisp function to use any subroutine | that uses or sets the mark. `---- u ,----[ C-h k M-| ] | M-| runs the command shell-command-on-region | which is an interactive compiled Lisp function in `simple'. | (shell-command-on-region START END COMMAND &optional OUTPUT-BUFFER REPLACE ERROR-BUFFER) | | Execute string COMMAND in inferior shell with region as input. | Normally display output (if any) in temp buffer `*Shell Command Output*'; | Prefix arg means replace the region with it. Return the exit code of | COMMAND. | | To specify a coding system for converting non-ASCII characters | in the input and output to the shell command, use C-x RET c | before this command. By default, the input (from the current buffer) | is encoded in the same coding system that will be used to save the file, | `buffer-file-coding-system'. If the output is going to replace the region, | then it is decoded from that same coding system. | | The noninteractive arguments are START, END, COMMAND, OUTPUT-BUFFER, | REPLACE, ERROR-BUFFER. Noninteractive callers can specify coding | systems by binding `coding-system-for-read' and | `coding-system-for-write'. | | If the output is short enough to display in the echo area (which is | determined by the variable `max-mini-window-height' if | `resize-mini-windows' is non-nil), it is shown there, but it is | nonetheless available in buffer `*Shell Command Output*' even though | that buffer is not automatically displayed. If there is no output, or | if output is inserted in the current buffer, then `*Shell Command | Output*' is deleted. | | If the optional fourth argument OUTPUT-BUFFER is non-nil, | that says to put the output in some other buffer. | If OUTPUT-BUFFER is a buffer or buffer name, put the output there. | If OUTPUT-BUFFER is not a buffer and not nil, | insert output in the current buffer. | In either case, the output is inserted after point (leaving mark after it). | | If REPLACE, the optional fifth argument, is non-nil, that means insert | the output in place of text from START to END, putting point and mark | around it. | | If optional sixth argument ERROR-BUFFER is non-nil, it is a buffer | or buffer name to which to direct the command's standard error output. | If it is nil, error output is mingled with regular output. | In an interactive call, the variable `shell-command-default-error-buffer' | specifies the value of ERROR-BUFFER. `---- -- Kevin Rodgers ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: perl-mode 2005-02-28 19:26 ` perl-mode Kevin Rodgers @ 2005-03-01 11:58 ` Dietmar Kehr 2005-03-01 18:50 ` perl-mode Kevin Rodgers 0 siblings, 1 reply; 7+ messages in thread From: Dietmar Kehr @ 2005-03-01 11:58 UTC (permalink / raw) > > I would suggest: > > (add-hook 'perl-mode-hook > (lambda () > (set (make-local-variable 'compile-command) > (format "perl %s" > (file-name-nondirectory buffer-file-name))))) > ` > and then `M-x compile', which gives you a *compilation* buffer whose > error messges you can navigate (instead of a *Shell Command Output* > buffer). > I can't see any difference in the work of `M-x compile' if I use (add-hook 'perl-mode-hook (lambda () (set (make-local-variable 'compile-command) (format "perl %s" (file-name-nondirectory buffer-file-name))))) (I've wrote it in a file and have loaded it with 'load-file'). In both cases (with and without it) after using `M-x compile' emacs suggests 'make -k' and behaves in the same way. ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: perl-mode 2005-03-01 11:58 ` perl-mode Dietmar Kehr @ 2005-03-01 18:50 ` Kevin Rodgers 0 siblings, 0 replies; 7+ messages in thread From: Kevin Rodgers @ 2005-03-01 18:50 UTC (permalink / raw) Dietmar Kehr wrote: > I can't see any difference in the work of `M-x compile' > if I use > > (add-hook 'perl-mode-hook > (lambda () > (set (make-local-variable 'compile-command) > (format "perl %s" > (file-name-nondirectory buffer-file-name))))) > > (I've wrote it in a file and have loaded it with 'load-file'). > > > In both cases (with and without it) after using > `M-x compile' emacs suggests 'make -k' > and behaves in the same way. You need to invoke perl-mode, either explicitly via M-x or implicitly by visiting a Perl file. -- Kevin Rodgers ^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2005-03-01 18:50 UTC | newest] Thread overview: 7+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2005-02-26 15:56 perl-mode Dietmar Kehr 2005-02-26 17:50 ` perl-mode Peter J. Acklam 2005-02-27 13:28 ` perl-mode Dietmar Kehr 2005-02-28 8:26 ` perl-mode Ilya Zakharevich 2005-02-28 19:26 ` perl-mode Kevin Rodgers 2005-03-01 11:58 ` perl-mode Dietmar Kehr 2005-03-01 18:50 ` perl-mode Kevin Rodgers
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).