From 92f8786c5d0f2f81883d45ff9cca04e10f375525 Mon Sep 17 00:00:00 2001 From: Maxim Ivanov Date: Mon, 11 Dec 2017 18:11:18 -0500 Subject: [PATCH] use file suffix --- autoload/sass-colors.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/autoload/sass-colors.rb b/autoload/sass-colors.rb index a871024..35c2195 100644 --- a/autoload/sass-colors.rb +++ b/autoload/sass-colors.rb @@ -278,11 +278,11 @@ prefix_regex = /\/(?:stylesheets|sass|scss)\// -# suffix_regex = /\.(?:scss|sass|less)/ +suffix_regex = /\.(?:scss|sass|less)/ current_file = ARGV[0] -#$suffix = current_file[suffix_regex] -$suffix = ".*" +$suffix = current_file[suffix_regex] +# $suffix = ".*" current_dir = ARGV[0].sub(/\/[^\/]+$/,'') style_root_key = current_file[prefix_regex] if style_root_key