This is the mail archive of the docbook-apps@lists.oasis-open.org mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: metrics tool to count xsl lines of code?


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

/ "Billard, Trish" <trish.billard@hp.com> was heard to say:
|   Does anyone know of a (preferably free) metrics tool that counts lines of .xsl code?  We'd need something that would exclude white space and comments, and not count something like this:
|
| <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform";
|                 xmlns:xt="http://www.jclark.com/xt";
|                 extension-element-prefixes="xt"
|               version='1.0'>
|  as 4 lines just because it's formatted that way.
|
| We need it to do some planning and estimating for a project that involves writing and modifying .xsl stylesheets.
|
| Any ideas?

Run the stylesheet through an identity transform in XSL, that'll get rid of
all the comments, then count start tags. (Or just count "<" and divide by 2).

                                        Be seeing you,
                                          norm

- -- 
Norman Walsh <ndw@nwalsh.com>      | So, are you working on finding
http://www.oasis-open.org/docbook/ | that bug now, or are you leaving
Chair, DocBook Technical Committee | it until later? Yes.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: Processed by Mailcrypt 3.5.7 <http://mailcrypt.sourceforge.net/>

iD8DBQE91qsaOyltUcwYWjsRAhuIAKCPuuY5GMwzOzuA+zZfvw8PiiRn5ACZAdRt
3MvvWkD+Aad4HBcIo9sO0bA=
=RbSR
-----END PGP SIGNATURE-----


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]