How to edit twitter boot files in rails?

I am trying to find twitter-bootstrap files in my rails application ("bootstrap-sass", "2.0.0"), since I need to make changes directly to the bootstrap-responsive.css file, however, I cannot find it.

I have a reboot and startup, but I can not find the boot files. How to find bootstrap-responsive.css file?

Thanks!

+4
source share
2 answers

bootstap-sass stone uses Rails 3.2 asset pipelines to enter the necessary stylesheets into the application.The actual stylesheets are located in the gem installation directory, and not in your project.

Depending on what you want to change, you can:

  • Copy the _bootstrap-responsive.scss file from gem into your app/assets directory and edit it there.
  • Configure the necessary boot variables before loading Bootstrap into the application.scss file:

     $btnPrimaryBackground: #f00; @import "bootstrap"; 
+7
source

Edit: try searching under

 app/assets/stylesheets 

Here is an example

 https://github.com/joliss/solitr/tree/master/app/assets/stylesheets 

I'm not very good at rails application structure, but have you created a local copy or are you using bootstrap files hosted directly by github? You should understand this by checking one of your running html pages and looking at the source code, looking for something like

 <link rel="stylesheet" href="http://twitter.github.com/bootstrap/1.3.0/bootstrap.min.css"> 

If this is a local page, your rails application should have some kind of directory where the files are stored - maybe there is a static folder or something like that? Try searching for files so that you can find.

(I use Django / Python for web projects, but I will borrow Rails a bit and see if I can find anything)

0
source

Source: https://habr.com/ru/post/1414543/


All Articles