npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

grunt-compass-wrapper

v0.0.4

Published

Wrapper around the `compass` CLI tool.

Downloads

2

Readme

grunt-compass-wrapper

Build status

Build Status: Linux

Install

Install with npm

npm install grunt-compass-wrapper --save-dev

Tasks

Every options is the same for for each tasks.

compass-clean

Wrapper around the $ compass clean command.

Remove generated files and the sass cache.

Supported arguments

With the default options the

grunt compass-clean

is equivalent to

bundle exec compass clean

compass-compile

Wrapper around the $ compass compile command.

Compile Sass stylesheets to CSS.

Supported arguments

With the default options the

grunt compass-compile

is equivalent to

bundle exec compass complie

compass-validate

Wrapper around the $ compass validate command.

Validate your generated css.

Supported arguments

With the default options the

grunt compass-validate

is equivalent to

bundle exec compass validate

Options

rubyExecutable

Type: String

Default value: ''

bundleExecutable

Type: String

Default value: 'bundle'

bundleExec

Type: Boolean

Default value: true

compassExecutable

Type: String

Default value: 'compass'

arguments

Type: Object

Default value: {}

Different options than the default ones

grunt.initConfig({
  'compass-compile': {
    options: {
      rubyExecutable: '/home/foo/.rvm/rubies/ruby-2.1.3/bin/ruby',
      bundleExecutable: '/home/foo/.rvm/gems/ruby-2.1.3/bin/bundle',
      arguments: {
        boring: true
      }
    },
    'my-01': {
      files: {
        src: ['**/config.rb']
      }
    },
    'my-02': {
      options: {
        rubyExecutable: '',
        bundleExecutable: '',
        arguments: {
          boring: false,
          environment: 'production'
        }
      },
      files: {
        src: ['**/config.rb']
      }
    }
  }
});
grunt compass-compile:my-01
echo 'is equivalent to'
/home/foo/.rvm/rubies/ruby-2.1.3/bin/ruby /home/foo/.rvm/gems/ruby-2.1.3/bin/bundle exec compass compile --boring
grunt compass-compile:my-02
echo 'is equivalent to'
bundle exec compass compile --environment production 

Arguments

All argument is same as the CLI counterpart. You can check them with the $ compass {clean|compile|validate} --help command.

require

Type: Object

Default value: {}

Key-value pairs where the key is the desired library and the value is false or true.

grunt.initConfig({
  'compass-compile': {
    options: {
      arguments: {
        require: {
          'path/to/gem-01': true,
          'path/to/gem-02': true,
          'path/to/gem-03': true
        }
      }
    },
    'my-target-01': {
      options: {
        arguments: {
          require: {
            'path/to/gem-02': false
          }
        }
      }
    }
  }
});
compass-compile --require 'path/to/gem-01' --require 'path/to/gem-03'

sourceMap

Type: Boolean

Default value: null

debugInfo

Type: Boolean

Default value: null

load

Type: String

Default value: ''

loadAll

Type: String

Default value: ''

importPath

Type: String

Default value: ''

quiet

Type: Boolean

Default value: false

trace

Type: Boolean

Default value: false

boring

Type: Boolean

Default value: false

config

Type: String

Default value: ''

app

Type: String

Default value: ''

appDir

Type: String

Default value: ''

sassDir

Type: String

Default value: ''

cssDir

Type: String

Default value: ''

imagesDir

Type: String

Default value: ''

javascriptDir

Type: String

Default value: ''

fontsDir

Type: String

Default value: ''

environment

Type: String

Default value: ''

outputStyle

Type: String

Default value: ''

relativeAssets

Type: Boolean

Default value: false

noLineComments

Type: Boolean

Default value: false

httpPath

Type: String

Default value: ''

generatedImagesPath

Type: String

Default value: ''

Flags

You can modify the arguments by Flags

Flag - quiet

Override the value of quiet argument with true.

Flag - trace

Override the value of trace argument with true.

Flag - force

Override the value of force argument with true.

Flag - boring

Override the value of boring argument with true.

Flag - development

Override the value of environment argument with 'development'.

Flag - production

Override the value of environment argument with 'production'.

Flag - nested

Override the value of outputStyle argument with 'nested'.

Flag - expanded

Override the value of outputStyle argument with 'expanded'.

Flag - compact

Override the value of outputStyle argument with 'compact'.

Flag - compressed

Override the value of outputStyle argument with 'compressed'.

Flag - relative-assets

Override the value of relativeAssets argument with true.

Flag - no-line-comments

Override the value of noLineComments argument with true.

Examples

Example - Basic

require('jit-grunt')(
  grunt,
  // Mapping.
  {
    'compass-clean': 'grunt-compass-wrapper',
    'compass-compile': 'grunt-compass-wrapper',
    'compass-validate': 'grunt-compass-wrapper'
  }
);

grunt.initConfig({
  'compass-clean': {
    'my-01': {
      files: {
        src: ['./path/to/dir/config.rb']
      }
    }
  },
  'compass-compile': {
    'my-01': {
      files: {
        src: ['./path/to/dir/config.rb']
      }
    }
  },
  'compass-validate': {
    'my-01': {
      files: {
        src: ['./path/to/dir/config.rb']
      }
    }
  }
});

grunt.registerTask('scss-compile', [
  'compass-clean',
  'compass-compile',
  'compass-validate'
]);
grunt scss-compile
echo 'is equivalent to'
bundle exec compass clean
bundle exec compass compile
bundle exec compass validate

Example - Without bundle

grunt.initConfig({
  'compass-compile': {
    options: {
      bundleExec: false
    },
    'my-01': {
      files: {
        src: ['./path/to/dir/config.rb']
      }
    }
  }
});
grunt compass-compile
echo 'is equivalent to'
compass compile

Example - Arguments

grunt.initConfig({
  'compass-compile': {
    options: {
      arguments: {
        environment: 'development',
        outputStyle: 'nested'
      }
    },
    'my-01': {
      files: {
        src: ['./path/to/dir/config.rb']
      }
    }
  }
});
grunt compass-compile
echo 'is equivalent to'
bundle exec compass compile --environment 'development' --output-style 'nested'

Example - Arguments and flags

grunt.initConfig({
  'compass-compile': {
    options: {
      arguments: {
        environment: 'development',
        outputStyle: 'nested'
      }
    },
    'my-01': {
      files: {
        src: ['./path/to/dir/config.rb']
      }
    }
  }
});

grunt.registerTask('scss-compile-prod', [
  'compass-compile:my-01:production:compressed'
]);
grunt compass-compile:my-01
echo 'is equivalent to'
bundle exec compass compile --environment 'development' --output-style 'nested'
grunt compass-compile:my-01:production:compressed
echo 'is equivalent to'
grunt scss-compile-prod
echo 'is equivalent to'
bundle exec compass compile --environment 'production' --output-style 'compressed'

Author

Andor Dávid

Release History

  • v0.0.4 2015-05-24
    • Improved documentation
  • v0.0.3 2015-05-22
    • Nobody knows
  • v0.0.2 2015-05-18
    • Flag support

License

Copyright (c) 2015 Andor Dávid, contributors.


This file was generated by grunt-verb on May 24, 2015.