aboutsummaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--plugins/include_code.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/include_code.rb b/plugins/include_code.rb
index 93db78a3..ec72006c 100644
--- a/plugins/include_code.rb
+++ b/plugins/include_code.rb
@@ -38,7 +38,7 @@ module Jekyll
end
def render(context)
- code_dir = (context.registers[:site].config['code_dir'] || 'downloads/code')
+ code_dir = (context.registers[:site].config['code_dir'].sub(/^\//,'') || 'downloads/code')
code_path = (Pathname.new(context.registers[:site].source) + code_dir).expand_path
file = code_path + @file