linemanjs / lineman

Lineman helps you build fat-client JavaScript apps. It produces happiness by building assets, mocking servers, running specs on every file change
MIT License
1.18k stars 80 forks source link

enableSass halts booting #228

Closed olimart closed 10 years ago

olimart commented 10 years ago

As per the docs. I uncomment enableSass: true

then I run lineman run but I get

/Code/_exp/my-lineman-app/config/application.js:48
    enableSass: true
    ^^^^^^^^^^
Loading "Gruntfile.js" tasks...ERROR
>> SyntaxError: Unexpected identifier
Warning: Task "common" not found. Used --force, continuing.
Warning: Task "dev" not found. Used --force, continuing.

Done, but with warnings.

Any idea?

jraede commented 10 years ago

What does your full application.js file look like? My guess is you're missing a comma after enableSass:true

olimart commented 10 years ago

Hi @jraede thanks for the quick reply. Here is my application.js file. I tried to add coma, semicolon or nothing but same result.

/* Exports a function which returns an object that overrides the default &
 *   plugin grunt configuration object.
 *
 * You can familiarize yourself with Lineman's defaults by checking out:
 *
 *   - https://github.com/linemanjs/lineman/blob/master/config/application.coffee
 *   - https://github.com/linemanjs/lineman/blob/master/config/plugins
 *
 * You can also ask Lineman's about config from the command line:
 *
 *   $ lineman config #=> to print the entire config
 *   $ lineman config concat.js #=> to see the JS config for the concat task.
 */
module.exports = function(lineman) {
  //Override application configuration here. Common examples follow in the comments.
  return {
    // grunt-angular-templates assumes your module is named "app", but
    // you can override it like so:
    //
    // ngtemplates: {
    //   options: {
    //     module: "myModuleName"
    //   }
    // }

    server: {
      pushState: true
      // API Proxying
      //
      // During development, you'll likely want to make XHR (AJAX) requests to an API on the same
      // port as your lineman development server. By enabling the API proxy and setting the port, all
      // requests for paths that don't match a static asset in ./generated will be forwarded to
      // whatever service might be running on the specified port.
      //
      // apiProxy: {
      //   enabled: true,
      //   host: 'localhost',
      //   port: 3000
      // }
    }

    // Sass
    //
    // Lineman supports Sass via grunt-contrib-sass, which requires you first
    // have Ruby installed as well as the `sass` gem. To enable it, comment out the
    // following line:
    //
    enableSass: true,

    // sass: {
    //   options: {
    //     bundleExec: true
    //   }
    // }

    // Asset Fingerprints
    //
    // Lineman can fingerprint your static assets by appending a hash to the filename
    // and logging a manifest of logical-to-hashed filenames in dist/assets.json
    // via grunt-asset-fingerprint
    //
    // enableAssetFingerprint: true

  };
};
jraede commented 10 years ago

You're missing a comma after the server section. Right before // Sass, you need a comma after the closing curly bracket. And you also shouldn't have a comma after enableSass:true since it's the last entry.

olimart commented 10 years ago

@jraede Thanks for your help