1
Fork 0

Fix CI error (4)

master
Vladimir Hodakov 2018-10-28 20:51:58 +04:00
parent 750e5ea21f
commit 003de0bbb1
Signed by: Vladimir Hodakov
GPG Key ID: 673980B6882F82C6
2 changed files with 16 additions and 3 deletions

View File

@ -12,8 +12,8 @@ before_script:
build site:
stage: build
script:
- bundle exec jekyll build -d public
- bundle exec jekyll build -d lorchess.ru
artifacts:
expire_in: 1 month
paths:
- public
- lorchess.ru

View File

@ -4,7 +4,20 @@ module Jekyll
safe true
priority :low
include I18nFilter
LOCALE = :ru
def localize(input, format=nil)
load_translations
format = (format =~ /^:(\w+)/) ? $1.to_sym : format
I18n.l input, :format => format
end
def load_translations
unless I18n::backend.instance_variable_get(:@translations)
I18n.backend.load_translations Dir[File.join(File.dirname(__FILE__), '../_locales/*.yml')]
I18n.locale = LOCALE
end
end
# Generates the reviews file
def generate(site)