[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: how can I tell emacs to treat a text file as html?
From: |
Angelina Carlton |
Subject: |
Re: how can I tell emacs to treat a text file as html? |
Date: |
Sat, 9 Apr 2005 14:46:37 -0400 |
User-agent: |
Mutt/1.3.28i |
On Sat, Apr 09, 2005 at 08:11:49PM +0200, Pascal Bourguignon wrote:
> emacsclient -e "(progn (find-file \"$file\") (html-mode))"
This throws an error:
emacsclient: invalid option -- e
> Also, it might be possible to append:
>
> <!--
> Local Variables:
> mode: html
> End:
>
> or to prepend: <!-- -*- mode: html -*- -->
>
> if not already present in the file, and then use merely: emacsclient $file
>
> For example:
>
>
> tail -10 $file \
> | grep -q -s 'mode: html' \
> || cat >> $file <<EOF
> <!--
> Local Variables:
> mode: html
> End:
> EOF
> emacsclient $file
>
>
I think from the man page:
-f function Execute the lisp function function.
-l file Load the lisp code in the file file.
So it looks like I can load some code from a file which is probably the simplest
thing to do for my needs.
--
Angelina Carlton
- how can I tell emacs to treat a text file as html?, Angelina Carlton, 2005/04/09
- Re: how can I tell emacs to treat a text file as html?, Albert Reiner, 2005/04/09
- Re: how can I tell emacs to treat a text file as html?, Pascal Bourguignon, 2005/04/09
- Re: how can I tell emacs to treat a text file as html?,
Angelina Carlton <=
- Re: how can I tell emacs to treat a text file as html?, Stefan Monnier, 2005/04/09
- Re: how can I tell emacs to treat a text file as html?, Angelina Carlton, 2005/04/09
- Re: how can I tell emacs to treat a text file as html?, Angelina Carlton, 2005/04/09
- Message not available
- Re: how can I tell emacs to treat a text file as html?, Pascal Bourguignon, 2005/04/09
- Re: how can I tell emacs to treat a text file as html?, Joe Corneli, 2005/04/10
- Message not available
- byte-compiling .emacs (was: how can I tell emacs to treat a text file as html?), Reiner Steib, 2005/04/11
- Re: byte-compiling .emacs (was: how can I tell emacs to treat a text file as html?), Joe Corneli, 2005/04/11
- Re: byte-compiling .emacs (was: how can I tell emacs to treat a text file as html?), Peter Dyballa, 2005/04/11
- Message not available
- Re: byte-compiling .emacs, David Kastrup, 2005/04/11
- Re: byte-compiling .emacs, Peter Dyballa, 2005/04/11