The official web site for Carpathian Mountain Outreach
CSS Ruby HTML JavaScript Shell
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
bin
data
environments
helpers
source
spec
.eslintrc.json
.gitignore
.haml-lint.yml
.rspec
.rubocop.yml
.ruby-version
.scss-lint.yml
.travis.yml
Gemfile
Gemfile.lock
LICENSE
README.md
config.rb
gulpfile.js
package.json

README.md

cmoproject.org

Build Status Dependency Status

cmoproject.org is the official web site for Carpathian Mountain Outreach, a short-term missions project hosted annually by Euro Team Outreach, Inc. in Western Ukraine.

This site was built using Middleman 4.

cmoproject.org screenshot

Requirements

Setup

To get started, clone the repo, cd into it, and run the setup script.

$ bin/setup

Development

This project uses Gulp with Middleman's new external_pipeline feature introduced in v4.

# Run the development server with Gulp
$ bundle exec middleman server

# Build the site (also invokes Gulp)
$ bundle exec middleman build

Environments

Middleman has two default environments: development and production. This app is configured to run the external pipeline (Gulp in our case) in both. There are times, however, when the external pipeline should not run. Two good examples are tests and the console. We therefore define two additional environments: test and console.

Custom environments can be invoked on the command line with -e flag like so:

# Start the console in the console enviroment
$ bundle exec middleman console -e console

Code for custom environments is stored in environments/<your-custom-env>.rb. Note that custom environments can be invoked without the existence of a corresponding file in the environments/ directory. If, for example, you merely wanted to start a server without the default development configs, you could run middleman server -e <anything-here>.

For completeness, all four environments used in this app have corresponding files:

environments/
├── console.rb
├── development.rb
├── production.rb
└── test.rb

Tests

Testing is done with Rspec. Run the tests like so:

$ bin/rspec spec/

Aliases

Consider adding the following to your .bashrc or .zshrc file:

mm='bundle exec middleman'
mmb='bundle exec middleman build --clean'
mmc='bundle exec middleman console -e console'
mms='bundle exec middleman server'

Deployment

cmoproject.org is currently deployed on Amazon S3. Detailed instructions are available from Amazon.

Acknowledgements

I got started with Middleman thanks to Chris Toomey of thoughtbot. His excellent introductory video on building static sites with Middleman and the accompanying sample application provided much of the inspiration for building this site.

Upgrading this site to v4 of Middleman was made much easier thanks to Craig Dennis. His YouTube video and accompanying GitHub repo clearly illustrate how to use Middleman with Gulp Starter as the asset pipeline.

Logo

Carpathian Mountain Outreach

The Carpathian Mountain Outreach logo is a trademark of Euro Team Outreach, Inc.

Legal

Site content is copyrighted (c) 2016 by Euro Team Outreach, Inc. Software is under the MIT license.