4.2
JSHint 2.3.0 included
Removed some legacy options from JSHint configuration
Use any JSHint option, there’s a text field in which you can enter JSHint config options. (separated by comma).
A list of valid options can be found here: jshint.com/docs/options/
Rewritten JSHint-Wrapper (because JSHint works a bit differently now)
Removed some legacy JSHint options
4.1
Bugfix for a very improbable exception
Code update (mostly internal stuff)
Dialog layout improved when resized
4.0
CSSTidy updated to the current development release. This should now correctly format CSS inside @media-tags.
Integrated HTML 5 compatible tidy for validation and reformatting
3.9
New: Validate JS on save (Coda 2 only)
New: Separate CSS minification included
Fix PHP validation on save with selection
Laxcomma setting for JSHINT
JSMinify updated
3.8
Lots of bugfixes
Compatibility with other plugins improved
JSMinify updated
3.7
New: Minify on Publish (Coda 2 only)
New: Modify file extension list for PHP validate on save
Check if Growl is present, includes Growl 1.2 and Growl 1.3 notifier
CSSTidy: New option Remove last ; – control if the last ; in a block is removed or not
CSSTidy: Workaround for wrong @import behavior
JSHint: Doesn’t report useless strict warnings anymore
JSHint: Removed unused –safe option
JSHint: Added link to option documentation in the preferences
CSSTidy/JSMinify: CR/LF handling improved
PHPTidy won’t try to format php files with syntax errors
Rewritten launching of php based tools, more robust now
Refactoring PHP error display
Performance/memory improvements
Preferences layout improved, added Google+ link
3.6
“Unified” version for Coda 1 and Coda 2
Checks automatically if accidentally more than one plugin is installed
New function: PHP validate on save (Coda 2 only)
Javascript JSHint: Updated to a new version
Javascript Tidy (JSBeautify): Update to latest version, no file size limit anymore, CR/LF handling correctly now
CSS Tidy: Update to latest version, CR/LF handling correctly now
Performance improvements (loading time, js functions)
New version notification now shows the new version number…
Plugin path is now correct for Coda 1 and Coda 2
3.5 beta
Coda 2 compatible version
New preference setting for JSHint: Use smart tabs
“Go to line” (for PHP errors) now uses the API function in Coda 2, so it scrolls to the error location
Automatic update should now work correctly with Coda 1 and Coda 2
3.4
Remove proCSSor because the API service has been cancelled
3.3
Small bugfix for Prefs window layout
Internal structure improvement
Fix (improbable) memory leak
3.2
Validate PHP syntax before performing PHPtidy
Minify CSS
Updated CSSTidy
Preferences window improved (links to twitter/fb/donate)
JS Hint: Many more options
JS Hint: Respect line endings, whitespace warnings now correct
JS Tidy: Respect line endings
3.1
JS Tidy now also configurable
proCSSor bugfix
Respect Tabs/Spaces where available
Automatic Update (finally..!!)
Improved validation results
JS Hint updated
PHPTidy improvements
JS Hint: Remove (quite useless) “unsafe character” warning
Result window looks cooler now
Modularized the code
Modularized the code
Prefs window improved
3.0
Use selection
Growl (and growl-like) notifications
Results as floating window
More preferences for PHPTidy
HTML online validation: Included three validator settings
Drop curl, use cocoa instead
Use JSC call instead of shell script
JShint preferences
Improved preferences layout
Bugfixes, lots of
Nearly complete code rewrite
2.7
Show an short message after updating (only once)
Updated CSSTidy to 1.3.1
HTML Validate output improved
HTML5 support
aka workaround for tidy
JSLint replace by JSHint (upgrade, kind of)
Preference for PHPTidy: Fix statement brackets
2.6
Preferences for PHPTidy: New lines, Whitespaces, Comma spacing
Bugfix for umlaut conversion with JSTidy
2.5
Set CSS Level for validation (2, 2.1, 3)
Configure PHPTidy braces placement
2.4
Warning message (incompatible plugin) improved
Before accessing proCSSor, check if incompatible plugin present
2.3
TidyCSS update (current SVN)
W3C online response much more readable
Check for incompatible SBJsonParser
Error messages improved
Updatecheck circumvents cache now
2.2
New: Beep only for PHP validation
Preferences window now remembers the open tab
Preferences window revamped (again..)
Shortcuts also shown in the preferences
HTML Tidy version in about window now modified if “use internal” is changed
Improved some tooltips in the preferences
2.1
New: procssor.com configurable
New: JSBeautifier included
About window now part of the preferences
Preferences window revamped
Code clean-up
Shortcut for JS Beautifier
2.0
New: Encoding automatically selected
New: Custom HTML tidy configuration
New: Included a more recent HTML tidy binary
New: procssor.com online service included (experimental)
Goto line now works correctly with different line endings
Line endings now respected in HTML tidy, CSS tidy and PHP tidy
HTML tidy version shown in the about page
Preferences window new layout
JS lint now correctly handles backslashes
Error messages improved
Message sheet layout improved
1.9
New: JS Minify
HTML Validation report window now can be close without the annoying “Save Changes”-question
“Reveal in Finder” bugfix at preferences page
Donation button in the about window (Hint: click it :)
1.81
CSS tidy now handles CSS3 values starting with a dash (-)
Keyboard shortcuts for CSS tidy and Preferences
Some code clean-up
1.8
Javascript Lint (JSLint) now included
Update check now daily instead of each time Coda starts
New CSS tidy configuration: Sort attributes
1.7
HTML tidy now configurable (in the Preferences) !
Preferences are automatically saved
Bugfix when saving Coda Prefs
1.62
Automatic update check now in the background (asynchronous)
CSS tidy now configurable (in the Preferences) !
Less intrusive error-messages on connection failures
1.6
User Preferences
Automatic check for updates
CSS tidy integrated
Structured Menu (aka Submenus)
Using the HTML-tidy version delivered with OSX (PowerPC compatible)
Redesigned the error- and “validation okay”-sheets XCode-like
More encodings: ASCII, UTF-16, Windows CP-1252
All functions use the current buffer contents now
Error messages not explicitely state their origin
Updated phptidy to current version 2.10
1.4
W3C-Validation online for HTML-files
W3C-Validation online for CSS-files
Help button (on the about sheet) now opens this page
1.31
W3C-Validation service, 1st try
1.3
Improved Sheet display
Bugfixes
1.13
Validate HTML (via tidy)
Jump to error line – if PHP validation finds an error
Check for Updates (in the about-box)
File encoding can be chosen
Nice sheets, no more of those ugly alert-boxes
Menu items are only available if they should be
Lots of code cleanup
More useful “About”-dialogue, link to the plugin homepage
0.96
“About..”-dialog
Improved exception handling
Bugfixes
0.9
New features: HTML tidy, Strip PHP, PHP tidy
Included HTML Tidy
Included phptidy
Bugfixes
0.85
Bugfixes, dialogs updated
0.8
Initial release
v.4.1 CSS minification shouldn’t quote @keyframes name.
Source:
@keyframes rot45 {
from {transform:rotate(0);}
to {transform:rotate(45deg);}
}
Becomes minified:
@keyframes “rot45″{from{transform:rotate(0);}to{transform:rotate(45deg);}}
This ruins css animation.
Hotfix is a regexp replace
from
keyframes\ \”([a-z-]+)\”
to
keyframes \1
in the minified css.
upd. hotfix “from” regexp should be
keyframes\ \”([0-9a-z-]+)\”
Trying to figure out how to remove ’empty’ line spaces for HTML tidy. Can this be done? I went and found the plugin but not sure where in the contents folder to modify.
Great!
Is there a formatter for mixed HTML/PHP?
I currently don’t know of one – except of course software like phpstorm.
Maybe this is a feature and I’m missing it:
Is there a simple way to select a block of code/text and enclose it with
Am I just that bad at Coda 2?
Your plugins are amazing.
Hi,
use Text -> Wrap in Tag.
Hello, it very nice plugin. good job. I’m using Symfony2 and I want to know if it is possible to configure and tidy html.twig tags. because till now when i try to tidy html, that break or remove tags and Blocks.
I think also i will be nice if your plugin can become open source, and by this way people can contribute for it developpement.
thanks
No, that’s not possible with HTML tidy, the software I use to format HTML.
About open source: Yes, that’s my plan anyway.
Thanks, this really helps my workflow!
I noticed that when I ran HTML –> Tidy HTML it deleted all of my icon elements (i) in HTML. For example, was deleted, had about 5 i elements that were missing. Thanks for your hard work!
You can use the 4.2beta and select the html5 tidy in the preferences – then i-tags shouldn’t be removed anymore. (In the prior version of html tidy you should use em-tags instead).
Is there a way to set custom JSHint options for example the unused warning is kind of annoying, because they are being used.
I believe the beta 4.2 version may have fixed this, can you update the changelog per chance?
Thanks much!
Yes, you’re right. The changelog was some months behind :)
Thx.
Hi, I have upgraded to the new Growl (V2.1.3) from the AppStore and tried to used it the Coda PHP & Web Toolkit (V4.1).
Unfortunately, it doesn’t seem to find Growl and continues to use the standard notification dialogs.
I use auto-checking when saving JavaScript files and the problem I have with the standard dialogs is that they don’t disappear by themselves. Instead of going away after a while or when a new notification comes, they just pile onto each other and after a days work I have several hundred notifications visible.
So the question is now, how can I activate Growl?
Usually you just check “Notify via Growl” on the General section of the plugin preferences, but it might be incompatible with the new Growl version.
First thing: Try the latest 4.2 beta version of the plugin.
The “everything fine” dialogs should disappear by themselves, just tested it – but in case of problems the error messages (of course) don’t disappear by themselves. So in my opinion this behaviour is correct, which behaviour would you expect in case of errors?
Thanks for you quick reply!
I’ve tried the beta, but there the standard notification are also used, regardless of the “Notify via Growl” setting.
In case of an new error I would expect that any previous notifications should be closed. The way it is now, all previous notification stay open, but their contents is gone. This doesn’t seem to make sense.
Another thing I noticed: when saving multiple files with Command-Option-S, I wouldn’t be able to find out which file created error messages, because the filename doesn’t show in the notification.
The filename is a good idea for the error window, noted.
Now I see your problem, the “old” dialogs just hang around and are empty – yes that’s a bug. Is on the list, thx!
About the filename: This should be present (using latest 4.2beta) as window title, like “JSHint validation result for indent-crlf.js”
Is there a possibility that Tidy HTML dont make a line break after for exampe every
Hi – Love the plugin and it saves me heaps of time!
One annoying aspect I find is that when using the tidy functions there is no option to use tabs instead of spaces.
I love the tidy functions and it is one of the main things I use this plugin for, but I have to do a find/replace to get all my tabs back in there.
I second this request, only thing missing from this awesome plugin.
Thanks!
Hi –
this feature is with the currently included html tidy not possible (from the documentation: “Tidy never outputs tabs.”), but it might be there’s a new html5-tidy which supports this feature. I’ll have a look.
really don’t know if this will solve my problem
my script no longer installs becasue of updated php version, can i get your direct email so that i can send screen shots and the small script.
Is there a way to insert a space after the CSS attribute? ie. format it this way:
body {
font-size: 14px;
}
…instead of…
body {
font-size:14px;
}
Hi –
that’s on my todo-list but it might take some time until I find the time for an update. If you know PHP you can modify the file “csstidy.php” yourself (if you right click on (your home folder)/Library/Application Support/Coda 2/Plug-Ins/PhpPlugin.codaplugin, choose “show contents” and go to “Contents/Resources”). Starting from line 642 are the rules for the CSS-Tidy modes.
Note that your changes will be overwritten with the next update – but then this is hopefully already integrated :)
So great!! Thanks a lot!
Hi, I have a feeling something is goofy with my setup, when I try to use HTML tidy I get a dialog telling me Coda 2 quit unexpectedly (although it doesn’t actually quit), then a dialog telling me “Tidy returned nothing”
Any help is appreciated :-)
Tom
Hi –
it seems the tidy executable makes problems. As first idea please try “Use HTML5 compatible Tidy” in the settings (or disabled it, if it was already enabled). If that doesn’t help: Which Mac and which OS X version do you have?
It should be handy to not remove css comments on wordpress because it is used by the CMS for internal use.
Also minify on upload for html and php would be awesome since firefox is messing up with spaces between divs
You could perhaps include this new Tidy library https://github.com/w3c/tidy-html5
It has some new cool feature, like not removing empty tags
It’s already included in the latest beta version :)
This wonderful plugin has change my life.
I love the tidy and minify for code.
Many many thanks for plugin development and great supporting.
Hi,
This is a great plugin for Coda! I have a question with HTML tidy.
I’m trying to tidy a section of HTML which is used as a template. It doesn’t need tags. However, the plugin kept adding all these tags which is quite annoying. I have read the whole option reference and can’t find one option which can turn it off.
Pls advise if it is possible to turn the “Automatic HTML Head Adding” off.
Thanks!
The message seems striped my < bracket. I mean the html, title, head, body tag.
Hi –
therefore just use the “body only” preset, that’s exactly for this case.
Great plugin to find PHP syntax errors – you saved me hours!
Hi,
I’m having a minor issue with the plugin, maybe a bug?
All the commands work except for “Tidy HTML”.
It pumps out an error in Coda:-
NSInvalidArgumentException
Error: launch path not accessible
Console Log:
20/1/14 3:46:44.424 pm Coda 2[939]: Exception occurred: 0 ExceptionHandling 0x00007fff88958aee NSExceptionHandlerExceptionRaiser + 172
1 libobjc.A.dylib 0x00007fff8836ae75 objc_exception_throw + 43
2 CoreFoundation 0x00007fff8429f2cc +[NSException raise:format:] + 204
3 Foundation 0x00007fff8c5a8777 -[NSConcreteTask launchWithDictionary:] + 450
4 PhpPlugin 0x0000000114bc8462 -[CwPhpPlugin filterTextInput:with:options:encoding:useStdout:] + 705
5 PhpPlugin 0x0000000114bc7eab -[CwPhpPlugin reformatWith:arguments:called:] + 119
6 PhpPlugin 0x0000000114bc5434 -[CwPhpPlugin doTidyHtml] + 345
7 AppKit 0x00007fff898743d0 -[NSApplication sendAction:to:from:] + 327
8 AppKit 0x00007fff8988f348 -[NSMenuItem _corePerformAction] + 394
9 AppKit 0x00007fff8988f084 -[NSCarbonMenuImpl performActionWithHighlightingForItemAtIndex:] + 117
10 AppKit 0x00007fff898de4dd -[NSMenu _internalPerformActionForItemAtIndex:] + 35
11 AppKit 0x00007fff898de359 -[NSCarbonMenuImpl _carbonCommandProcessEvent:handlerCallRef:] + 104
12 AppKit 0x00007fff89885176 NSSLMMenuEventHandler + 716
13 HIToolbox 0x00007fff8c7206d4 _ZL23DispatchEventToHandlersP14EventTargetRecP14OpaqueEventRefP14HandlerCallRec + 892
14 HIToolbox 0x00007fff8c71fc87 _ZL30SendEventToEventTargetInternalP14OpaqueEventRefP20OpaqueEventTargetRefP14HandlerCallRec + 385
15 HIToolbox 0x00007fff8c733d90 SendEventToEventTarget + 40
16 HIToolbox 0x00007fff8c769a30 _ZL18SendHICommandEventjPK9HICommandjjhPKvP20OpaqueEventTargetRefS5_PP14OpaqueEventRef + 420
17 HIToolbox 0x00007fff8c79c618 SendMenuCommandWithContextAndModifiers + 59
18 HIToolbox 0x00007fff8c79c5c4 SendMenuItemSelectedEvent + 178
19 HIToolbox 0x00007fff8c79c4a5 _ZL19FinishMenuSelectionP13SelectionDataP10MenuResultS2_ + 94
20 HIToolbox 0x00007fff8c7a4425 _ZL14MenuSelectCoreP8MenuData5PointdjPP13OpaqueMenuRefPt + 718
21 HIToolbox 0x00007fff8c7a4051 _HandleMenuSelection2 + 446
22 AppKit 0x00007fff897f779c _NSHandleCarbonMenuEvent + 284
23 AppKit 0x00007fff8965656e _DPSNextEvent + 2170
24 AppKit 0x00007fff896558db -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] + 122
25 AppKit 0x00007fff896499cc -[NSApplication run] + 553
26 AppKit 0x00007fff89634803 NSApplicationMain + 940
27 Coda 2 0x0000000100002a04 start + 52
28 ??? 0x0000000000000001 0x0 + 1
Hi –
it seems the plugin doesn’t find (or can’t access) the included HTML tidy executable. Did you check the hints here http://www.chipwreck.de/blog/software/coda-php/help/#quick ?
If that doesn’t help, write me an email and we’ll sort it out..
mario
Same – did you get this working?
The JS Minify function is putting a lot of things in new line. Is there any option or way it could puts everything in one line? The way actual minify should work?
Also, is there a way to maintain a file.min.js for the minified version (published version) and file.js for development. This is the way I think it should be… Don’t you think?
Hi –
the JSMin implementation is not very flexible. It’s a port of the Douglas Crockford JS Minify, but maybe there are better solutions now. For the next version I’ll have a look.
About the .js/.min.js: Of course this would be the best practice. Currently you can keep the .js-version locally and publish the minified version automatically (see plugin settings). If I find some time I might include another option to automatically save a “*.min.js”-file next to the original file.
Thanks for the reply brother. I found that the YUI Compress plugin for Coda does this (saves a .min.js). Maybe you can look into that in next versions of the plugin :)
This is what I was looking for a long time ago. Only one question. Is it possible to have a tab indent code format instant of a 4 space indent?
ditto; need this feature if i’m going to use this and still work with other people.
You can switch this per file in the Coda settings or with the gear-icon at the bottom.
Thank you
What are the chances of JSHint being updated? it’s a very old version and no longer supports all the modern options such as quotmark: http://www.jshint.com/docs/options/#quotmark
All my scripts now throw at least two warnings because of quotmark and other modern flags.
Chances are quite good :)
I suppose in the next days I’ll find the time to update JSHint and the plugin.Have a look at the beta version above!Awesome! Thanks!
Thanks for the plugin however there are still some annoying issues such as:
1. Why HTML head and body tags added each time I want to Tidy-up only a body code? I know I can use the “body only (experimental), but it’s still experimental and deletes other code parts such as PHP includes outside of the HTML tags.
2. Input tags such as Label, Textarea and Inputs are Tidy-up funny. Textarea breaks in the middle if you use a placeholder, the closing tag indents to the far left not under the opening tag.
3. Label and input tags follow each other rather then wrap as separate tags.
Thanks,
The thing is I use HTML tidy and can’t simply add features or modify its inner workings. You can play around with the settings (see documentation on the plugin settings page), that should help.
About “body only”: I’ll remove that “experimental” tag :) But php-statements should be left in the code, at least if you use the complete form for php-tags (that is: ?php … ?, with the brackets of course).
Thanks for the quick reply.
Almost all front-end code is build on includes and parts not full HTML pages with body and head tags. having those added each time I try to tidy part of my code is annoying and time consuming.
Cheers
Of course, same goes for most complex web projects.
HTML tidy is good for validating complete HTML pages but for HTML snippets it’s surely not the best. As soon as I know of a better tool for this purpose I’d be glad to include it if possible…
Hi there,
I have PHP & Web Toolkit for Coda 2 and lately I’ve noticed that the CSS Minify and CSS Tidy features are resulting on the same thing (minified CSS).
Are you aware of this issue? Any help or solutions for this?
Thanks anyway ;)
That depends on the CSS tidy configuration in the plugin settings. If you choose “highest compression” it is quite the same, but not for the other settings..
That does it ;)
I can confirm that the HTML Tidy option, using the Body Only configuration does all kinds of different things to embeded php tags. Some it throws away completely, some it converts to <?php and some it leaves alone.
Is there a configuration option (Custom, perhaps?) that simply indents the HTML nicely and doesn’t add, change or delete anything?
Hi there, thanks for this useful coda plugin!
I got an issue with the HTML tidy function: i set up for the BODY ONLY tidy mode and aN HTML tag like this “i” “/i” disappear after the script command. I flagged HTML5 compatible compatible tidy but unfortunately nothing is changed.
Have you any suggestion to fix it?
Thanks in advance for your response.
Hey how to show you the html tag?
Hi –
the “i”-tag (just don’t use the brackets to show tags here) is deprecated therefore considered invalid. Use “em” “/em” instead.
I really wish the Tidy HTML command would put comments on a separate line. This plugin would be perfect if it did. As it is now, I have to go back in and move all my comments. Is there a setting I’m missing?
Hi –
I’m afraid that’s a limitation of HTML tidy, so you might look on their website if the feature is maybe planned.
Great plug-in. Could it be extended for .scss validation?
Hi –
I don’t think I’ll find the time soon (and have no idea if there is a free and compatible validation tool)..
Hi, thanks for a great plugin. I do have a problem using PHP tidy code, on just a selection. It works great if I do not tick selection. Then it does the whole file. But when I tick to just apply to selection, nothing happens when I try to use it. It does say that it worked, but it doesn’t. Tried from both top menu and right-click menu. Advice?
Probably a problem with the selected code, try again with other parts and check if that works..
Great plugin, I have the problem where bootstrap / font-awesome / icomoon etc all use empty tags as placeholders for icons / glyphs, and can’t find a setting that leaves them alone (custom doesn’t seem to have that option). Anything you could do to help exclude certain empty tags (or tags that are empty but have an attribute) in a future version would be appreciated!
You could try to use “new-empty-tags” as custom config option, but I’m not sure if the included version of HTML Tidy already supports this option – but in the future I’ll surely update HTML tidy so that new-empty-tags will be supported.
I’d like this feature too, could you explain more about how to use ‘new-empty-tags’ to accomplish this?
In the custom configuration you can add a list of tags which can be empty by default, like this:
new-empty-tags: test,address
This is included in the HTML 5 compatible tidy but according to the issue tracker on Github it doesn’t work realiably. Probably the next weeks I’ll put another version online with an updated version of tidy
It would be nice to have a php version option so that specific php language features can be tested, for example, the short array syntax “[]” in php 5.4.
I would also be nice if the plugin supported the short array syntax.
Hi –
the plugin calls the installed php interpreter to check the syntax, so if you have php 5.4 installed (via MacPorts for example) you can set the php binary to use in the plugin options (like /opt/local/bin/php i.e.).