Giter VIP home page Giter VIP logo

sinatra.github.com's Introduction

Sinatra Website / Documentation

This repo contains the Sinatra website and documentation sources published at http://sinatra.github.com/.

Working Locally

Grab the sources from GitHub:

$ git clone git://github.com/sinatra/sinatra.github.com.git
$ cd sinatra.github.com

Make sure you have the bundler gem installed on your machine:

$ gem install bundler

Install dependencies:

$ bundle install

Run the test server:

$ rake server

Changes are immediately available at:

http://localhost:4000/sinatra.github.com/

Sass / CSS

Gulp was set up to streamline your build process. Simply run:

$ gulp watch

gulp watch triggers a couple of processes:

  • After changes have been introduced in the _sass directory, it first builds uncompressed .css files from the corresponding .sass files and puts them into /css/development.
  • Gulp also watches any changes made directly made on .cssfiles in the /css/development directory.
  • In turn, these or any changes in /css/development will get compressed, prefixed and purified of any obsolete style declarations before being placed in their final destination at /css.
  • Your site is reloaded automatically using Browsersync which watches any changes to .css files in /css. No need to install any additional gimmicks.

That means Gulp is configured so that you can either work on .sass files in the /_sass directory or on .css files directly in the /css/development directory. The legacy styles are placed in there as well atm. That being said, if you want to introduce changes in /css/development, you need to create new filenames to avoid being overwritten when new versions of Sass files get built.

Contributing directly to one of the existing Sass partials or via new ones of your own would be the preferred option. After some refactoring, we want to only serve one authorative stylesheet (application.css) that imports all the Sass partials during the build process. It would be appreciated if you could introduce your changes in the indented Sass syntax. Not a friend of curlies and stuff.

Contributing

See GitHub's "Fork A Repo" for more information.

Creating Blog Posts

Blog posts are stored under the _posts directory. To create a new blog post and open your $EDITOR, use:

thor blog:new 'Blog Post Title'

This requires Thor:

$ gem install thor

Prebuilt Files

You will need thor, rdoc, haml and mislav's hanna gem to rebuild static files and the API docs:

$ gem install thor
$ gem install rdoc -v 2.3.0
$ gem install haml -v 2.0.4
$ gem install mislav-hanna --source=http://gems.github.com/

The prebuilt file sources are maintained under the sinatra and sinatra-book projects. To pull in the latest versions and build them:

rake pull build

The generated files under the "_includes" and "api" directories need to be committed after building. To regenerate and add those files to your index for the next commit:

rake regen

sinatra.github.com's People

Contributors

rkh avatar rtomayko avatar vis-kid avatar cypher avatar sr avatar kgrz avatar bmizerany avatar cschneid avatar randomecho avatar syd avatar karmi avatar gnandretta avatar nesquena avatar tannerburson avatar foca avatar zapnap avatar victori avatar mattwildig avatar scudelletti avatar akahn avatar lenary avatar nakajima avatar micahbrich avatar ai avatar trevorturk avatar tienle avatar mistersourcerer avatar funkaoshi avatar neall avatar prefork avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.