-
Notifications
You must be signed in to change notification settings - Fork 206
Comparing changes
Open a pull request
base repository: rodjek/puppet-lint
base: 1.0.1
head repository: rodjek/puppet-lint
compare: 1.1.0
Commits on Sep 18, 2014
-
Cache parsing state in Lexer rather than recalculating
Reported in #315, puppet-lint is painfully slow when processing large files. I reproduced this by creating a very large manifest (basically the same block of code concatenated over and over). ``` $ ls -la ~/test.pp -rw-r--r-- 1 tsharpe staff 165928 18 Sep 14:23 /Users/tsharpe/test.pp $ wc -l ~/test.pp 6296 /Users/tsharpe/test.pp ``` On 1.0.1, running the full suite of checks: ``` $ time bin/puppet-lint ~/test.pp bin/puppet-lint ~/test.pp > 1.0.1.output 169.96s user 0.26s system 99% cpu 2:50.26 total ``` Basically, the problem was that every time the lexer was creating a new token it would search through every byte of the file tokenised so far to count how many newlines had been found in order to add the line number to the Tokens. By changing the lexer so that it now keeps a counter which it increments everytime a :NEWLINE Token is created, we can avoid all this stupidity (keeping track of the state in regards to column number also provided a small win, but not as large as line number). On this branch, running the full suite of checks: ``` $ time bin/puppet-lint ~/test.pp bin/puppet-lint ~/test.pp > 315.output 9.43s user 0.08s system 99% cpu 9.513 total ```
Configuration menu - View commit details
-
Copy full SHA for af3bf4e - Browse repository at this point
Copy the full SHA af3bf4eView commit details -
Insert :WHITESPACE token between :NAME and :FARROW if needed
When fixing arrow alignment, ensure that we insert a new :WHITESPACE token if there isn't one there or we'll end up wiping out the parameter name when fixing the arrow alignment.
Configuration menu - View commit details
-
Copy full SHA for d7edd29 - Browse repository at this point
Copy the full SHA d7edd29View commit details -
Merge pull request #317 from rodjek/issue-315
Cache parsing state in Lexer rather than recalculating
Configuration menu - View commit details
-
Copy full SHA for 1c98182 - Browse repository at this point
Copy the full SHA 1c98182View commit details -
Merge pull request #318 from rodjek/issue-311
Insert :WHITESPACE token between :NAME and :FARROW if needed
Configuration menu - View commit details
-
Copy full SHA for 61d4b8e - Browse repository at this point
Copy the full SHA 61d4b8eView commit details
Commits on Sep 19, 2014
-
Don't parse class body when searching for parameter tokens
Fixes #319
Dominic Cleal committedSep 19, 2014 Configuration menu - View commit details
-
Copy full SHA for 817abfd - Browse repository at this point
Copy the full SHA 817abfdView commit details
Commits on Sep 21, 2014
-
Configuration menu - View commit details
-
Copy full SHA for d6bcfed - Browse repository at this point
Copy the full SHA d6bcfedView commit details -
Configuration menu - View commit details
-
Copy full SHA for b5bdb73 - Browse repository at this point
Copy the full SHA b5bdb73View commit details -
Merge pull request #321 from rodjek/issue-310
Support of metaparameter variables in variable_scope check
Configuration menu - View commit details
-
Copy full SHA for d84c3b7 - Browse repository at this point
Copy the full SHA d84c3b7View commit details -
Merge pull request #320 from domcleal/319-param-body
Don't parse class body when searching for parameter tokens
Configuration menu - View commit details
-
Copy full SHA for d6bf899 - Browse repository at this point
Copy the full SHA d6bf899View commit details -
Configuration menu - View commit details
-
Copy full SHA for d79ba24 - Browse repository at this point
Copy the full SHA d79ba24View commit details -
Configuration menu - View commit details
-
Copy full SHA for 7026a07 - Browse repository at this point
Copy the full SHA 7026a07View commit details -
Configuration menu - View commit details
-
Copy full SHA for 2d79fb8 - Browse repository at this point
Copy the full SHA 2d79fb8View commit details -
Handle multiple params on a line when fixing arrow_alignment problems
Move the additional params onto their own lines and indent them properly before adusting the whitespace between param and arrow to fix alignment.
Configuration menu - View commit details
-
Copy full SHA for 43ef2cb - Browse repository at this point
Copy the full SHA 43ef2cbView commit details -
Merge pull request #322 from rodjek/issue-312
Handle multiple parameters on a line when fixing arrow_alignment problems
Configuration menu - View commit details
-
Copy full SHA for 93153dc - Browse repository at this point
Copy the full SHA 93153dcView commit details
Commits on Sep 22, 2014
-
Configuration menu - View commit details
-
Copy full SHA for d2b116e - Browse repository at this point
Copy the full SHA d2b116eView commit details -
Configuration menu - View commit details
-
Copy full SHA for 3f5c3a9 - Browse repository at this point
Copy the full SHA 3f5c3a9View commit details -
Merge pull request #324 from rodjek/issue-323
Support for multiple node names in unquoted_node_name
Configuration menu - View commit details
-
Copy full SHA for fe3a7ae - Browse repository at this point
Copy the full SHA fe3a7aeView commit details -
Configuration menu - View commit details
-
Copy full SHA for b37c98e - Browse repository at this point
Copy the full SHA b37c98eView commit details -
Configuration menu - View commit details
-
Copy full SHA for bcddef9 - Browse repository at this point
Copy the full SHA bcddef9View commit details -
Merge pull request #325 from rodjek/issue-314
Support multiple commands in a single control comment
Configuration menu - View commit details
-
Copy full SHA for 3aa4d6d - Browse repository at this point
Copy the full SHA 3aa4d6dView commit details -
Configuration menu - View commit details
-
Copy full SHA for 8cfa590 - Browse repository at this point
Copy the full SHA 8cfa590View commit details -
Configuration menu - View commit details
-
Copy full SHA for 763575c - Browse repository at this point
Copy the full SHA 763575cView commit details -
Configuration menu - View commit details
-
Copy full SHA for c7c36bb - Browse repository at this point
Copy the full SHA c7c36bbView commit details -
Merge pull request #326 from rodjek/issue-305
Extend the rake task to support setting configuration options in the block
Configuration menu - View commit details
-
Copy full SHA for c08bf75 - Browse repository at this point
Copy the full SHA c08bf75View commit details
Commits on Sep 23, 2014
-
Configuration menu - View commit details
-
Copy full SHA for 7c52636 - Browse repository at this point
Copy the full SHA 7c52636View commit details -
Configuration menu - View commit details
-
Copy full SHA for 879b7eb - Browse repository at this point
Copy the full SHA 879b7ebView commit details
There are no files selected for viewing