diff options
author | Louise Crow <louise.crow@gmail.com> | 2017-09-27 16:22:32 +0100 |
---|---|---|
committer | Louise Crow <louise.crow@gmail.com> | 2017-09-27 16:22:32 +0100 |
commit | 2bfe3de491ae721d5d57ddec3c0051108ce39c8f (patch) | |
tree | f7464c5cbb45e84aaddf6ae0eed6541b1a6f808f /lib | |
parent | 30f48c5d6c9b2f800e21eebb5a1dd56ff5241446 (diff) | |
parent | b927df66e39d66d38586467e3084579f0fbebc9f (diff) |
Merge branch 'release/0.30.0.0' into develop
Diffstat (limited to 'lib')
-rw-r--r-- | lib/alavetelitheme.rb | 14 | ||||
-rw-r--r-- | lib/config/custom-routes.rb | 4 | ||||
-rw-r--r-- | lib/views/general/_orglink.html.erb | 1 |
3 files changed, 16 insertions, 3 deletions
diff --git a/lib/alavetelitheme.rb b/lib/alavetelitheme.rb index 0658142..c472d34 100644 --- a/lib/alavetelitheme.rb +++ b/lib/alavetelitheme.rb @@ -45,6 +45,20 @@ $alaveteli_route_extensions << 'custom-routes.rb' Rails.application.config.assets.paths.unshift theme_asset_path end +# Append individual theme assets to the asset path +theme_asset_path = File.join(File.dirname(__FILE__), + '..', + 'app', + 'assets') +theme_asset_path = Pathname.new(theme_asset_path).cleanpath.to_s + +LOOSE_THEME_ASSETS = lambda do |logical_path, filename| + filename.start_with?(theme_asset_path) && + !['.js', '.css', ''].include?(File.extname(logical_path)) +end + +Rails.application.config.assets.precompile.unshift(LOOSE_THEME_ASSETS) + # Tell FastGettext about the theme's translations: look in the theme's # locale-theme directory for a translation in the first place, and if # it isn't found, look in the Alaveteli locale directory next: diff --git a/lib/config/custom-routes.rb b/lib/config/custom-routes.rb index 98fccf7..efbf95e 100644 --- a/lib/config/custom-routes.rb +++ b/lib/config/custom-routes.rb @@ -3,7 +3,7 @@ Rails.application.routes.draw do # brand new controller example - # match '/mycontroller' => 'general#mycontroller' + # get '/mycontroller' => 'general#mycontroller' # Additional help page example - # match '/help/help_out' => 'help#help_out' + # get '/help/help_out' => 'help#help_out' end diff --git a/lib/views/general/_orglink.html.erb b/lib/views/general/_orglink.html.erb deleted file mode 100644 index b22d123..0000000 --- a/lib/views/general/_orglink.html.erb +++ /dev/null @@ -1 +0,0 @@ -<%= link_to image_tag('old-logo.png', :alt => 'Alaveteli logo'), frontpage_url, :id=>'logo' %> |