Support for live preview of Haml in Coda or Espresso? - html

I just discovered the beautiful Haml and Sass, and want to develop in these languages but with live previews. Coda and Espresso both allow for beautiful live previews of HTML files, but previews of an Haml file simply show it as plain text.
While there exist sugars for Espresso that add syntax highlighting, which is nice, I would like something that automatically compiles Haml files to HTML, and then lets me preview that instead of Haml.
Does anything like this exist for either Coda, or Espresso, or for any other web development tool out there?
(If it makes a difference, I'm not developing for Ruby on Rails, I'm making a static website, so the Ruby on Rails plugin shouldn't help AFAIK.
Software I tried out were StaticMatic and Middleman. StaticMatic's development seems discontinued, and for some reason MiddleMan refuses to work after creating my initial directory structure. Maybe I'm using it wrong.)

I don't use Espresso, so no comment there. However, Coda does not provide any support for Haml or Sass that I can find. I've been closely following the Coda forums, as I am a paid user, and it looks as though a 2.0 version is forthcoming. Who knows, perhaps that'll be included.
For now, since you're not using Ruby on Rails, I might suggest TextMate. It doesn't do Haml or Sass "right out of the box", but it can be configured to do so using "Bundles."
Installing HAML bundle for TextMate is a primer on how to setup TextMate for Haml/Sass, and I suspect there are others.
That said, for roughly the cost of TextMate you can purchase RubyMine ($69), which does both Haml (via RubyGem) and Sass (via Plugin), and can also handle running Sass --watch internally. I know you're not using Ruby, so maybe the idea of using a tool made primarily for Ruby doesn't appeal, but it does work in both the Haml and Sass environments very nicely.
The third option would be BBEdit, which can also handle both Haml and Sass. Some information on the plugin for BBEdit is in BBEdit-Codeless-Language-Module-for-HAML-SASS.
I hope this helps.
P.S.: I'm a paid user on all the platforms I mentioned. While I use RubyMine as my primary tool, I find that TextMate still gets a lot of use when I'm programming and need a quick, friendly window to examine code in. I used to use BBEdit when I needed to do complex regular expression-style search and replacements, but then I discovered how to do the same thing in TextMate, so BBEdit is sort of collecting dust. Coda? It looks pretty, but doesn't get the job done so much any more (though Panic's Transmit is still very much a core application).

There are two plugins for Coda 2 that I am aware of:
Coda-Sass-Plug-in is available from GitHub and allows you to save out your scss files to css. I worked for me though I wasn't completely happy with needing to refresh multiple tabs all the time.
LessCSS is available from incident57 dot com. Although I was never able to make it work, it lead me to CodeKit (CodeKit has been mothballed due to production of CodeKit).
CodeKit has the ability to watch folders and generate css files from sass or less when they are saved. It also has the ability to handle Stylus, Haml, Javascript, CoffeeScript, Jade, Slim and Kit.

OK, for anyone else looking for an answer to this, I decided to go along with a different solution. I'm using my normal editors, along with 'serve', a Ruby gem that runs a web server using WEBrick, and automatically compiles any files which it detects has changed. This includes HAML, Sass, Slim, Markdown, etc. files. I'm going to be using either Coda's live preview, or the minimalist browser called Playground, which eliminates the need to press refresh when the local file it is displaying changes.
This workflow is nice for now, although it doesn't have any built-in method to build the entire site into a static site when I'm done and want to deploy. This is a feature in middleman, but middleman still refuses to run because a dependency of it, thin, refuses to work on 64 bits. I might have to manually compile all the files using the terminal command, and hope the Haml interpreter can handle combining template files with each file, which I seriously doubt at this stage. This limitation and thus the continued dependence on 'serve' might force me to consider one of the other applications out there, listed on the page Haml Sucks for Content.

Related

is developing an HTML web app using Notepad++ secure

I have started on a web app for the ORG i work for, using notepad++ for html and css and of course php and javascript. I must say that the ORG did not used to have software developers, all software they have is off-the-shelf or oracle forms and am a recent grad.
We got a new hire he has much more experience "he claims", the thing is that he has been criticizing me for using notepad++ for html, he instead suggests using ASP.NET in VS. His argument comes from security risks and better support point of view.
The web app will consist of a website for the visitors to browse, in addition to an intranet for employees to use onsite and globally.
So i am not sure if i am on the right track and he is showing off, or i should be following his advice "he could be our new IT manager".
I thank you very much in advance.
The editor you are using has literally nothing to do with the security of the programmed application. Notepad++ is perfectly fine, even though i would recommend something like Atom, Visual Studio Code or Sublime.
One thing they have as a "security advantage" over Notepad++ is, that it is easier to install plugins that try to check your code and point out possible bugs. Otherwise blaming the Editor for Security issues is nonsense.
I have no experience with ASP.NET, i tried it a few times but never liked it. I think it comes with some authentication solutions out of the box.
HTML and CSS have very little to do with security. JavaScript and especially PHP is what you have to be careful with. I would recommend to use some kind of PHP framework as there are often well tested authentication components included. Frameworks I know of are Symfony and Laravel (which is built on Symfony).

