Skip to content

Commit

Permalink
removing concatinated css files from wherever they are linked to with…
Browse files Browse the repository at this point in the history
… link tag. Fixes h5bp#452
  • Loading branch information
Divya Manian committed Jul 4, 2011
1 parent e12930a commit e3367bc
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion build/build.xml
Original file line number Diff line number Diff line change
Expand Up @@ -401,7 +401,7 @@
<target name="-invalid" description="(PRIVATE) Prevents deletion of current directory or other innocent directories from human error" depends="-check-publish-dir" if="publish-invalid">
<fail message="Your dir.publish folder setting could delete your entire site or worse. Change it in project.properties"/>
</target>
<target name="-clean" description="(PRIVATE) Wipe the previous build (Deletes the dir.publish directory" depends="-check-publish-dir" unless="publish-invalid">
<target name="-clean" description="(PRIVATE) Wipe the previous build (Deletes the dir.publish directory">
<!-- This is a private target -->
<echo message="Cleaning up previous build directory..."/>
<delete dir="./${dir.intermediate}/"/>
Expand Down Expand Up @@ -687,6 +687,13 @@


<!-- CSS -->
<target name="-css-remove-concatenated-stylesheets">
<echo>Removing ${css_file} from html</echo>
<replaceregexp match="&lt;link.+href=&quot;.*${css_file}&quot;.*&gt;" replace=" ">
<fileset dir="${dir.publish}" includes="${page-files}"/>
</replaceregexp>
</target>

<target name="-css" depends="-mkdirs" description="Concatenates and Minifies any stylesheets listed in the file.stylesheets property">
<echo message="Concatenating css..."/>

Expand Down Expand Up @@ -730,6 +737,7 @@
<mapper type="glob" from="*.css" to="${basedir}/${dir.publish}/${dir.css}/*.css"/>
<targetfile/>
</apply>
<foreach list="${file.stylesheets}" param="css_file" target="-css-remove-concatenated-stylesheets" />
</target>


Expand Down

0 comments on commit e3367bc

Please sign in to comment.