Compare commits
7 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 2686e96046 | |||
| 213e2bb432 | |||
| 79bb5c10ab | |||
| 7ea012d786 | |||
| 43591f75de | |||
| 05d82c0569 | |||
| 76c8d3206c |
@@ -532,9 +532,9 @@ Your Rack middleware can pass author details to Gollum in a Hash in the session
|
|||||||
## WINDOWS FILENAME VALIDATION
|
## WINDOWS FILENAME VALIDATION
|
||||||
Note that filenames on windows must not contain any of the following characters `\ / : * ? " < > |`. See [this support article](http://support.microsoft.com/kb/177506) for details.
|
Note that filenames on windows must not contain any of the following characters `\ / : * ? " < > |`. See [this support article](http://support.microsoft.com/kb/177506) for details.
|
||||||
|
|
||||||
## LIB.SO ERROR
|
## CONFIG FILE
|
||||||
|
|
||||||
`Could not open library 'lib.so'` may be solved by installing `python-devel` on Fedora or `python-dev` on Ubuntu. Gentoo requires a rubypython [patch](https://gist.github.com/2802480) to use python2.7.
|
Gollum optionaly takes a `--config file`. See [config.rb](https://github.com/github/gollum/blob/master/config.rb) for an example.
|
||||||
|
|
||||||
## CONTRIBUTE
|
## CONTRIBUTE
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,28 @@
|
|||||||
|
# Example gollum config
|
||||||
|
# gollum ../wiki --config config.rb
|
||||||
|
#
|
||||||
|
# or run from source with
|
||||||
|
#
|
||||||
|
# bundle exec bin/gollum ../wiki/ --config config.rb
|
||||||
|
|
||||||
|
# Remove const to avoid
|
||||||
|
# warning: already initialized constant FORMAT_NAMES
|
||||||
|
#
|
||||||
|
# only remove if it's defined.
|
||||||
|
# constant Gollum::Page::FORMAT_NAMES not defined (NameError)
|
||||||
|
Gollum::Page.send :remove_const, :FORMAT_NAMES if defined? Gollum::Page::FORMAT_NAMES
|
||||||
|
# limit to one format
|
||||||
|
Gollum::Page::FORMAT_NAMES = { :markdown => "Markdown" }
|
||||||
|
|
||||||
|
=begin
|
||||||
|
Valid formats are:
|
||||||
|
{ :markdown => "Markdown",
|
||||||
|
:textile => "Textile",
|
||||||
|
:rdoc => "RDoc",
|
||||||
|
:org => "Org-mode",
|
||||||
|
:creole => "Creole",
|
||||||
|
:rest => "reStructuredText",
|
||||||
|
:asciidoc => "AsciiDoc",
|
||||||
|
:mediawiki => "MediaWiki",
|
||||||
|
:pod => "Pod" }
|
||||||
|
=end
|
||||||
+3
-2
@@ -5,8 +5,8 @@ Gem::Specification.new do |s|
|
|||||||
s.required_ruby_version = ">= 1.8.7"
|
s.required_ruby_version = ">= 1.8.7"
|
||||||
|
|
||||||
s.name = 'gollum'
|
s.name = 'gollum'
|
||||||
s.version = '2.3.7'
|
s.version = '2.3.8'
|
||||||
s.date = '2012-11-06'
|
s.date = '2012-11-07'
|
||||||
s.rubyforge_project = 'gollum'
|
s.rubyforge_project = 'gollum'
|
||||||
|
|
||||||
s.summary = "A simple, Git-powered wiki."
|
s.summary = "A simple, Git-powered wiki."
|
||||||
@@ -53,6 +53,7 @@ Gem::Specification.new do |s|
|
|||||||
README.md
|
README.md
|
||||||
Rakefile
|
Rakefile
|
||||||
bin/gollum
|
bin/gollum
|
||||||
|
config.rb
|
||||||
docs/sanitization.md
|
docs/sanitization.md
|
||||||
gollum.gemspec
|
gollum.gemspec
|
||||||
lib/gollum.rb
|
lib/gollum.rb
|
||||||
|
|||||||
+1
-1
@@ -23,7 +23,7 @@ require File.expand_path('../gollum/web_sequence_diagram', __FILE__)
|
|||||||
require File.expand_path('../gollum/frontend/uri_encode_component', __FILE__)
|
require File.expand_path('../gollum/frontend/uri_encode_component', __FILE__)
|
||||||
|
|
||||||
module Gollum
|
module Gollum
|
||||||
VERSION = '2.3.7'
|
VERSION = '2.3.8'
|
||||||
|
|
||||||
def self.assets_path
|
def self.assets_path
|
||||||
::File.expand_path('gollum/frontend/public', ::File.dirname(__FILE__))
|
::File.expand_path('gollum/frontend/public', ::File.dirname(__FILE__))
|
||||||
|
|||||||
@@ -212,4 +212,20 @@ $(document).ready(function() {
|
|||||||
$('#gollum-revert-form').submit();
|
$('#gollum-revert-form').submit();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if( $('#wiki-wrapper.edit').length ){
|
||||||
|
$("#gollum-editor-submit").click( function() { window.onbeforeunload = null; } );
|
||||||
|
$("#gollum-editor-body").one('change', function(){
|
||||||
|
window.onbeforeunload = function(){ return "Leaving will discard all edits!" };
|
||||||
|
});
|
||||||
|
$.GollumEditor();
|
||||||
|
}
|
||||||
|
|
||||||
|
if( $('#wiki-wrapper.create').length ){
|
||||||
|
$("#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}}' });
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<div id="wiki-wrapper">
|
<div id="wiki-wrapper" class="create">
|
||||||
<div id="head">
|
<div id="head">
|
||||||
<h1>Create New Page</h1>
|
<h1>Create New Page</h1>
|
||||||
</div>
|
</div>
|
||||||
@@ -8,13 +8,5 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<script type="text/javascript">
|
|
||||||
window.onbeforeunload = function(){ return "Leaving will not create a new page!" };
|
|
||||||
$("#gollum-editor-submit").click( function() { window.onbeforeunload = null; } );
|
|
||||||
|
|
||||||
jQuery(document).ready(function() {
|
|
||||||
$.GollumEditor({ NewFile: true, MarkupType: '{{default_markup}}' });
|
|
||||||
});
|
|
||||||
</script>
|
|
||||||
|
|
||||||
{{something}}
|
{{something}}
|
||||||
|
|||||||
@@ -10,11 +10,3 @@
|
|||||||
</div>
|
</div>
|
||||||
<div id="wiki-content">{{>editor}}</div>
|
<div id="wiki-content">{{>editor}}</div>
|
||||||
</div>
|
</div>
|
||||||
<script type="text/javascript">
|
|
||||||
window.onbeforeunload = function(){ return "Leaving will discard all edits!" };
|
|
||||||
$("#gollum-editor-submit").click( function() { window.onbeforeunload = null; } );
|
|
||||||
|
|
||||||
jQuery(document).ready(function() {
|
|
||||||
$.GollumEditor();
|
|
||||||
});
|
|
||||||
</script>
|
|
||||||
|
|||||||
+2
-2
@@ -181,8 +181,8 @@ module Gollum
|
|||||||
self.class.default_ws_subs
|
self.class.default_ws_subs
|
||||||
@history_sanitization = options[:history_sanitization] ||
|
@history_sanitization = options[:history_sanitization] ||
|
||||||
self.class.history_sanitization
|
self.class.history_sanitization
|
||||||
@live_preview = options.fetch(:live_preview, true)
|
@live_preview = options[:live_preview] || true
|
||||||
@universal_toc = options.fetch(:universal_toc, false)
|
@universal_toc = options[:universal_toc] || false
|
||||||
@mathjax = options[:mathjax] || false
|
@mathjax = options[:mathjax] || false
|
||||||
@show_all = options[:show_all] || false
|
@show_all = options[:show_all] || false
|
||||||
@collapse_tree = options[:collapse_tree] || false
|
@collapse_tree = options[:collapse_tree] || false
|
||||||
|
|||||||
Reference in New Issue
Block a user