helpListings package for LaTeX - Support: sr #292, lstlisting 1.4, the sh language

 
 
Show feedback again

You are not allowed to post comments on this tracker with your current authentification level.

sr #292: lstlisting 1.4, the sh language

Submitted by:  Brooks Moses <brooks>
Submitted on:  Tue Apr 12 20:12:49 2011  
 
Category: NonePriority: 5 - Normal
Severity: 5 - NormalStatus: None
Privacy: PublicAssigned to: None
Open/Closed: OpenOperating System: None

Tue Apr 12 20:12:49 2011, original submission:

Akim Demaille wrote, on Thu, 17 Jun 2010 14:26:48 +0200:


Hi,

I read this in lstlang1:

\lst@definelanguage{sh}%
{morekeywords={awk,break,case,cat,cd,continue,do,done,echo,else,%
env,eval,exec,expr,exit,export,false,fi,for,function,getopts,%
hash,history,if,kill,nice,nohup,ps,pwd,read,readonly,return,%
sed,shift,test,then,times,trap,true,umask,unset,until,while},%
morecomment=[l]\#,%
morestring=[d]"%
}[keywords,comments,strings]%

This is wrong, double quotes are backslashed, not doubled. Besides, there is also the single quote strings. In that case, the single quote cannot be escaped.

I suggest

morestring=[b]{"},%
morestring={'}%

but it does not work: I cannot pass no optional argument for the single quote. The more acceptable is [d], but it is not right. I cannot use [s] either.

Cheers!

Brooks Moses <brooks>
Project Administrator

 

Attached Files
file #90:  sh.tex added by brooks (554B - application/x-tex)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by brooks (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    1 latest change follows.

    Date Changed By Updated Field Previous Value => Replaced By
    Tue Apr 12 20:12:49 2011brooksAttached File-=>Added sh.tex, #90
    Show feedback again

    Back to the top


    Powered by Savane 3.1-cleanup+gray