<html>
<head>
</head>
<body style="font-size: 12pt; line-height: normal; margin-left: 4px; margin-right: 4px; margin-bottom: 1px; margin-top: 4px; font-variant: normal; font-weight: normal; font-family: Comic Sans MS; font-style: normal">
<p style="margin-bottom: 0; margin-top: 0">
<font face="Comic Sans MS" size="3">Oops, sorry about the typo below, I meant to say "I know this isn't exactly . . ."</font> </p>
<br>
<p style="margin-bottom: 0; margin-top: 0">
<font face="Comic Sans MS" size="3">bobb</font> </p>
<br>
<p style="margin-bottom: 0; margin-top: 0">
<br>
<br>
>>> "Bob Basques" <Bob.Basques@ci.stpaul.mn.us> wrote:<br> </p>
<table style="font-size: 1em; margin-left: 15px; margin-right: 0; margin-bottom: 0; margin-top: 0" border="0" bgcolor="#f3f3f3">
<tr>
<td>
<div style="padding-left: 7px; border-left: solid 1px #050505">
<p style="margin-bottom: 0; margin-top: 0">
<font face="Comic Sans MS" size="3">All,</font> </p>
<p style="margin-bottom: 0; margin-top: 0">
<br>
</p>
<p style="margin-bottom: 0; margin-top: 0">
<font face="Comic Sans MS" size="3">I've approached this topic over the years by having a nice Syntax editor available for MapFiles. Both VI and UltraEdit have proven to have good syntax templates for highlighting of edited MAPFILEs.</font> </p>
<p style="margin-bottom: 0; margin-top: 0">
<br>
</p>
<p style="margin-bottom: 0; margin-top: 0">
<font face="Comic Sans MS" size="3">I know this is exactly what was being asked about. But upon further thought, I wonder if a VI script couldn't be put together to do some of this checking, at least in pairing of quotes and END statements.</font> </p>
<p style="margin-bottom: 0; margin-top: 0">
<br>
</p>
<p style="margin-bottom: 0; margin-top: 0">
<font face="Comic Sans MS" size="3">Just a thought.</font> </p>
<p style="margin-bottom: 0; margin-top: 0">
<br>
</p>
<p style="margin-bottom: 0; margin-top: 0">
<font face="Comic Sans MS" size="3">bobb</font> </p>
<p style="margin-bottom: 0; margin-top: 0">
<br>
</p>
<p style="margin-bottom: 0; margin-top: 0">
<br>
<br>
>>> "Lime, Steve D (DNR)" <Steve.Lime@state.mn.us> wrote:<br> </p>
<table style="font-size: 1em; margin-left: 15px; margin-right: 0; margin-bottom: 0; margin-top: 0" border="0" bgcolor="#f3f3f3">
<tr>
<td>
<div style="padding-left: 7px; border-left: solid 1px #050505">
<p style="margin-bottom: 0; margin-top: 0">
Shp2img already provides this capability and is more portable than MapScript. I think ideally we'd develop<br>a validator that spits out all errors but that's probably not possible either since many common error states<br>(like a missing END or quote) will trigger a whole bunch of false positives. Best to take it an error at a<br>time for most cases. This might be useful more for between version migration where the mapfile is structurally<br>sound but keywords have changed.<br><br>We could write a dumber version of shp2img that only tries to load the mapfile and report an error but I'm not<br>sure it's worth the effort.<br><br>Steve<br><br>-----Original Message-----<br>From: mapserver-users-bounces@lists.osgeo.org [mailto:mapserver-users-bounces@lists.osgeo.org] On Behalf Of Ivan Mincik<br>Sent: Tuesday, May 15, 2012 10:24 AM<br>To: mapserver-users<br>Subject: Re: [mapserver-users] Mapfile verification tool<br><br>> I don't think this will work because the mapfile is read all at once<br>> and parsed into an internal data structure. You can't access it in<br>> mapscript until the parser has read it and the parser will error out on any errors.<br><br>Understand, but i mean only valid/invalid output from test script. If some error will raised - mapfile is invalid, with no other information where otherwise mapfile is OK.<br><br><br>--<br>Ivan Mincik<br>_______________________________________________<br>mapserver-users mailing list<br>mapserver-users@lists.osgeo.org<br><a href="http://lists.osgeo.org/mailman/listinfo/mapserver-users">http://lists.osgeo.org/mailman/listinfo/mapserver-users</a><br><br><br>_______________________________________________<br>mapserver-users mailing list<br>mapserver-users@lists.osgeo.org<br><a href="http://lists.osgeo.org/mailman/listinfo/mapserver-users">http://lists.osgeo.org/mailman/listinfo/mapserver-users</a><br>
</p>
</div>
</td>
</tr>
</table>
</div>
</td>
</tr>
</table>
</body>
</html>