* newbie needs to be bailed out
@ 2012-01-04 19:22 Kim Young
2012-01-04 19:45 ` Peter Dyballa
` (2 more replies)
0 siblings, 3 replies; 10+ messages in thread
From: Kim Young @ 2012-01-04 19:22 UTC (permalink / raw)
To: help-gnu-emacs
Hello,
I am running Mac os x lion and I want to use emacs to try to write some shell scripts for work. I am new to emacs so I would like help with some very basic things.
1. What is the command to determine the version of emacs that is provided with lion?
2. How do I enable color highlighting for syntext?
3 How do I get a list of the command sequences that auto generate things like "for", "while" and "do" loops for the various languages (C++, ruby, etc) I might use?
Thanks for any help you can give me.
John "Kim" Young
1663 71st Street
Brooklyn, NY 11204
(917) 620-5562
kimyoung@mac.com
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: newbie needs to be bailed out
2012-01-04 19:22 newbie needs to be bailed out Kim Young
@ 2012-01-04 19:45 ` Peter Dyballa
2012-01-04 22:40 ` Philipp Haselwarter
2012-01-04 23:54 ` Jai Dayal
2012-01-05 3:18 ` Eric Abrahamsen
2 siblings, 1 reply; 10+ messages in thread
From: Peter Dyballa @ 2012-01-04 19:45 UTC (permalink / raw)
To: Kim Young; +Cc: help-gnu-emacs
Am 04.01.2012 um 20:22 schrieb Kim Young:
> 1. What is the command to determine the version of emacs that is provided with lion?
emacs --version
>
> 2. How do I enable color highlighting for syntext?
Use a colour terminal!
--
Greetings
Pete
Government is actually the worst failure of civilized man. There has never been a really good one, and even those that are most tolerable are arbitrary, cruel, grasping and unintelligent.
– H. L. Mencken
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: newbie needs to be bailed out
2012-01-04 19:45 ` Peter Dyballa
@ 2012-01-04 22:40 ` Philipp Haselwarter
2012-01-04 23:57 ` Peter Dyballa
0 siblings, 1 reply; 10+ messages in thread
From: Philipp Haselwarter @ 2012-01-04 22:40 UTC (permalink / raw)
To: Peter Dyballa; +Cc: help-gnu-emacs, Kim Young
Peter Dyballa <Peter_Dyballa@Web.DE> writes:
> Am 04.01.2012 um 20:22 schrieb Kim Young:
>
>> 1. What is the command to determine the version of emacs that is provided with lion?
>
> emacs --version
>
>>
>> 2. How do I enable color highlighting for syntext?
>
> Use a colour terminal!
>
---8<---[snipped 10 lines]---8<---
Or emacs in graphical mode; also make sure to turn on
`global-font-lock-mode'.
> 3 How do I get a list of the command sequences that auto generate things like
> "for", "while" and "do" loops for the various languages (C++, ruby, etc) I might
> use?
With emacs come `abbrev.el' and `skeleton.el', I like `yasnippet' very
much. Make sure to take a look at the emacswiki:
http://www.emacswiki.org/emacs/CategoryTemplates
--
Philipp Haselwarter
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: newbie needs to be bailed out
2012-01-04 19:22 newbie needs to be bailed out Kim Young
2012-01-04 19:45 ` Peter Dyballa
@ 2012-01-04 23:54 ` Jai Dayal
2012-01-05 0:14 ` Marko Vojinovic
2012-01-05 3:18 ` Eric Abrahamsen
2 siblings, 1 reply; 10+ messages in thread
From: Jai Dayal @ 2012-01-04 23:54 UTC (permalink / raw)
To: Kim Young; +Cc: help-gnu-emacs
[-- Attachment #1: Type: text/plain, Size: 916 bytes --]
1) in terminal type, emacs --version
2) in emacs, type "M-x" and then type global-font-lock-mode M stands for
"meta" and is generally the ALT key.
3) what the other guy said
On Wed, Jan 4, 2012 at 2:22 PM, Kim Young <kimyoung@me.com> wrote:
> Hello,
>
> I am running Mac os x lion and I want to use emacs to try to write some
> shell scripts for work. I am new to emacs so I would like help with some
> very basic things.
>
> 1. What is the command to determine the version of emacs that is
> provided with lion?
>
> 2. How do I enable color highlighting for syntext?
>
> 3 How do I get a list of the command sequences that auto generate
> things like "for", "while" and "do" loops for the various languages (C++,
> ruby, etc) I might use?
>
> Thanks for any help you can give me.
>
>
> John "Kim" Young
> 1663 71st Street
> Brooklyn, NY 11204
> (917) 620-5562
> kimyoung@mac.com
>
>
>
>
>
[-- Attachment #2: Type: text/html, Size: 1386 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: newbie needs to be bailed out
2012-01-04 22:40 ` Philipp Haselwarter
@ 2012-01-04 23:57 ` Peter Dyballa
0 siblings, 0 replies; 10+ messages in thread
From: Peter Dyballa @ 2012-01-04 23:57 UTC (permalink / raw)
To: Philipp Haselwarter; +Cc: help-gnu-emacs, Kim Young
Am 04.01.2012 um 23:40 schrieb Philipp Haselwarter:
>>> 2. How do I enable color highlighting for syntext?
>>
>> Use a colour terminal!
>>
> ---8<---[snipped 10 lines]---8<---
>
> Or emacs in graphical mode; also make sure to turn on
> `global-font-lock-mode'.
Such Emacsen do not come with Mac OS X. (Presumingly the best integrated one is the "AppKit Emacs" based on GNU Emacs 23.3 – it has to be compiled by one-self. Once you install X11 you could also use the X11 variant of either GNU Emacs 23.3 or the coming GNU Emacs 24.1.)
--
Greetings
Pete
Government is actually the worst failure of civilized man. There has never been a really good one, and even those that are most tolerable are arbitrary, cruel, grasping and unintelligent.
– H. L. Mencken
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: newbie needs to be bailed out
2012-01-04 23:54 ` Jai Dayal
@ 2012-01-05 0:14 ` Marko Vojinovic
2012-01-05 0:16 ` Jai Dayal
` (2 more replies)
0 siblings, 3 replies; 10+ messages in thread
From: Marko Vojinovic @ 2012-01-05 0:14 UTC (permalink / raw)
To: help-gnu-emacs
On Wednesday 04 January 2012 18:54:31 Jai Dayal wrote:
> On Wed, Jan 4, 2012 at 2:22 PM, Kim Young <kimyoung@me.com> wrote:
> > I am running Mac os x lion and I want to use emacs to try to write some
> > shell scripts for work. I am new to emacs so I would like help with some
> > very basic things.
> >
> > 1. What is the command to determine the version of emacs that is
> > provided with lion?
>
> 1) in terminal type, emacs --version
This maybe doesn't apply to the OP, but I've seen MacOSX users who don't even
know what a "terminal" is, let alone how to open one (being a Linux user
myself, I also had some trouble finding a way to open a terminal when I first
sat in front of a Mac machine on one occasion).
So, is there a way to find out the emacs version from within a running emacs
instance itself?
Best, :-)
Marko
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: newbie needs to be bailed out
2012-01-05 0:14 ` Marko Vojinovic
@ 2012-01-05 0:16 ` Jai Dayal
2012-01-05 0:20 ` Drew Adams
2012-01-05 12:32 ` Peter Dyballa
2 siblings, 0 replies; 10+ messages in thread
From: Jai Dayal @ 2012-01-05 0:16 UTC (permalink / raw)
To: Marko Vojinovic; +Cc: help-gnu-emacs
[-- Attachment #1: Type: text/plain, Size: 1102 bytes --]
Hmm, good question. All though, the OP did state he was using it to write
shell scripts, others might not know.
I honestly don't know.
On Wed, Jan 4, 2012 at 7:14 PM, Marko Vojinovic <vvmarko@gmail.com> wrote:
> On Wednesday 04 January 2012 18:54:31 Jai Dayal wrote:
> > On Wed, Jan 4, 2012 at 2:22 PM, Kim Young <kimyoung@me.com> wrote:
> > > I am running Mac os x lion and I want to use emacs to try to write some
> > > shell scripts for work. I am new to emacs so I would like help with
> some
> > > very basic things.
> > >
> > > 1. What is the command to determine the version of emacs that is
> > > provided with lion?
> >
> > 1) in terminal type, emacs --version
>
> This maybe doesn't apply to the OP, but I've seen MacOSX users who don't
> even
> know what a "terminal" is, let alone how to open one (being a Linux user
> myself, I also had some trouble finding a way to open a terminal when I
> first
> sat in front of a Mac machine on one occasion).
>
> So, is there a way to find out the emacs version from within a running
> emacs
> instance itself?
>
> Best, :-)
> Marko
>
>
>
>
[-- Attachment #2: Type: text/html, Size: 1647 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* RE: newbie needs to be bailed out
2012-01-05 0:14 ` Marko Vojinovic
2012-01-05 0:16 ` Jai Dayal
@ 2012-01-05 0:20 ` Drew Adams
2012-01-05 12:32 ` Peter Dyballa
2 siblings, 0 replies; 10+ messages in thread
From: Drew Adams @ 2012-01-05 0:20 UTC (permalink / raw)
To: 'Marko Vojinovic', help-gnu-emacs
> is there a way to find out the emacs version from within
> a running emacs instance itself?
M-x emacs-version
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: newbie needs to be bailed out
2012-01-04 19:22 newbie needs to be bailed out Kim Young
2012-01-04 19:45 ` Peter Dyballa
2012-01-04 23:54 ` Jai Dayal
@ 2012-01-05 3:18 ` Eric Abrahamsen
2 siblings, 0 replies; 10+ messages in thread
From: Eric Abrahamsen @ 2012-01-05 3:18 UTC (permalink / raw)
To: help-gnu-emacs
On Thu, Jan 05 2012, Kim Young wrote:
> Hello,
>
> I am running Mac os x lion and I want to use emacs to try to write
> some shell scripts for work. I am new to emacs so I would like help
> with some very basic things.
>
> 1. What is the command to determine the version of emacs that is provided with lion?
>
> 2. How do I enable color highlighting for syntext?
>
> 3 How do I get a list of the command sequences that auto generate
> things like "for", "while" and "do" loops for the various languages
> (C++, ruby, etc) I might use?
>
> Thanks for any help you can give me.
In addition to what everyone else has said…
Assuming you are already *in* emacs and using it to write bash scripts,
you want to find the "major mode" that corresponds with your file. When
I open, for instance, ~/.bashrc, it goes into shell-script mode, and on
the mode line I see (Shell-script[bash]). So emacs knows I'm editing a
shell script, and knows it's a bash script. This major mode (see (info
"(emacs)Modes")) provides both the syntax highlighting you're looking
for, and also helpful commands for language constructs. All the
major languages (C++, ruby, etc) have their own major modes, that
provide the correct highlighting and give you helper functions.
Hope that's what you were asking!
Read the manual!
Eric
>
> John "Kim" Young
> 1663 71st Street
> Brooklyn, NY 11204
> (917) 620-5562
> kimyoung@mac.com
>
>
>
>
>
--
GNU Emacs 24.0.92.2 (i686-pc-linux-gnu, GTK+ Version 2.24.8)
of 2012-01-04 on pellet
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: newbie needs to be bailed out
2012-01-05 0:14 ` Marko Vojinovic
2012-01-05 0:16 ` Jai Dayal
2012-01-05 0:20 ` Drew Adams
@ 2012-01-05 12:32 ` Peter Dyballa
2 siblings, 0 replies; 10+ messages in thread
From: Peter Dyballa @ 2012-01-05 12:32 UTC (permalink / raw)
To: Marko Vojinovic; +Cc: help-gnu-emacs
Am 5.1.2012 um 01:14 schrieb Marko Vojinovic:
> This maybe doesn't apply to the OP, but I've seen MacOSX users who don't even
> know what a "terminal" is, let alone how to open one (being a Linux user
> myself, I also had some trouble finding a way to open a terminal when I first
> sat in front of a Mac machine on one occasion).
Apple adds some documentation to the released DVDs which explain such basic things. It's mostly English, though... and has to be read by oneself, it does not speak.
>
> So, is there a way to find out the emacs version from within a running emacs
> instance itself?
How can you determine that when you can't launch a terminal in which GNU Emacs runs?
--
Greetings
Pete
If we don't succeed, we run the risk of failure.
– George W. Bush
^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2012-01-05 12:32 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-01-04 19:22 newbie needs to be bailed out Kim Young
2012-01-04 19:45 ` Peter Dyballa
2012-01-04 22:40 ` Philipp Haselwarter
2012-01-04 23:57 ` Peter Dyballa
2012-01-04 23:54 ` Jai Dayal
2012-01-05 0:14 ` Marko Vojinovic
2012-01-05 0:16 ` Jai Dayal
2012-01-05 0:20 ` Drew Adams
2012-01-05 12:32 ` Peter Dyballa
2012-01-05 3:18 ` Eric Abrahamsen
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).