Learn, use, and debug AWK in Emacs.

35 views
Skip to first unread message

Hongyi Zhao

unread,
Aug 6, 2023, 9:28:58 AMAug 6
to
Hi here,

Are there some feasible ways to learn, use, and debug AWK in Emacs?

Regards,
Zhao

Janis Papanagnou

unread,
Aug 6, 2023, 9:46:13 AMAug 6
to
On 06.08.2023 15:28, Hongyi Zhao wrote:
> Hi here,
>
> Are there some feasible ways to learn, use, and debug AWK in Emacs?

The learn and use part can be done by studying a book; I recommend
then one mentioned previously in this newsgroup:
The AWK Programming Language
by Alfred V. Aho, Brian W. Kernighan, Peter J. Weinberger
A new edition is appearing soon, as we've been told.

If you're using GNU Awk I suggest (in addition) Arnold Robbins book:
Effective Awk Programming
Here you also get information about the GNU Awk's specific features.

GNU Awk has also debugging features; inspect Arnold's book or the
also online available GNU Awk documentation for details.

If you want to embed Awk in Emacs I cannot help you - myself using it
in a Unix system context from a shell command line -, but I'm sure
that the Emacs documentation will have some hints how to embed such
tools in Emacs.

Janis

>
> Regards,
> Zhao
>

Hongyi Zhao

unread,
Aug 6, 2023, 9:52:52 AMAug 6
to
On Sunday, August 6, 2023 at 9:46:13 PM UTC+8, Janis Papanagnou wrote:
> On 06.08.2023 15:28, Hongyi Zhao wrote:
> > Hi here,
> >
> > Are there some feasible ways to learn, use, and debug AWK in Emacs?
> The learn and use part can be done by studying a book; I recommend
> then one mentioned previously in this newsgroup:
> The AWK Programming Language
> by Alfred V. Aho, Brian W. Kernighan, Peter J. Weinberger
> A new edition is appearing soon, as we've been told.
>
> If you're using GNU Awk I suggest (in addition) Arnold Robbins book:
> Effective Awk Programming
> Here you also get information about the GNU Awk's specific features.
>
> GNU Awk has also debugging features; inspect Arnold's book or the
> also online available GNU Awk documentation for details.
>
> If you want to embed Awk in Emacs I cannot help you - myself using it
> in a Unix system context from a shell command line -, but I'm sure

Is the following usage of standard English grammar, as you have written above?

-,

> that the Emacs documentation will have some hints how to embed such
> tools in Emacs.
>
> Janis

Zhao

> >
> > Regards,
> > Zhao
> >

Janis Papanagnou

unread,
Aug 6, 2023, 10:18:48 AMAug 6
to
On 06.08.2023 15:52, Hongyi Zhao wrote:
> On Sunday, August 6, 2023 at 9:46:13 PM UTC+8, Janis Papanagnou wrote:
>>
>> If you want to embed Awk in Emacs I cannot help you - myself using it
>> in a Unix system context from a shell command line -, but I'm sure
>
> Is the following usage of standard English grammar, as you have written above?
>
> -,

Better ask in a newsgroup were languages, grammar, and semantics are
discussed. Myself not a native speaker I've used principles from my
own language and some basic knowledge. What I can say (or speculate
about, if you like) is...
Relative clauses: A, B, C.
Clauses in dash: A - B - C. (Often written with long - or double -- .)
A composition of a relative clause with a dashed clause: A - B -, C.
where the first part of the relative clause contains a dashed clause.
Instead you can also use a parenthetical clause: A (B). or A (B) C.
or as a composition with a relative clause: A (B), C.
What you use depends on the intention, on what you want to express.
(Some native speaker may provide corrections or better explanations.)

I hope the clause composition didn't confuse you so much that the
expressed content was incomprehensible to you.
Syntactically you can parse A - B -, C. as {A{B}}{C} to see what
belongs semantically together.

Janis

PS: Reading Ludwig Wittgenstein's Tractatus Logico-philosophicus might
help (or maybe not).

Hongyi Zhao

unread,
Aug 6, 2023, 9:10:20 PMAug 6
to
On Sunday, August 6, 2023 at 10:18:48 PM UTC+8, Janis Papanagnou wrote:
> On 06.08.2023 15:52, Hongyi Zhao wrote:
> > On Sunday, August 6, 2023 at 9:46:13 PM UTC+8, Janis Papanagnou wrote:
> >>
> >> If you want to embed Awk in Emacs I cannot help you - myself using it
> >> in a Unix system context from a shell command line -, but I'm sure
> >
> > Is the following usage of standard English grammar, as you have written above?
> >
> > -,
> Better ask in a newsgroup were languages, grammar, and semantics are
> discussed.

See <https://groups.google.com/g/alt.usage.english/c/446LFA9rfDw/m/a1XF_QtzAgAJ> for further discussion on this question.

> Myself not a native speaker I've used principles from my
> own language and some basic knowledge. What I can say (or speculate
> about, if you like) is...
> Relative clauses: A, B, C.
> Clauses in dash: A - B - C. (Often written with long - or double -- .)
> A composition of a relative clause with a dashed clause: A - B -, C.
> where the first part of the relative clause contains a dashed clause.
> Instead you can also use a parenthetical clause: A (B). or A (B) C.
> or as a composition with a relative clause: A (B), C.
> What you use depends on the intention, on what you want to express.
> (Some native speaker may provide corrections or better explanations.)
>
> I hope the clause composition didn't confuse you so much that the
> expressed content was incomprehensible to you.
> Syntactically you can parse A - B -, C. as {A{B}}{C} to see what
> belongs semantically together.
>
> Janis
>
> PS: Reading Ludwig Wittgenstein's Tractatus Logico-philosophicus might
> help (or maybe not).

Thank you for your comments and explanations.

Zhao
Reply all
Reply to author
Forward
0 new messages