Web-development – a resonable workflow for designing webapps

web-developmentworkflows

It has been a while since I have done any substantial web development and I'd like to take advantage of the latest practices but I'm struggling to visualize the workflow to incorporate everything.

Here's what I'm looking to use:

  • CakePHP framework
  • jsmin (JavaScript Minify)
  • SASS (Synctactically Awesome StyleSheets)
  • Git

CakePHP:

Pretty self explanatory, make modifications and update the source.

jsmin:

When you modify a script, do you manually run jsmin to output the new minified code, or would it be better to run a pre-commit hook that automatically generates jsmin outputs of javascript files that have changed. Assume that I have no knowledge of implementing commit hooks.

SASS:

I really like what SASS has to offer but I'm also aware that SASS code isn't supported by browsers by default so, at some point, the SASS code needs to be transformed to normal CSS. At what point in the workflow is this done.

Git

I'm terrified to admit it but, the last time I did any substantial web development, I didn't use SCM source control (IE, I did use source control but it consisted of a very detailed change log with backups).

I have since had plenty of experience using Git (as well as mercurial and SVN) for desktop development but I'm wondering how to best implement it for web development).

Is it common practice to implement a remote repository on the web host so I can push the changes directly to the production server, or is there some cross platform (windows/linux) tool that makes it easy to upload only changed files to the production server. Are there web hosting companies that make it eas to implement a remote repository, do I need SSH access, etc…

I know how to accomplish this on my own testing server with a remote repository with a separate remote tracking branch already but I've never done it on a remote production web hosting server before so I'm not aware of the options yet.

Extra:

I was considering implementing a javascript framework where separate javascript files used on a page are compiled into a single file for each page on the production server to limit the number of file downloads needed per page.

Does something like this already exist? Is there already an open source project out in the wild that implements something similar that I could use and contribute to?

Considering how paranoid web devs are about performance (and the fact that the number of file requests on a website is a big hit to performance) I'm guessing that there is some wizard hacker on the net who has already addressed this issue.

Best Answer

You could check out Google's PageSpeed extension for Apache: afaik, there is an option to aggregate and minify Javascript and CSS automatically and combined with caching, this would fit what you mention you're looking for at the end of your post.

Related Topic