<commit_before>css-grid-generator
==================

Simple PHP script to generate CSS for a grid

## Installation

This will clone the repository into your bin directory and add a symbolic link
to the `cssgrid` script.

    $ cd ~/bin/
    $ git clone git://github.com/sumpygump/css-grid-generator.git
    $ ln -s css-grid-generator/cssgrid cssgrid

## Requirements

- PHP 5.3+

## Usage

    cssgrid --cols=12 --col-width=67 --gutter=16 --units=percent > grid.css

This will generate the CSS rules for a grid and put them in a file `grid.css`.

### Parameters

    --cols : number of columns
    --col-width : width in pixels of columns
    --gutter : width in pixels of gutter space between columns
    --units : output units (pixels or percent)

## Example Output

```css
/* ---------------------------------------------------------------------
 Grid

 Generated with cssgrid v0.8.1 at 2013-02-12 21:30:54 CST
 https://github.com/sumpygump/css-grid-generator
 cssgrid --units=percent --cols=12 --col-width=67 --gutter=16 --max-width=980

 ============================================
 Formulas used for calculation of grid values
 ============================================
 gutter      = (gutter / max-width) * 100
 col-width   = (((col-width * col-index) + (gutter * (col-index - 1)) / max-width) * 100
 col-push    = (((col-width * col-index) + (gutter * col-index)) / max-width) * 100
 col-pull    = (((col-width * col-index) + (gutter * col-index)) / max-width) * 100 * -1
 col-prefix  = (((col-width * col-index) + (gutter * col-index)) / max-width) * 100
 col-suffix  = (((col-width * col-index) + (gutter * col-index)) / max-width) * 100 * -1
------------------------------------------------------------------------ */
.grid:after {
    content: ".";
    display: block;
    height: 0;
    clear: both;
    visibility: hidden;
}

.grid-col {
    position: relative;
    float: left;
}

.grid-col + .grid-col {
    margin-left: 1.6326530612245%;
}

.grid-col_1of12 { width: 6.8367346938776%; }
.grid-col_2of12 { width: 15.30612244898%; }
.grid-col_3of12 { width: 23.775510204082%; }
.grid-col_4of12 { width: 32.244897959184%; }<commit_msg>updating docs to refelct change to the clearfix<commit_after>css-grid-generator
==================

Simple PHP script to generate CSS for a grid

## Installation

This will clone the repository into your bin directory and add a symbolic link
to the `cssgrid` script.

    $ cd ~/bin/
    $ git clone git://github.com/sumpygump/css-grid-generator.git
    $ ln -s css-grid-generator/cssgrid cssgrid

## Requirements

- PHP 5.3+

## Usage

    cssgrid --cols=12 --col-width=67 --gutter=16 --units=percent > grid.css

This will generate the CSS rules for a grid and put them in a file `grid.css`.

### Parameters

    --cols : number of columns
    --col-width : width in pixels of columns
    --gutter : width in pixels of gutter space between columns
    --units : output units (pixels or percent)

## Example Output

```css
/* ---------------------------------------------------------------------
 Grid

 Generated with cssgrid v0.8.1 at 2013-02-12 21:30:54 CST
 https://github.com/sumpygump/css-grid-generator
 cssgrid --units=percent --cols=12 --col-width=67 --gutter=16 --max-width=980

 ============================================
 Formulas used for calculation of grid values
 ============================================
 gutter      = (gutter / max-width) * 100
 col-width   = (((col-width * col-index) + (gutter * (col-index - 1)) / max-width) * 100
 col-push    = (((col-width * col-index) + (gutter * col-index)) / max-width) * 100
 col-pull    = (((col-width * col-index) + (gutter * col-index)) / max-width) * 100 * -1
 col-prefix  = (((col-width * col-index) + (gutter * col-index)) / max-width) * 100
 col-suffix  = (((col-width * col-index) + (gutter * col-index)) / max-width) * 100 * -1
------------------------------------------------------------------------ */
.grid:after {
    content: " ";
    display: block;
    height: 0;
    clear: both;
    visibility: hidden;
}

.grid-col {
    position: relative;
    float: left;
}

.grid-col + .grid-col {
    margin-left: 1.6326530612245%;
}

.grid-col_1of12 { width: 6.8367346938776%; }
.grid-col_2of12 { width: 15.30612244898%; }
.grid-col_3of12 { width: 23.775510204082%; }
.grid-col_4of12 { width: 32.244897959184%; }
{'fraction_non_alphanumeric': 0.2467741935483871, 'fraction_numerical': 0.06313364055299539, 'mean_word_length': 2.402037617554859, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2571777', 'n_tokens_mistral': 1571, 'n_tokens_neox': 1365, 'n_words': 385}