1 new commit in galaxy-central: https://bitbucket.org/galaxy/galaxy-central/commits/363b639c2b48/ Changeset: 363b639c2b48 User: greg Date: 2013-10-04 20:51:42 Summary: Override the default Galaxy style for unordered lists in the Tool Shed so bullets points will display, and enhance tool config and readme file image declarations to allow for image files to be contained in a repository directory named something starting with the string 'http'. Affected #: 3 files diff -r 3cabb73f554e53064f6fb88234e2f535caa39bb4 -r 363b639c2b4816b566c38dde4dccd352a9e4f0ff lib/tool_shed/util/readme_util.py --- a/lib/tool_shed/util/readme_util.py +++ b/lib/tool_shed/util/readme_util.py @@ -68,6 +68,7 @@ encoding_errors='replace' ) text_of_reasonable_length = text_of_reasonable_length.render( static_path=web.url_for( '/static' ), host_url=web.url_for( '/', qualified=True ) ) + text_of_reasonable_length = unicodify( text_of_reasonable_length ) else: text_of_reasonable_length = suc.to_html_string( text_of_reasonable_length ) readme_files_dict[ readme_file_name ] = text_of_reasonable_length diff -r 3cabb73f554e53064f6fb88234e2f535caa39bb4 -r 363b639c2b4816b566c38dde4dccd352a9e4f0ff lib/tool_shed/util/shed_util_common.py --- a/lib/tool_shed/util/shed_util_common.py +++ b/lib/tool_shed/util/shed_util_common.py @@ -1523,10 +1523,11 @@ text = text.replace( './static/images', '' ) # Eliminate the default setting of /static/images since the routes will properly display images contained in that directory. text = text.replace( '/static/images', '' ) - # Use regex to instantiate routes into the defined image paths. + # Use regex to instantiate routes into the defined image paths, but replace paths that start with neither http:// nor https://, + # which will allow for settings like .. images:: http_files/images/help.png for match in re.findall( '.. image:: (?!http)/?(.+)', text ): text = text.replace( match, match.replace( '/', '%2F' ) ) - text = re.sub( '.. image:: (?!http)/?(.+)', '.. image:: %s/\\1' % route_to_images, text ) + text = re.sub( r'\.\. image:: (?!https?://)/?(.+)', r'.. image:: %s/\1' % route_to_images, text ) return text def set_only_if_compiling_contained_td( repository, required_repository ): diff -r 3cabb73f554e53064f6fb88234e2f535caa39bb4 -r 363b639c2b4816b566c38dde4dccd352a9e4f0ff templates/webapps/tool_shed/repository/common.mako --- a/templates/webapps/tool_shed/repository/common.mako +++ b/templates/webapps/tool_shed/repository/common.mako @@ -584,10 +584,7 @@ </%def><%def name="render_readme( readme, pad, parent, row_counter )"> - <% - encoded_id = trans.security.encode_id( readme.id ) - from galaxy.util import unicodify - %> + <% encoded_id = trans.security.encode_id( readme.id ) %><tr class="datasetRow" %if parent is not None: parent="${parent}" @@ -595,15 +592,7 @@ id="libraryItem-rr-${encoded_id}"><td style="padding-left: ${pad+20}px;"><table id="readme_files"> - <tr> - <td> - % if readme.name.endswith( '.rst' ): - ${ unicodify( readme.text ) } - %else: - ${ readme.text } - %endif - </td> - </tr> + <tr><td>${ readme.text }</td></tr></table></td></tr> @@ -689,6 +678,8 @@ word-break:keep-all; word-wrap:break-word; line-break:strict; } + ul{ list-style-type: disc; + padding-left: 20px; } </style></%def> @@ -1163,10 +1154,6 @@ </div> %endif %if tool_test_results_root_folder: - ##${render_table_wrap_style( "failed_test_table" )} - ##${render_table_wrap_style( "missing_table" )} - ##${render_table_wrap_style( "not_tested_table" )} - ##${render_table_wrap_style( "passed_tests_table" )} ${render_table_wrap_style( "test_environment" )} <p/><div class="toolForm"> Repository URL: https://bitbucket.org/galaxy/galaxy-central/ -- This is a commit notification from bitbucket.org. You are receiving this because you have the service enabled, addressing the recipient of this email.