unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* command-line emacs tops out at 16384?
@ 2003-06-30  3:13 Sanford Selznick
  2003-06-30 16:55 ` Kevin Rodgers
  0 siblings, 1 reply; 3+ messages in thread
From: Sanford Selznick @ 2003-06-30  3:13 UTC (permalink / raw)


I've created a file "/tmp/test" that contains 20000 characters.  If I 
execute the following command on it from a console only the first 16384 
characters are input.

Why is this?

This is supposed to execute c-style wrapping on /tmp/test, and works 
great for file lengths < 16384.

emacs -batch -eval '(find-file "/tmp/test")' -eval '(c-mode)' -eval 
'(indent-region (point-min) (point-max) nil)' -eval '(save-buffer)' 
-eval '(kill-buffer (current-buffer))'

Thank you,
  Sanford

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: command-line emacs tops out at 16384?
  2003-06-30  3:13 command-line emacs tops out at 16384? Sanford Selznick
@ 2003-06-30 16:55 ` Kevin Rodgers
  2003-07-01  6:43   ` Harry Putnam
  0 siblings, 1 reply; 3+ messages in thread
From: Kevin Rodgers @ 2003-06-30 16:55 UTC (permalink / raw)


Sanford Selznick wrote:

> emacs -batch -eval '(find-file "/tmp/test")' -eval '(c-mode)' -eval 
> '(indent-region (point-min) (point-max) nil)' -eval '(save-buffer)' 
> -eval '(kill-buffer (current-buffer))'


I can't answer your question, but just want to point out that can be

simplified:

emacs --batch \
       "/tmp/test" \
       -f c-mode \
       --eval '(indent-region (point-min) (point-max) nil)' \
       -f save-buffer

-- 
<a href="mailto:&lt;kevin.rodgers&#64;ihs.com&gt;">Kevin Rodgers</a>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: command-line emacs tops out at 16384?
  2003-06-30 16:55 ` Kevin Rodgers
@ 2003-07-01  6:43   ` Harry Putnam
  0 siblings, 0 replies; 3+ messages in thread
From: Harry Putnam @ 2003-07-01  6:43 UTC (permalink / raw)


[-- Attachment #1: Type: text/plain, Size: 915 bytes --]

Kevin Rodgers <ihs_4664@yahoo.com> writes:

> I can't answer your question, but just want to point out that can be
>
> simplified:
>
> emacs --batch \
>        "/tmp/test" \
>        -f c-mode \
>        --eval '(indent-region (point-min) (point-max) nil)' \
>        -f save-buffer

Kevin,  I haven't been following here but this caught my attention as
  a potentially usefull piece of command line syntax.  Not sure what
  the application here was supposed to be.   Can it be aimed at an
  existing file that is unformatted and the end result will be that
  it is formatted and saved?

  If so, how might that be made to handle a lisp file?

I tried: 
emacs -q -no-site-file -batch  \
 "/tmp/my_gnus.el" -f lisp-mode  \
 -eval '(indent-region (point-min) (point-max) nil)' \
  -f save-buffer

>>> OUTPUT
(No changes need to be saved)

And the file is unchanged.  See attached file for the code I ran it
against.


[-- Attachment #2: lisp file --]
[-- Type: text/plain, Size: 2471 bytes --]

(add-to-list 'load-path  "/usr/local/gnus/lisp")
(setq gnus-init-file "/tmp/my_gnus_init.el") 
(load-library "gnus")
(message gnus-version)
(setq mail-user-agent  'gnus-user-agent) ;;;batch:76:/home/reader/.gnus
(setq  max-lisp-eval-depth 2000) ;;;batch:80:/home/reader/.gnus
(setq  message-syntax-checks ;;;batch:81:/home/reader/.gnus
'((sender . disabled))) ;;;batch:82:/home/reader/.gnus
(defun message-make-fqdn () ;;;batch:84:/home/reader/.gnus
"My  hacked message-id." ;;;batch:85:/home/reader/.gnus
"newsguy.com") ;;;batch:86:/home/reader/.gnus
(setq gnus-expert-user t) ;;;batch:95:/home/reader/.gnus
(setq gnus-agent-short-article 50) ;;;batch:96:/home/reader/.gnus
(setq gnus-use-adaptive-scoring nil) ;;;batch:152:/home/reader/.gnus
(setq mail-sources ;;;batch:159:/home/reader/.gnus
'((file :path "/var/spool/mail/reader") ;;;batch:160:/home/reader/.gnus
(directory :path "/home/reader/spool/"    :suffix ".in"))) ;;;batch:161:/home/reader/.gnus
(setq gnus-extra-headers ;;;batch:164:/home/reader/.gnus
'(To Newsgroups Keywords )) ;;;batch:165:/home/reader/.gnus
(setq nnmail-extra-headers gnus-extra-headers) ;;;batch:166:/home/reader/.gnus
(setq gnus-ignored-from-addresses ;;;batch:167:/home/reader/.gnus
"Harry Putnam") ;;;batch:168:/home/reader/.gnus
(setq message-user-organization "Still searching...") ;;;batch:171:/home/reader/.gnus
(setq gnus-select-method '(nntp "enews.newsguy.com")) ;;;batch:172:/home/reader/.gnus
(setq user-mail-address "reader@newsguy.com") ;;;batch:175:/home/reader/.gnus
(setq gnus-check-new-newsgroups 'ask-server) ;;;batch:183:/home/reader/.gnus
(setq gnus-agent-handle-level 3) ;;;batch:186:/home/reader/.gnus
(setq gnus-activate-foreign-newsgroups 3) ;;;batch:187:/home/reader/.gnus
(setq mail-source-delete-incoming t) ;;;batch:188:/home/reader/.gnus
(setq gnus-use-long-file-name  t) ;;;batch:189:/home/reader/.gnus
(setq nnmail-crosspost nil) ;;;batch:190:/home/reader/.gnus
(setq gnus-secondary-select-methods ;;;batch:194:/home/reader/.gnus
'((nnml ""))) ;;;batch:195:/home/reader/.gnus
(setq nnmail-split-methods ;;;batch:197:/home/reader/.gnus
'(("tests" "^Subject:.*test.*labridge") ;;;batch:198:/home/reader/.gnus
("Edited"  "^Subject: \\[ed\\]\\|^Subject:  \\[ed\\]") ;;;batch:199:/home/reader/.gnus
("misc" ""))) ;;;batch:200:/home/reader/.gnus
(setq user-mail-address "reader@newsguy.com") ;;;batch:120:/home/reader/.emacs
(setq message-syntax-checks '((sender . disabled))) ;;;batch:121:/home/reader/.emacs

[-- Attachment #3: Type: text/plain, Size: 151 bytes --]

_______________________________________________
Help-gnu-emacs mailing list
Help-gnu-emacs@gnu.org
http://mail.gnu.org/mailman/listinfo/help-gnu-emacs

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2003-07-01  6:43 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-06-30  3:13 command-line emacs tops out at 16384? Sanford Selznick
2003-06-30 16:55 ` Kevin Rodgers
2003-07-01  6:43   ` Harry Putnam

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).