<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>The Code Train &#187; command line</title>
	<atom:link href="http://thecodetrain.co.uk/tag/command-line/feed/" rel="self" type="application/rss+xml" />
	<link>http://thecodetrain.co.uk</link>
	<description>Where Neil Crosby talks about coding on the train...</description>
	<lastBuildDate>Sun, 03 Apr 2011 18:15:12 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Running the W3C CSS Validator locally from the command line</title>
		<link>http://thecodetrain.co.uk/2009/02/running-the-w3c-css-validator-locally-from-the-command-line/</link>
		<comments>http://thecodetrain.co.uk/2009/02/running-the-w3c-css-validator-locally-from-the-command-line/#comments</comments>
		<pubDate>Wed, 18 Feb 2009 21:36:18 +0000</pubDate>
		<dc:creator>Neil Crosby</dc:creator>
				<category><![CDATA[Blog Posts]]></category>
		<category><![CDATA[command line]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[feci]]></category>
		<category><![CDATA[installation]]></category>
		<category><![CDATA[offline]]></category>
		<category><![CDATA[validator]]></category>
		<category><![CDATA[w3c]]></category>

		<guid isPermaLink="false">http://thecodetrain.co.uk/?p=203</guid>
		<description><![CDATA[<p>One of the things I&#8217;m currently working on is being able to run automated tests of FrontEnd Web Systems.  In order to carry out the first phase of this testing I need local installations of the <a href="http://validator.w3.org/">HTML Validator</a>, <a href="http://jigsaw.w3.org/css-validator/">CSS Validator</a> and <a href="http://jslint.com">JsLint</a> (when automatically running these tests many times a day it&#8217;s not fair to put that load on these free services).</p>

<p>I&#8217;m currently working on the CSS portion of the First Phase, so I&#8217;ve been looking at getting the W3C CSS Validator running locally on my machine.  Since there was a tiny bit more to it than there seemed from the <a href="http://jigsaw.w3.org/css-validator/DOWNLOAD.html">W3C&#8217;s setup instructions</a>, I thought I&#8217;d better write down how I did it.</p>

<ol>
<li><p><a href="http://www.w3.org/Jigsaw/#Getting-2-2-6">Download the Jigsaw web server</a> and unzip it to a location of your choice.  We&#8217;ll be needing the servlet.jar file from it later (it&#8217;s in <code>Jigsaw 2/classes/servlet.jar</code>)</p></li>
<li><p>Open a terminal window, and change directory to somewhere you&#8217;re happy to put the CSS Validator.  The CVS password, when prompted, is &#8220;anonymous&#8221;.</p>

<pre><code>CVSROOT=:pserver:anonymous@dev.w3.org:/sources/public cvs login
CVSROOT=:pserver:anonymous@dev.w3.org:/sources/public cvs checkout \
2002/css-validator
cd 2002/css-validator
mkdir lib
cp {your servelet.jar location} lib
ant jar
</code></pre></li>
<li><p>Assuming nothing goes wrong, you&#8217;ve got yourself a self-contained, offline CSS Validator.  Awesome.</p></li>
<li><p>Test the validator by running the following:</p>

<pre><code>java -jar css-validator.jar --output=soap12 http://www.w3.org/
</code></pre></li>
<li><p>By running the following, you can see the options available to you from the validator:</p>

<pre><code>java -jar css-validator.jar
</code></pre>

<p>These options are explained in the <a href="http://jigsaw.w3.org/css-validator/manual.html">CSS Validator User Manual</a>.</p></li>
</ol>

<p>And that, as they say, is all there is to it.  From this, it shouldn&#8217;t be too difficult to set the validator up to run as a website if you want to, but that wasn&#8217;t necessary for me right now, so I didn&#8217;t do it myself.</p>
<div style="display:block"><small><em><a href="http://neilcrosby.com">Neil Crosby</a> also blogs at about t-shirts at <a href="http://iwearcotton.com">I Wear Cotton</a>, writes <a href="http://thetenwordreview.com/users/workingwithme">Ten Word Reviews</a>, and uploads <a href="http://www.flickr.com/photos/thevoicewithin/">photos</a> to flickr.  You can follow a combined feed of posts at <a href="http://neilcrosby.com/">NeilCrosby.com</a>.</em></small></div>]]></description>
			<content:encoded><![CDATA[<p>One of the things I&#8217;m currently working on is being able to run automated tests of FrontEnd Web Systems.  In order to carry out the first phase of this testing I need local installations of the <a href="http://validator.w3.org/">HTML Validator</a>, <a href="http://jigsaw.w3.org/css-validator/">CSS Validator</a> and <a href="http://jslint.com">JsLint</a> (when automatically running these tests many times a day it&#8217;s not fair to put that load on these free services).</p>

<p>I&#8217;m currently working on the CSS portion of the First Phase, so I&#8217;ve been looking at getting the W3C CSS Validator running locally on my machine.  Since there was a tiny bit more to it than there seemed from the <a href="http://jigsaw.w3.org/css-validator/DOWNLOAD.html">W3C&#8217;s setup instructions</a>, I thought I&#8217;d better write down how I did it.</p>

<ol>
<li><p><a href="http://www.w3.org/Jigsaw/#Getting-2-2-6">Download the Jigsaw web server</a> and unzip it to a location of your choice.  We&#8217;ll be needing the servlet.jar file from it later (it&#8217;s in <code>Jigsaw 2/classes/servlet.jar</code>)</p></li>
<li><p>Open a terminal window, and change directory to somewhere you&#8217;re happy to put the CSS Validator.  The CVS password, when prompted, is &#8220;anonymous&#8221;.</p>

<pre><code>CVSROOT=:pserver:anonymous@dev.w3.org:/sources/public cvs login
CVSROOT=:pserver:anonymous@dev.w3.org:/sources/public cvs checkout \
2002/css-validator
cd 2002/css-validator
mkdir lib
cp {your servelet.jar location} lib
ant jar
</code></pre></li>
<li><p>Assuming nothing goes wrong, you&#8217;ve got yourself a self-contained, offline CSS Validator.  Awesome.</p></li>
<li><p>Test the validator by running the following:</p>

<pre><code>java -jar css-validator.jar --output=soap12 http://www.w3.org/
</code></pre></li>
<li><p>By running the following, you can see the options available to you from the validator:</p>

<pre><code>java -jar css-validator.jar
</code></pre>

<p>These options are explained in the <a href="http://jigsaw.w3.org/css-validator/manual.html">CSS Validator User Manual</a>.</p></li>
</ol>

<p>And that, as they say, is all there is to it.  From this, it shouldn&#8217;t be too difficult to set the validator up to run as a website if you want to, but that wasn&#8217;t necessary for me right now, so I didn&#8217;t do it myself.</p>
]]></content:encoded>
			<wfw:commentRss>http://thecodetrain.co.uk/2009/02/running-the-w3c-css-validator-locally-from-the-command-line/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

