Giter VIP home page Giter VIP logo

Comments (7)

jessy1092 avatar jessy1092 commented on May 31, 2024

And the path of dest in gulp.dest(dest) would effect output result.

ex1.

build_path = '_public'
gulp.task 'sass', ->
  gulp.src './sass/*.sass'
    .pipe gulp-compass {sass: 'sass', css: "#{build_path}/css", sourcemap: true}
    .pipe gulp.dest "#{build_path}/css"

would be

  • sass
    • example.sass
  • _public
    • _public
      • css
        • example.css
    • css
      • example.css
      • example.css.map

ex2.

build_path = '_public'
gulp.task 'sass', ->
  gulp.src './sass/*.sass'
    .pipe gulp-compass {sass: 'sass', css: "#{build_path}/css", sourcemap: true}
    .pipe gulp.dest "#{build_path}"

would be

  • sass
    • example.sass
  • _public
    • css
      • example.css
      • example.css.map

It's strange.

In my expectation

build_path = '_public'
gulp.task 'sass', ->
  gulp.src './sass/*.sass'
    .pipe gulp-compass {sass: 'sass', css: "#{build_path}/css", sourcemap: true}
    .pipe gulp.dest "#{build_path}/css"

should be

  • sass
    • example.sass
  • _public
    • css
      • example.css
      • example.css.map

My env.

  • sass 3.4.5
  • compass 1.0.1
  • gulp 3.8.8
  • gulp-compass 1.3.3

from gulp-compass.

appleboy avatar appleboy commented on May 31, 2024

I will take it.

from gulp-compass.

boris-arkenaar avatar boris-arkenaar commented on May 31, 2024

I don't see why you have a _public folder inside a _public folder in example 1 jessy.

This is my situation:

gulp.src('./src/sass/*.sass')
.pipe(gulp-compass({
  project: '/project',
  sass: 'src/sass',
  css: 'build/compass'
}))
.pipe(gulp.dest('build/public/css'));
  • build
    • compass
      • style.css // Created by compass
    • public
      • css
        • style.css // gulp.dest should create this
  • src
    • sass
      • style.sass

The file stream gulp.dest receives from gulp-compass points to '../../build/compass/style.css' which is relative to 'src/sass' in stead of the project root.

My environment:

  • sass 3.4.5
  • compass 1.0.1
  • gulp 3.8.8
  • gulp-compass 1.3.3

So that's the same as yours jessy :)

from gulp-compass.

appleboy avatar appleboy commented on May 31, 2024

@Slotkenov Please update to 2.0.0

from gulp-compass.

appleboy avatar appleboy commented on May 31, 2024

@Slotkenov My test config using coffee-script

'use strict'

gulp = require 'gulp'
compass = require 'gulp-compass'
csso = require 'gulp-csso'

gulp.task 'default', ->
  gulp.src('src/sass/*')
    .pipe compass
      sass: 'src/sass'
      css: 'build/compass'
    .pipe gulp.dest 'build/css'
    .pipe csso()
    .pipe gulp.dest 'build/compress'

from gulp-compass.

boris-arkenaar avatar boris-arkenaar commented on May 31, 2024

Thanks a bunch, it is working again with version 2.0.0!

from gulp-compass.

appleboy avatar appleboy commented on May 31, 2024

@Slotkenov 👍

from gulp-compass.

Related Issues (20)

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.