Themes

By on

Overview

In the latest build, I’ve added multiple themes support, finally, you can switch themes with just one command.

This is an experimental feature and may change until the feature stabilizes.

Installing Themes

The AMSF framework ships a default theme Curtana. You can also install as many themes as you like and switch to the one you prefer in any time.

Via Git (GitHub)

The easiest way to install new theme is via theme-add, the following command will install theme Curtana from its official repo amsf/amsf-curtana:

$ grunt theme-add --theme=curtana

If you’d install custom theme from other users, append --user in your command, the following command will install a new theme named bootstrap-sass from sparanoid/amsf-bootstrap-sass

$ grunt theme-add --theme=bootstrap-sass --user=sparanoid

Manually Install

You can also install themes manually. find an AMSF theme (Curtana, for example), download the package and uncompress all files to .amsf-cache/themes directory, the file structure should look like:

├── .amsf-cache/ (Almace Scaffolding cache directory)
|   ├── themes/
|   |   └── curtana/
|   |   |   └── assets/
|   |   |   └── includes/
|   |   |   └── layouts/
|   |   |   └── pages/
|   |   |   └── config.yml
└── _app/

Then execute the following command:

$ grunt activate --theme=curtana

You current theme will be backed up to .amsf-cache/themes/your-old-theme/ and the new theme curtana will be installed to the appropriate directories.

Upgrading Themes

You can update your current activated theme by the following command. The activated theme will be downloaded from GitHub automatically if there’s any update:

$ grunt theme-update

Please note that only themes added via GitHub can be updated.