Skip to content

Instantly share code, notes, and snippets.

@joshuapaling
Created March 31, 2015 23:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save joshuapaling/d6816c2daf77acc45075 to your computer and use it in GitHub Desktop.
Save joshuapaling/d6816c2daf77acc45075 to your computer and use it in GitHub Desktop.
Rake task to rename .css.scss files to just .scss (the long extension is deprecated)
task :rename_css_scss do
files = Rake::FileList["app/assets/stylesheets/**/*.css.scss"]
files.each do |f|
new_name = f.gsub(/\.css\.scss/, '.scss')
sh "mv #{f} #{new_name}"
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment