Views like index.php, single.php, header.php, footer.php, etc are all created using the HAML files located in the app/views directory.
Styles are compiled from SASS files found in the
app/assets/scripts_to_compile directory will be compiled into one manifest file, with jQuery placed before anything else. Scripts inside of
app/assets/scripts_uncompiled will just be copied to the
/scripts folder in the theme.
All other assets are copied from their respective assets folder to the appropriate theme directory.
After compilation, the theme is stored in the
/theme directory. You can change this directory by editing the
make file. See the "Usage" section for a better way - symbolic linking the /theme directory to your local server
Dependencies, Installation, Usage
We are using the amazing Multi-Target HAML compiler to render PHP along with some custom regexes to strip out anything that would normally be compiled at runtime.
./install to install fswatcher, which the package uses to watch the /app directory for changes and recompile the theme. You may need to run
chmod +x install to give it the correct permissions before you run it.
Start the watcher by typing
./watch. You may need to run
chmod +x watch to give it the correct permissions before you run it. Edit HAML, SASS, and PHP files and save them to recompile the theme.
You may want to symbolic link the /theme directory to wherever your serving your blog from locally. For instance, if you're using MAMP:
sudo ln -s ~/dev/wordpress-haml-sass/theme/ /Applications/MAMP/htdocs/wp-content/themes/theme
Contributions, Authors, Props
Are happily accepted if they're in the general spirit of the project. Just send a pull request. Also file an issue if you notice any weirdness!
Zach Feldman @zachfeldman
Ian Jennings (Watcher Implementation) @sw1tch