Skip to content

Commit 9989371

Browse files
author
Guilhem MAS-PAITRAULT
committed
[Quickfix]Added rules to discover .sass files when compiling directories
1 parent 91dd2ab commit 9989371

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

sass.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -150,13 +150,14 @@ def compile_dirname(
150150
for dirpath, _, filenames in os.walk(search_path):
151151
filenames = [
152152
filename for filename in filenames
153-
if filename.endswith('.scss') and not filename.startswith('_')
153+
if filename.endswith('.scss') or filename.endswith('.sass')
154+
and not filename.startswith('_')
154155
]
155156
for filename in filenames:
156157
input_filename = os.path.join(dirpath, filename)
157158
relpath_to_file = os.path.relpath(input_filename, search_path)
158159
output_filename = os.path.join(output_path, relpath_to_file)
159-
output_filename = re.sub('.scss$', '.css', output_filename)
160+
output_filename = re.sub('.s[ac]ss$', '.css', output_filename)
160161
input_filename = input_filename.encode(fs_encoding)
161162
s, v, _ = compile_filename(
162163
input_filename, output_style, source_comments, include_paths,

0 commit comments

Comments
 (0)