- Requirements
- Installation of dependencies
- Building
- Serving the files with a local webserver
- Sublime Text
- nodejs,
On a mac fetch it with homebrew:
brew install node - gulp,
Install via npm if you don't have it:
npm install -g gulp - bower,
Install via npm if you don't have it:
npm install -g bower
Execute the following commands while in the package dir (package.json lies there):
npm installbower install
It will fetch a lot of gulp plugins, a ghost package and the inuitcss framework.
There are three main targets for building:
default(just rungulpwithout arguments), builds the complete theme and dumps tocontent/themes/dev/livereload(rungulp livereload) starts a file watcher and a livereload server, and a ghost demo instance. connect your browser to that server (or just depend on the inserted javascript shim) to get a live preview while editing templates or cssdist(rungulp dist) packs up the template indev-theme.zipand removes livereload and.mapfiles.
Just use the gulp task livereload:
gulp livereload
This will run a demo ghost instance on http://localhost:2368 (user template, email: example@example.com, password: template) with the dev-theme preselected.
If you're using Sublime Text, please open the template-dev project, it hides all things that are not neccessary for developing a template.
Furthermore it defines 2 build targets:
buildfor just compiling the templatepreviewfor running a ghost instance and enabling live reload for your browser