Work with HTML coder

I am a rails backend developer and I am now working in a team with an HTML coder and I have some problems with information exchange.
I want him to generate all the HTML templates (haml, erb, whatever) and css files. But he has actually no clue on how to install ruby (and rails).
So, we are working now in this ugly workcycle when he puts all html's and css's in public, test them, and then I (myself) move them to correct place.
Is there a tool (for HTML codes) that mimics Rails rendering part so he will run this tool, which must be easy, and when the server starts, he can put all the templates to app/ and test them?
I see this as a small easy installable subset of rails, that only deal with page rendering.
If your coder still doesn't know how to install ruby or how to configure stuff for works , then I can say this is quite problematic . You either can try any cloud based IDE . Or , tools like git to get only raw stuff.
But , you also can look for someone who in minimum way will try to make the whole process possible by learning and installing ruby in their pc .
I had a similiar problem where a copywriter needed to play with the html and we ended up using Cloud9.
Cloud9 is a collaborative IDE in the cloud, IMHO It's pretty decent for small scale projects and can really get the job done.
I simply installed rails once and ran a local dev server and she did all the modifications and watced the preview.
Another option is to create a vagrant environment and preisntall rails there. This means the HTML coder would have to install a VM on his machine and run the vagrant there.

How to convert many HTML files to MediaWiki Pages on Windows?

I'm on Windows and I have an index.html in a folder and a huge set of html pages in subfolders.
How can I convert these html files to MediaWiki pages?
Check the Converting content from HTML text file section from the manual at mediawiki.org. Personally I would start with these two, and if that doesn't work I'd build something based on pywikibot. Any of these solutions can be made to work on Windows, though it is advisable to try it on Linux or OS X first, and if not install Cygwin.
You're unlikely to find any kind of streamlined GUI tool for such a specialized action. If you need more help with using the code available there you should hire a programmer or learn how to do it yourself.

How to customize buildbot web pages

I am trying to make some extra web pages for a test buildbot, since I am planning to have one running my project.
Practically I would like to have a waterfall page that show the button to build a specific builder, close to the build name, instead than in the builder page only. I would also like to have some reference documents loaded from inside the builder work folder, and from other locations on the slave machine; using buttons to display or hide them.
I've looked at the manual and I do not see any info about how do you customize or create new html pages, that can leverage on the Buildbot features (like the templates already included with Buildbot do).
I have opened some pages, and see that there are some html files that actually has non-html code statements like
% macro
% for
And so on. I am not a web programmer so I am quite clueless about what should I look for. Tried to google the word macro for HTML and I just got a bunch of results related to Wiki customization; it does not look like it is Python language so I am quite lost.
Is there anyone that was successfully able to make custom pages for the buildbot, and could give me some pointers about what to learn?
Buildbot uses jinja2 for templating, the jinja2 homepage has some nice documentation. This is where the non-html statements come from. I found google's chromium buildbot to be a good starting point, when learning about buildbot customization.
http://buildbot.net/buildbot/docs/0.8.7/developer/webstatus.html
http://jinja.pocoo.org/docs
http://src.chromium.org/viewvc/chrome/trunk/tools/build/masters/master.chromium/templates/

Needed: Light and free HTML editor with source control support

We're not doing real web development. We get our HTMLs from our designers, and have our web app generate those HTMLs (with some specific content). Simply put, we don't use any major web development infrastructure (ASP, PHP, JSP etc). Having that said, we sometimes do need to edit HTML, JavaScript and CSS files, and I'm tired of using rocks and stones and having no proper backup. What I'm looking for is a rather simple editor that would handle those kinds of files, and most importantly - will support source control, and will be free (or very cheep).
I've been looking into Aptana, and it seems to be a bit of an overkill. It has a lot of features we can do without, and this makes it too heavy. VWD express is lighter, but has no source control integration. There are probably a million other HTML editors, but I couldn't find one that satisfies the basic requirements - relatively lightweight, supports source control and is (almost) free. Any suggestions?
Not exactly what you want but you could try and use Notepad++ combined with TortoiseSVN.
Eclipse is pretty good. It's also very popular among developers and can edit HTML.
Why is supporting source control a requirement? I find that the place for good source control is not in the editor. The editor just gets in the way and only implements a subset of functionality.
NetBeans can edit about anything, is free, cross-platform, and directly supports CVS, Subversion and Mercurial version control systems. It's not exactly lightweight, although it is lighter than any comparably featured competitors I'm aware of.
Pick your poison at Wikipedia's Comparison of HTML editors page.
The Revisionator is a cloud based html editor that has built in source control. It'll even do wysiwyg diffing and merging of different versions.