PreviousNextTracker indexSee it online !

(145/231) 3487912 - syntax highlight in shell script #!/bin/sh is not correct

Hi,

I have found some issue with syntax highlighting for shell script/s.
Jedit 4.5 , java 64bit sdk version 1.7.0_02 , ubuntu 11.10 64 bit.

1. problem:
It is hghlighting on magenta color even if it is not text
I have attached file to exam. Line 42 and following appeared wrongly highlighted.
If I added one single quotation mark at the end - syntax highlighting is correct (but shell syntax not).

2. problem , line 1440
this block
cat <<\\_ACEOF
...
_ACEOF
is wrongly highlighted which makes the rest of file wrongly highlighted as well.

I compared attached script as example with editor Kate where it is correctly highlighted.

Regards,
Martin

Submitted masuch2 - 2012-02-15 - 16:57:57z Assigned nobody
Priority 5 Category None
Status Open Group None
Resolution None Visibility No

Comments

2012-04-27 - 12:17:53z
kpouer
Hi, this is jEdit's bug not plugin.
I'm not sure about your syntax

you do:

cat <<\\_ACEOF
...
_ACEOF

If you remove the \\ it seems it works, I'm not a shellscript expert but what is the difference with the syntax
cat <<_ACEOF
...
_ACEOF

is this one invalid ?
2012-05-05 - 16:41:53z
masuch2
OK,

cat <<\\ACEOF is quite NOT important.

-----------------------------
!!! The most important is double quotes syntax highlighting !!!

for example following code is as well wrongly highlighted:
echo "------ initctl list|grep $SERVICE"
initctl list|grep ${SERVICE}"
RETVAL=$?
if [ -z "${RETVAL}" ]; then

2012-05-05 - 16:49:14z
masuch2
Sorry, just ignore my previous example - wrong copy / paste.

Attachments

2012-02-15 - 16:58:01z
masuch2
a.sh.tar.gz