[fix] static file paths

This commit is contained in:
Adam Tauber 2015-01-01 17:54:33 +01:00
parent 9f12605f7e
commit 8151585918
7 changed files with 12 additions and 12 deletions

View File

@ -5,7 +5,7 @@ before_install:
- "export DISPLAY=:99.0"
- "sh -e /etc/init.d/xvfb start"
- npm install -g less grunt-cli
- ( cd searx/static/oscar;npm install )
- ( cd searx/static/themes/oscar;npm install )
install:
- "make"
- pip install coveralls

View File

@ -20,7 +20,7 @@ $(python):
tests: .installed.cfg
@bin/test
@grunt test --gruntfile searx/static/oscar/gruntfile.js
@grunt test --gruntfile searx/static/themes/oscar/gruntfile.js
robot: .installed.cfg
@bin/robot
@ -45,18 +45,18 @@ minimal: bin/buildout minimal.cfg setup.py
bin/buildout -c minimal.cfg $(options)
styles:
@lessc -x searx/static/default/less/style.less > searx/static/default/css/style.css
@lessc -x searx/static/oscar/less/bootstrap/bootstrap.less > searx/static/oscar/css/bootstrap.min.css
@lessc -x searx/static/oscar/less/oscar/oscar.less > searx/static/oscar/css/oscar.min.css
@lessc -x searx/static/themes/default/less/style.less > searx/static/themes/default/css/style.css
@lessc -x searx/static/themes/oscar/less/bootstrap/bootstrap.less > searx/static/themes/oscar/css/bootstrap.min.css
@lessc -x searx/static/themes/oscar/less/oscar/oscar.less > searx/static/themes/oscar/css/oscar.min.css
grunt:
@grunt --gruntfile searx/static/oscar/gruntfile.js
@grunt --gruntfile searx/static/themes/oscar/gruntfile.js
locales:
@pybabel compile -d searx/translations
clean:
@rm -rf .installed.cfg .mr.developer.cfg bin parts develop-eggs \
searx.egg-info lib include .coverage coverage searx/static/default/css/*.css
searx.egg-info lib include .coverage coverage searx/static/themes/default/css/*.css
.PHONY: all tests robot flake8 coverage production minimal styles locales clean

View File

@ -1,14 +1,14 @@
install dependencies
~~~~~~~~~~~~~~~~~~~~
run this command in the directory ``searx/static/oscar``
run this command in the directory ``searx/static/themes/oscar``
``npm install``
compile sources
~~~~~~~~~~~~~~~
run this command in the directory ``searx/static/oscar``
run this command in the directory ``searx/static/themes/oscar``
``grunt``

Binary file not shown.

View File

@ -16,7 +16,7 @@
*/
requirejs.config({
baseUrl: './static/oscar/js',
baseUrl: './static/themes/oscar/js',
paths: {
app: '../app'
}

View File

@ -116,7 +116,7 @@ $(document).ready(function(){
// TODO hack
// change default imagePath
L.Icon.Default.imagePath = "./static/oscar/img/map";
L.Icon.Default.imagePath = "./static/themes/oscar/img/map";
// init map
var map = L.map(leaflet_target);

View File

@ -49,7 +49,7 @@ class ViewsTestCase(SearxTestCase):
)
result = self.app.post('/', data={'q': 'test'})
self.assertIn(
'<h3 class="result_title"><img width="14" height="14" class="favicon" src="static/default/img/icons/icon_youtube.ico" alt="youtube" /><a href="http://second.test.xyz">Second <span class="highlight">Test</span></a></h3>', # noqa
'<h3 class="result_title"><img width="14" height="14" class="favicon" src="static/themes/default/img/icons/icon_youtube.ico" alt="youtube" /><a href="http://second.test.xyz">Second <span class="highlight">Test</span></a></h3>', # noqa
result.data
)
self.assertIn(