Compare commits

..

7 Commits

Author SHA1 Message Date
bootstraponline b08b97bd28 Release 2.3.11 2012-11-07 20:18:43 -07:00
bootstraponline dbb6ce2f71 Fix #570
Error in gollum.js broke new page button.
2012-11-07 20:17:50 -07:00
bootstraponline f66f14b593 Release 2.3.10 2012-11-07 19:47:09 -07:00
bootstraponline 8a52315dee Add base url to custom css 2012-11-07 19:46:27 -07:00
bootstraponline 7c4052906c Add custom css 2012-11-07 19:40:52 -07:00
bootstraponline 3a56f39f6a Fix readme 2012-11-07 19:17:49 -07:00
bootstraponline 6585ca5dd0 Fix space 2012-11-07 19:13:57 -07:00
9 changed files with 29 additions and 5 deletions
+9 -1
View File
@@ -534,7 +534,15 @@ Note that filenames on windows must not contain any of the following characters
## CONFIG FILE
Gollum optionaly takes a `--config file`. See [config.rb](https://github.com/github/gollum/blob/master/config.rb) for an example.
Gollum optionally takes a `--config file`. See [config.rb](https://github.com/github/gollum/blob/master/config.rb) for an example.
## CUSTOM CSS
The `--css` flag will inject `custom.css` from the root of your git repository into each page. Here's an example of floating the sidebar to the left.
```css
#wiki-rightbar { float: left !important; }
```
## CONTRIBUTE
+4
View File
@@ -45,6 +45,10 @@ opts = OptionParser.new do |opts|
options['irb'] = true
end
opts.on("--css", "Inject custom css. Uses custom.css from root repository") do
wiki_options[:css] = true
end
opts.on("--page-file-dir [PATH]", "Specify the sub directory for all page files (default: repository root).") do |path|
wiki_options[:page_file_dir] = path
end
+1 -1
View File
@@ -5,7 +5,7 @@ Gem::Specification.new do |s|
s.required_ruby_version = ">= 1.8.7"
s.name = 'gollum'
s.version = '2.3.9'
s.version = '2.3.11'
s.date = '2012-11-07'
s.rubyforge_project = 'gollum'
+1 -1
View File
@@ -23,7 +23,7 @@ require File.expand_path('../gollum/web_sequence_diagram', __FILE__)
require File.expand_path('../gollum/frontend/uri_encode_component', __FILE__)
module Gollum
VERSION = '2.3.9'
VERSION = '2.3.11'
def self.assets_path
::File.expand_path('gollum/frontend/public', ::File.dirname(__FILE__))
+2
View File
@@ -238,6 +238,7 @@ module Precious
@content = @page.formatted_data
@toc_content = wiki.universal_toc ? @page.toc_data : nil
@mathjax = wiki.mathjax
@css = wiki.css
@editable = false
mustache :page
end
@@ -360,6 +361,7 @@ module Precious
@content = page.formatted_data
@toc_content = wiki.universal_toc ? @page.toc_data : nil
@mathjax = wiki.mathjax
@css = wiki.css
mustache :page
elsif file = wiki.file(fullpath)
content_type file.mime_type
@@ -225,7 +225,7 @@ $(document).ready(function() {
$("#gollum-editor-submit").click( function() { window.onbeforeunload = null; } );
$("#gollum-editor-body").one('change', function(){
window.onbeforeunload = function(){ return "Leaving will not create a new page!" };
)};
});
$.GollumEditor({ NewFile: true, MarkupType: '{{default_markup}}' });
}
});
@@ -6,6 +6,7 @@
<link rel="stylesheet" type="text/css" href="{{base_url}}/css/editor.css" media="all">
<link rel="stylesheet" type="text/css" href="{{base_url}}/css/dialog.css" media="all">
<link rel="stylesheet" type="text/css" href="{{base_url}}/css/template.css" media="all">
{{#css}}<link rel="stylesheet" type="text/css" href="{{base_url}}/custom.css" media="all">{{/css}}
<!--[if IE 7]>
<link rel="stylesheet" type="text/css" href="{{base_url}}/css/ie7.css" media="all">
+4
View File
@@ -80,6 +80,10 @@ module Precious
@mathjax
end
def css # custom css
@css
end
# Access to embedded metadata.
#
# Examples
+6 -1
View File
@@ -137,6 +137,10 @@ module Gollum
# Gets the boolean live preview value.
attr_reader :live_preview
# Injects custom css from custom.css in root repo.
# Defaults to false
attr_reader :css
# Public: Initialize a new Gollum Repo.
#
# path - The String path to the Git repository that holds the Gollum
@@ -186,11 +190,12 @@ module Gollum
@sanitization = options.fetch :sanitization, self.class.sanitization
@ws_subs = options.fetch :ws_subs, self.class.default_ws_subs
@history_sanitization = options.fetch :history_sanitization, self.class.history_sanitization
@live_preview = options.fetch :live_preview, true
@live_preview = options.fetch :live_preview, true
@universal_toc = options.fetch :universal_toc, false
@mathjax = options.fetch :mathjax, false
@show_all = options.fetch :show_all, false
@collapse_tree = options.fetch :collapse_tree, false
@css = options.fetch :css, false
end
# Public: check whether the wiki's git repo exists on the filesystem.