Skip to content

Instantly share code, notes, and snippets.

Created June 13, 2013 18:09
Show Gist options
  • Select an option

  • Save anonymous/5775950 to your computer and use it in GitHub Desktop.

Select an option

Save anonymous/5775950 to your computer and use it in GitHub Desktop.

Revisions

  1. @invalid-email-address Anonymous created this gist Jun 13, 2013.
    45 changes: 45 additions & 0 deletions Gruntfile.js
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,45 @@
    module.exports = function(grunt) {

    grunt.initConfig({

    // [other stuff...]

    compass: {
    options: {
    sassDir: 'sass',
    javascriptsDir: 'javascripts',
    fontsDir: 'fonts',
    outputStyle: 'compressed',
    environment: 'production'
    },
    rTheme: {
    options: {
    importPath: 'sass/r-only',
    httpPath: '/wp-content/themes/r/',
    cssDir: 'stylesheets',
    imagesDir: 'img'
    }
    },
    fTheme: {
    options: {
    importPath: '../f/sass/',
    cssDir: '../f/stylesheets',
    imagesDir: '../f/img',
    httpPath: '/wp-content/themes/f/'
    }
    }
    },
    setPHPConstant: {
    styles: {
    constant: 'R_STYLES_UPDATED',
    value: '<%= grunt.template.today("yyyymmddHHMMss") %>',
    file: 'functions.php'
    }
    },

    // [other stuff...]

    // Tasks
    grunt.registerTask('styles', ['compass', 'setPHPConstant:styles']);

    };