Skip to content

Commit

Permalink
Merge branch 'bug-550515' into development
Browse files Browse the repository at this point in the history
  • Loading branch information
James Socol committed Apr 13, 2010
2 parents bd3d5b8 + ba2a037 commit 1c6f3dc
Show file tree
Hide file tree
Showing 6 changed files with 42 additions and 12 deletions.
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,8 @@ settings_local.py
pip-log.txt
.coverage
coverage.xml
build.py
**-all.css
**-min.css
**-all.js
**-min.js
8 changes: 2 additions & 6 deletions apps/search/templates/form.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,8 @@
{% if advanced == '1' %}
{% set classes = 'advanced_search' %}
{% endif %}
{% set styles = ('css/search.css',) %}
{% set scripts = (
'js/jquery.min.js',
'js/jqueryui.min.js',
'js/search.js'
) %}
{% set styles = ('search',) %}
{% set scripts = ('search',) %}

{% block content %}
{% if advanced == '1' %}
Expand Down
2 changes: 1 addition & 1 deletion apps/search/templates/results.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{# vim: set ts=2 et sts=2 sw=2: #}
{% extends "common/base.html" %}
{% set title = _('Search') %}
{% set styles = ('css/search.css',) %}
{% set styles = ('search',) %}

{% block content %}
<div id="basic-search" class="search-refine">
Expand Down
3 changes: 3 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@
-e git://github.com/jsocol/flatqs.git@fc0b5d89cc78b894eaf73c48dde81d0f197c7a15#egg=flatqs
Jinja2==2.2.1
-e git://github.com/jbalogh/jingo.git@c73d2c55182301e6f3ce507fc9a17ea843fed24f#egg=jingo
-e git://github.com/jsocol/jingo-minify.git#egg=jingo-minify

GitPython==0.1.7
MySQL-python==1.2.3c1
python-memcached==1.45
Werkzeug==0.5.1
Expand Down
27 changes: 27 additions & 0 deletions settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,7 @@
'django.contrib.sites',
'django.contrib.messages',
'tower',
'jingo_minify',
'sumo',
'search',
)
Expand Down Expand Up @@ -194,6 +195,32 @@ def JINJA_CONFIG():
# to True
TOWER_ADD_HEADERS=True

# Bundles for JS/CSS Minification
MINIFY_BUNDLES = {
'css': {
'common': (
'css/main.css',
'css/sidebar.css',
),
'search': (
'css/search.css',
),
},
'js': {
'common': (
'js/mozilla-menu.js',
'js/jquery.min.js',
),
'search': (
'js/jqueryui.min.js',
'js/search.js',
),
},
}

JAVA_BIN = '/usr/bin/java'

#
# Directory storying myspell dictionaries (with trailing slash)
DICT_DIR = '/usr/share/myspell/'
# Path to a file with a list of custom words.
Expand Down
9 changes: 4 additions & 5 deletions templates/layout/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,9 @@

<link rel="shortcut icon" type="image/x-icon" href="{{ MEDIA_URL }}img/favicon.ico"/>

<link rel="stylesheet" href="{{ MEDIA_URL }}css/main.css"/>
<link rel="stylesheet" href="{{ MEDIA_URL }}css/sidebar.css"/>
{{ css('common') }}
{% for style in styles %}
<link rel="stylesheet" href="{{ MEDIA_URL }}{{ style }}"/>
{{ css(style) }}
{% endfor %}

</head>
Expand Down Expand Up @@ -54,9 +53,9 @@
</div>{# /#footer-contents #}
</div>{# /#footer #}

<script type="text/javascript" src="{{ MEDIA_URL }}js/mozilla-menu.js"></script>
{{ js('common') }}
{% for script in scripts %}
<script type="text/javascript" src="{{ MEDIA_URL }}{{ script }}"></script>
{{ js(script) }}
{% endfor %}

</body>
Expand Down

0 comments on commit 1c6f3dc

Please sign in to comment.