Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
node-sass
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
楚学文
node-sass
Commits
29871dea
Commit
29871dea
authored
Nov 05, 2014
by
Adeel Mujahid
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #515 from kevva/recursive-watch
Add ability to watch for files recursively
parents
491f5fc8
a214ae21
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
2 deletions
+6
-2
node-sass
bin/node-sass
+6
-2
No files found.
bin/node-sass
View file @
29871dea
...
@@ -23,6 +23,7 @@ var cli = meow({
...
@@ -23,6 +23,7 @@ var cli = meow({
''
,
''
,
'Options'
,
'Options'
,
' -w, --watch Watch a directory or file'
,
' -w, --watch Watch a directory or file'
,
' -r, --recursive Recursively watch directories or files'
,
' -o, --output Output CSS file'
,
' -o, --output Output CSS file'
,
' -x, --omit-source-map-url Omit source map URL comment from output'
,
' -x, --omit-source-map-url Omit source map URL comment from output'
,
' -i, --indented-syntax Treat data from stdin as sass code (versus scss)'
,
' -i, --indented-syntax Treat data from stdin as sass code (versus scss)'
,
...
@@ -39,6 +40,7 @@ var cli = meow({
...
@@ -39,6 +40,7 @@ var cli = meow({
boolean
:
[
boolean
:
[
'indented-syntax'
,
'indented-syntax'
,
'omit-source-map-url'
,
'omit-source-map-url'
,
'recursive'
,
'stdout'
,
'stdout'
,
'source-comments'
'source-comments'
],
],
...
@@ -54,7 +56,8 @@ var cli = meow({
...
@@ -54,7 +56,8 @@ var cli = meow({
o
:
'output'
,
o
:
'output'
,
w
:
'watch'
,
w
:
'watch'
,
x
:
'omit-source-map-url'
,
x
:
'omit-source-map-url'
,
c
:
'source-comments'
c
:
'source-comments'
,
r
:
'recursive'
},
},
default
:
{
default
:
{
'image-path'
:
''
,
'image-path'
:
''
,
...
@@ -145,7 +148,8 @@ function watch(options, emitter) {
...
@@ -145,7 +148,8 @@ function watch(options, emitter) {
dir
.
push
(
options
.
src
);
dir
.
push
(
options
.
src
);
dir
=
dir
.
map
(
function
(
d
)
{
dir
=
dir
.
map
(
function
(
d
)
{
return
isSassFile
(
d
)
?
d
:
path
.
join
(
d
,
'*.{sass,scss}'
);
var
glob
=
options
.
recursive
?
'**/*.{sass,scss}'
:
'*.{sass,scss}'
;
return
isSassFile
(
d
)
?
d
:
path
.
join
(
d
,
glob
);
});
});
gaze
.
add
(
dir
);
gaze
.
add
(
dir
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment