Building a web design tool

I have been thinking a lot lately about building website templates to sell on different template marketplaces. However, my current workflow for designing and developing the front end is horrid. Mainly I am using sublime text or atom, and manually running SASS and CoffeeScript to compile to a media directory for use by the HTML files, which are in most cases at the moment, actually PHP files in my CodeIgniter views directory. If I am going to try and pump out some templates, I am going to need a better workflow than this. TEST

I think I want an online template creation tool.

What I am really thinking about is creating an online IDE of a sort that will automate a lot of my workflow, and easily allow me to test my designs while iterrating extremely quick. My current plan is to build a basic project structure that will be forced onto all template projects that create. This will be similar to the automated project management in VisualStudio for C++ and C# projects, which are still tons more flexible than I am planning for my project management. I am also considering making my own Package manager for managing my SASS and CoffeeScript/JavaScript files. I know that I can use bower, however it is overly complicated for what I am really trying to do, and doesn't manage the libraries exactly how I would like.

What I need to build first.