Skip to content
This repository has been archived by the owner on Nov 23, 2018. It is now read-only.

JS filename replacement in HTML is not parsing script tag when HTML is actually a server side template #154

Open
kierans opened this issue Mar 15, 2013 · 0 comments

Comments

@kierans
Copy link

kierans commented Mar 15, 2013

Similar to issue #153, for my project the JS is concatenated/minified by h5bp however the HTML pages are actually JSP tag templates. The current replacement regexp however is not parsing the script block when JSP snippets are in the code eg:

<!-- scripts concatenated and minified via build script -->
<script src="<%= application.getContextPath() + "/js/main.js" %>"></script>
<!-- end scripts -->

doesn't get parsed and main.js is not replaced with the correct file name.

I'll be submitting a pull request with a fix where quotes are included in capture groups and non greedy qualifiers used to achieve better matching.

kierans added a commit to kierans/ant-build-script that referenced this issue Mar 15, 2013
… minified JS filename; when script block has server side snippets present.

This fixes issue h5bp#154
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant