title: Is there a way to change org-mode source code background color with the option `:body-only t`?
body: <p>I used <code>org-html-publish-to-html</code> to publish org to html, and use jekyll to build my blog. The problem is the background-color of the source code part is published to white by default and my blog theme is white too, so I cannot see the white code and I want to change the background color to dark.</p>
  
  <p>I had checked how to change this background color in both <a href="https://orgmode.org/worg/org-contrib/babel/examples/fontify-src-code-blocks.html" rel="nofollow noreferrer">Pretty fontification of source code blocks</a> and <a href="https://emacs.stackexchange.com/questions/3374/set-the-background-of-org-exported-code-blocks-according-to-theme">Set the background of org-exported code blocks according to theme</a>. </p>
  
  <p>At first, these two ways are both not worked. And then the I found out that, I need to add option <code>:body-only t</code> to use jekyll, and when I used this option, only code between <code>&lt;body&gt;&lt;/body&gt;</code> can be exported, but the color changed code is in html head.</p>
  
  <p>Here is my org publish setting:</p>
  
  <pre class="lang-lisp prettyprint-override"><code>(setq org-publish-project-alist
        '(("blog-org"
           :base-directory "~/Github/xxxxx"
           :base-extension "org"
           :publishing-directory "~/Github/xxxxx/_posts"
           :recursive t
           :publishing-function org-html-publish-to-html
           :html-head-extra "&lt;style type='text/css'&gt;pre.src {background-color: #969696;}&lt;/style&gt;"
           :with-toc nil
           :headline-levels 4
           :auto-preampble nil
           :auto-sitemap nil
           :html-extension "html"
           :body-only t
           )
          ("blog-static"
           :base-directory "~/Github/xxxxxx/org"
           :base-extension "css\\|js\\|png\\|jpg\\|gif\\|pdf\\|mp3\\|ogg\\|swf\\|php"
           :publishing-directory "~/Github/xxxxx/images"
           :recursive t
           :publishing-function org-publish-attachment
           )
          ("blog" :components ("blog-org" "blog-static"))))
  </code></pre>
  
  <p>And color changed code:</p>
  
  <pre class="lang-lisp prettyprint-override"><code>(custom-set-faces
   '(org-block-begin-line
     ((t (:underline "#A7A6AA" :foreground "#008ED1" :background "#EAEAFF"))))
   '(org-block
     ((t (:background "#969696"))))
   '(org-block-end-line
     ((t (:overline "#A7A6AA" :foreground "#008ED1" :background "#EAEAFF"))))
   )
  </code></pre>
  
  <p>I want to generate the html with dark background color with the publish setting above.</p>