Execute Grunt-Sass in a GitHub Action

Viewed 51

I'm trying to publish a Blazor WASM in an Azure Static Web App with a GitHub Action.

This application uses a custom Bootstrap stylesheet, generated by grunt-contrib-sass npm module.

Grunt Contrib Sass requires Ruby and Sass to build my stylesheet. It works on my computer. But not in a GitHub Action. I've this error:

Running "sass:dist" (sass) task
Verifying property sass.dist exists in config...OK
Files: wwwroot/scss/galerie-renovation.scss -> wwwroot/css/galerie-renovation.css
Options: (none)
Warning: 
You need to have Ruby and Sass installed and in your PATH for this task to work.
More info: https://github.com/gruntjs/grunt-contrib-sass
 Use --force to continue.

Aborted due to warnings.

I've tried to setup ruby 2.7 with a dedicated job, a step in my build_and_deploy_job and with a npm package.

It's a public repository; You can view the project (code, Actions and logs) in my GitHub repository: https://github.com/andrestalavera/galerie-renovation

For the moment, the workaround that I've found consist to don't ignore generated files in my .gitignore file.

But I want to generate in my GitHub Action... Is it possible at least?

I've seen these resources:

0 Answers
Related