unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: saint@eng.it
To: Michael Heerdegen <michael_heerdegen@web.de>
Cc: help-gnu-emacs@gnu.org
Subject: Re: --script and --quick
Date: Wed, 27 May 2015 14:02:17 +0200	[thread overview]
Message-ID: <21861.45641.561501.901128@mail.eng.it> (raw)
In-Reply-To: <87lhgas0fb.fsf@web.de>

Michael Heerdegen writes:
 > "Gian Uberto Lauri" <saint@eng.it> writes:
 > 
 > > ---------------------------------8<----------------------
 > > #!/bin/bash
 > >
 > > emacs --quick --script $@
 > > ---------------------------------8<----------------------
 > 
 > And put the code into a different file?

*This* is the interpreter (a wrapper for Emacs). Use it for all your
 scripts.

-------------------------8<--------------------------
#!/home/saint/bin/esh
(find-file "paperoga")
(insert (concat "hello" "world"))
(save-buffer)
-------------------------8<--------------------------

This is a script .

BTW, I often use emacsclient --eval to invoke functions in a running
and is faster, but could block the foreground Emacs for a while.

My favourite strategy is a little shell script that targets the files
and processes them within Emacs.

-- 
 /\           ___                                    Ubuntu: ancient
/___/\_|_|\_|__|___Gian Uberto Lauri_____               African word
  //--\| | \|  |   Integralista GNUslamico            meaning "I can
\/                 coltivatore diretto di software       not install
     già sistemista a tempo (altrui) perso...                Debian"

Warning: gnome-config-daemon considered more dangerous than GOTO



  reply	other threads:[~2015-05-27 12:02 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-26 14:44 --script and --quick Michael Heerdegen
2015-05-26 16:49 ` Óscar Fuentes
2015-05-26 17:05   ` Michael Heerdegen
2015-05-26 20:53     ` Bob Proulx
2015-05-27  3:48       ` Yuri Khan
2015-05-27  6:55         ` Gian Uberto Lauri
2015-05-27 11:51           ` Michael Heerdegen
2015-05-27 12:02             ` saint [this message]
2015-05-27 12:34               ` Michael Heerdegen
2015-05-27 12:39                 ` Gian Uberto Lauri
2015-05-27 12:52                   ` Michael Heerdegen
2015-05-28 14:27                     ` Michael Heerdegen
     [not found]         ` <mailman.3742.1432709757.904.help-gnu-emacs@gnu.org>
2015-05-27  7:18           ` Chris F.A. Johnson
2015-05-27 12:39             ` Gian Uberto Lauri
2015-05-28 12:35       ` Michael Heerdegen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=21861.45641.561501.901128@mail.eng.it \
    --to=saint@eng.it \
    --cc=help-gnu-emacs@gnu.org \
    --cc=michael_heerdegen@web.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).