Permalink
Browse files

Release v0.6.1

  • Loading branch information...
1 parent 7db1fb6 commit d461241eb615aa014838a940753d67489ad34bb1 Nicholas C. Zakas committed Sep 8, 2011
View
@@ -1,3 +1,10 @@
+September 8, 2011 - v0.6.1
+
+* Workaround for Node.js stdout not flushing prior to exit (fixes #176) (Nicholas C. Zakas)
+* Ensure text-indent rule doesn't throw an error (fixes #179) (Nicholas C. Zakas)
+* Added documentation for shorthand rule (Nicholas C. Zakas)
+* Release v0.6.0 (Nicholas C. Zakas)
+
September 3, 2011 - v0.6.0
* Updated changelog task in build script (Nicholas C. Zakas)
@@ -119,3 +126,4 @@ June 15, 2011 - v0.1.0
+
View
@@ -1,7 +1,7 @@
<project name="csslint" default="build.all">
<!-- version number -->
- <property name="csslint.version" value="0.6.0" />
+ <property name="csslint.version" value="0.6.1" />
<!-- the directories containing the source files -->
<property name="src.dir" value="./src" />
View
@@ -21,7 +21,7 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*/
-/* Build time: 3-September-2011 10:59:45 */
+/* Build time: 8-September-2011 08:50:44 */
/*!
Parser-Lib
Copyright (c) 2009-2011 Nicholas C. Zakas. All rights reserved.
@@ -5432,7 +5432,7 @@ var CSSLint = (function(){
formatters = [],
api = new parserlib.util.EventTarget();
- api.version = "0.6.0";
+ api.version = "0.6.1";
//-------------------------------------------------------------------------
// Rule Management
@@ -7133,7 +7133,7 @@ CSSLint.addRule({
//event handler for end of rules
function endRule(event){
if (textIndent){
- reporter.warn("Negative text-indent doesn't work well with RTL. If you use text-indent for image replacement explicitly set text-direction for that item to ltr.", name.line, name.col, rule);
+ reporter.warn("Negative text-indent doesn't work well with RTL. If you use text-indent for image replacement explicitly set text-direction for that item to ltr.", textIndent.line, textIndent.col, rule);
}
}
@@ -7143,10 +7143,10 @@ CSSLint.addRule({
//check for use of "font-size"
parser.addListener("property", function(event){
var name = event.property.toString().toLowerCase(),
- value = event.value.parts[0].value;
+ value = event.value;
- if (name == "text-indent" && value < -99){
- textIndent = true;
+ if (name == "text-indent" && value.parts[0].value < -99){
+ textIndent = event.property;
} else if (name == "direction" && value == "ltr"){
textIndent = false;
}
View
@@ -21,7 +21,7 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*/
-/* Build time: 3-September-2011 10:59:45 */
+/* Build time: 8-September-2011 08:50:44 */
var CSSLint = (function(){
/*!
Parser-Lib
@@ -5433,7 +5433,7 @@ var CSSLint = (function(){
formatters = [],
api = new parserlib.util.EventTarget();
- api.version = "0.6.0";
+ api.version = "0.6.1";
//-------------------------------------------------------------------------
// Rule Management
@@ -7134,7 +7134,7 @@ CSSLint.addRule({
//event handler for end of rules
function endRule(event){
if (textIndent){
- reporter.warn("Negative text-indent doesn't work well with RTL. If you use text-indent for image replacement explicitly set text-direction for that item to ltr.", name.line, name.col, rule);
+ reporter.warn("Negative text-indent doesn't work well with RTL. If you use text-indent for image replacement explicitly set text-direction for that item to ltr.", textIndent.line, textIndent.col, rule);
}
}
@@ -7144,10 +7144,10 @@ CSSLint.addRule({
//check for use of "font-size"
parser.addListener("property", function(event){
var name = event.property.toString().toLowerCase(),
- value = event.value.parts[0].value;
+ value = event.value;
- if (name == "text-indent" && value < -99){
- textIndent = true;
+ if (name == "text-indent" && value.parts[0].value < -99){
+ textIndent = event.property;
} else if (name == "direction" && value == "ltr"){
textIndent = false;
}
View
@@ -1230,6 +1230,13 @@ background: -ms-linear-gradient(top, #1e5799 ,#2989d8 ,#207cca ,#7db9e8 );
"5px text-indent should not result in a warning": function(){
var result = CSSLint.verify(".foo{text-indent: 5px;}", {"text-indent": 1 });
Assert.areEqual(0, result.messages.length);
+ },
+
+ "This should cause a warning, not an error": function(){
+ var result = CSSLint.verify(".top h1 a { background: url(../images/background/logo.png) no-repeat; display: block; height: 44px; position: relative; text-indent: -9999px; width: 250px; }", { "text-indent": 1 });
+ Assert.areEqual(1, result.messages.length);
+ Assert.areEqual("warning", result.messages[0].type);
+ Assert.areEqual("Negative text-indent doesn't work well with RTL. If you use text-indent for image replacement explicitly set text-direction for that item to ltr.", result.messages[0].message);
}
}));
View
@@ -21,7 +21,7 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*/
-/* Build time: 3-September-2011 10:59:45 */
+/* Build time: 8-September-2011 08:50:44 */
/*!
Parser-Lib
Copyright (c) 2009-2011 Nicholas C. Zakas. All rights reserved.
@@ -5432,7 +5432,7 @@ var CSSLint = (function(){
formatters = [],
api = new parserlib.util.EventTarget();
- api.version = "0.6.0";
+ api.version = "0.6.1";
//-------------------------------------------------------------------------
// Rule Management
@@ -7133,7 +7133,7 @@ CSSLint.addRule({
//event handler for end of rules
function endRule(event){
if (textIndent){
- reporter.warn("Negative text-indent doesn't work well with RTL. If you use text-indent for image replacement explicitly set text-direction for that item to ltr.", name.line, name.col, rule);
+ reporter.warn("Negative text-indent doesn't work well with RTL. If you use text-indent for image replacement explicitly set text-direction for that item to ltr.", textIndent.line, textIndent.col, rule);
}
}
@@ -7143,10 +7143,10 @@ CSSLint.addRule({
//check for use of "font-size"
parser.addListener("property", function(event){
var name = event.property.toString().toLowerCase(),
- value = event.value.parts[0].value;
+ value = event.value;
- if (name == "text-indent" && value < -99){
- textIndent = true;
+ if (name == "text-indent" && value.parts[0].value < -99){
+ textIndent = event.property;
} else if (name == "direction" && value == "ltr"){
textIndent = false;
}
View
@@ -21,7 +21,7 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*/
-/* Build time: 3-September-2011 10:59:45 */
+/* Build time: 8-September-2011 08:50:44 */
var CSSLint = (function(){
/*!
Parser-Lib
@@ -5433,7 +5433,7 @@ var CSSLint = (function(){
formatters = [],
api = new parserlib.util.EventTarget();
- api.version = "0.6.0";
+ api.version = "0.6.1";
//-------------------------------------------------------------------------
// Rule Management
@@ -7134,7 +7134,7 @@ CSSLint.addRule({
//event handler for end of rules
function endRule(event){
if (textIndent){
- reporter.warn("Negative text-indent doesn't work well with RTL. If you use text-indent for image replacement explicitly set text-direction for that item to ltr.", name.line, name.col, rule);
+ reporter.warn("Negative text-indent doesn't work well with RTL. If you use text-indent for image replacement explicitly set text-direction for that item to ltr.", textIndent.line, textIndent.col, rule);
}
}
@@ -7144,10 +7144,10 @@ CSSLint.addRule({
//check for use of "font-size"
parser.addListener("property", function(event){
var name = event.property.toString().toLowerCase(),
- value = event.value.parts[0].value;
+ value = event.value;
- if (name == "text-indent" && value < -99){
- textIndent = true;
+ if (name == "text-indent" && value.parts[0].value < -99){
+ textIndent = event.property;
} else if (name == "direction" && value == "ltr"){
textIndent = false;
}
View
@@ -152,6 +152,12 @@ Writing selectors such as `li.active` are unnecessary unless the element name ca
Rule ID: `overqualified-elements`
+### Require shorthand properties
+
+Sometimes when editing a rule you may end up defining multiple properties that can better be represented using shorthand. This rule checks to see if you're using `margin-left`, `margin-right`, `margin-top`, and `margin-bottom` together and suggests to use just `margin` instead. The same is done for the variants of `padding`.
+
+Rule ID: `shorthand`
+
## Maintainability & Duplication
These rules help to ensure your code is readable and maintainable by others.
View
@@ -1,5 +1,5 @@
#!/usr/bin/env node
-/* Build time: 3-September-2011 10:59:45 */
+/* Build time: 8-September-2011 08:50:44 */
/*
* Encapsulates all of the CLI functionality. The api argument simply
* provides environment-specific functionality.
@@ -205,11 +205,19 @@ cli({
print: function(message){
fs.writeSync(1, message + "\n");
- fs.fsyncSync(1);
},
quit: function(code){
- process.exit(code || 0);
+
+ //Workaround for https://github.com/joyent/node/issues/1669
+ var flushed = process.stdout.flush()
+ if (!flushed) {
+ process.once("drain", function () {
+ process.exit(code || 0)
+ });
+ } else {
+ process.exit(code || 0);
+ }
},
isDirectory: function(name){
@@ -258,3 +266,4 @@ cli({
}
});
+
@@ -21,7 +21,7 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*/
-/* Build time: 3-September-2011 10:59:45 */
+/* Build time: 8-September-2011 08:50:44 */
/*!
Parser-Lib
Copyright (c) 2009-2011 Nicholas C. Zakas. All rights reserved.
@@ -5432,7 +5432,7 @@ var CSSLint = (function(){
formatters = [],
api = new parserlib.util.EventTarget();
- api.version = "0.6.0";
+ api.version = "0.6.1";
//-------------------------------------------------------------------------
// Rule Management
@@ -7133,7 +7133,7 @@ CSSLint.addRule({
//event handler for end of rules
function endRule(event){
if (textIndent){
- reporter.warn("Negative text-indent doesn't work well with RTL. If you use text-indent for image replacement explicitly set text-direction for that item to ltr.", name.line, name.col, rule);
+ reporter.warn("Negative text-indent doesn't work well with RTL. If you use text-indent for image replacement explicitly set text-direction for that item to ltr.", textIndent.line, textIndent.col, rule);
}
}
@@ -7143,10 +7143,10 @@ CSSLint.addRule({
//check for use of "font-size"
parser.addListener("property", function(event){
var name = event.property.toString().toLowerCase(),
- value = event.value.parts[0].value;
+ value = event.value;
- if (name == "text-indent" && value < -99){
- textIndent = true;
+ if (name == "text-indent" && value.parts[0].value < -99){
+ textIndent = event.property;
} else if (name == "direction" && value == "ltr"){
textIndent = false;
}
View
@@ -1,6 +1,6 @@
{
"name": "csslint",
- "version": "0.6.0",
+ "version": "0.6.1",
"description": "CSSLint",
"author": "Nicholas C. Zakas",
"os": ["darwin", "linux"],

0 comments on commit d461241

Please sign in to comment.