mathisonian / gulp-sass-bulk-import

gulp task to allow importing directories in your SCSS
MIT License
41 stars 11 forks source link

Keep original Sass file as is #22

Closed Benjamin-K closed 6 years ago

Benjamin-K commented 6 years ago

Description

The plugin works great, but it overrides the original sass-file and adds the direct path to the currently available files in a folder. If you will add some other files to the imported folder, bulkSass won't do anything any more because there are no globs.

How it currently works

The original file gets overridden so any further execution will not include new files.

@import 'folder/*';

becomes

@import '/path/to/folder/file1.scss';
@import '/path/to/folder/file2.scss';

so if you add a file3.scss to that folder afterwords, it will be ignored.

Expected behaviour

The original file should be kept as is (or even reverted to the original version after execution) so that any files that are added afterwards will be imported too.

Benjamin-K commented 6 years ago

Sorry, i mistakenly had .pipe(gulp.dest('path/to/scss')) which produced this output. All is working correct and i'll close this issue.