1 new commit in galaxy-central:
https://bitbucket.org/galaxy/galaxy-central/changeset/424d407c67f7/
changeset: 424d407c67f7
user: inithello
date: 2012-11-13 19:56:59
summary: Fix for renaming repository.
affected #: 1 file
diff -r 447448028a2f7326fc452ee32055de5c58e822f6 -r 424d407c67f7ea4f830317b7ab033815415a5a3b lib/galaxy/webapps/community/controllers/repository.py
--- a/lib/galaxy/webapps/community/controllers/repository.py
+++ b/lib/galaxy/webapps/community/controllers/repository.py
@@ -1676,8 +1676,7 @@
# Change the entry in the hgweb.config file for the repository.
old_lhs = "repos/%s/%s" % ( repository.user.username, repository.name )
new_lhs = "repos/%s/%s" % ( repository.user.username, repo_name )
- new_rhs = "%s\n" % repo_dir
- trans.app.hgweb_config_manager.change_entry( old_lhs, new_lhs, new_rhs )
+ trans.app.hgweb_config_manager.change_entry( old_lhs, new_lhs, repo_dir )
# Change the entry in the repository's hgrc file.
hgrc_file = os.path.join( repo_dir, '.hg', 'hgrc' )
self.__change_repository_name_in_hgrc_file( hgrc_file, repo_name )
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.
1 new commit in galaxy-central:
https://bitbucket.org/galaxy/galaxy-central/changeset/3419a45c1f01/
changeset: 3419a45c1f01
user: greg
date: 2012-11-13 19:45:03
summary: Create a new, empty hgweb.config file if one isn't found in the configured location.
affected #: 2 files
diff -r 4471a94e8fbff8d8c165c58f0f76867500953b82 -r 3419a45c1f01790b3108d1726253fcb46feedbf4 lib/galaxy/webapps/community/app.py
--- a/lib/galaxy/webapps/community/app.py
+++ b/lib/galaxy/webapps/community/app.py
@@ -49,5 +49,6 @@
# Let the HgwebConfigManager know where the hgweb.config file is located.
self.hgweb_config_manager = self.model.hgweb_config_manager
self.hgweb_config_manager.hgweb_config_dir = self.config.hgweb_config_dir
+ print >> sys.stderr, "Tool shed hgweb.config file is: ", self.hgweb_config_manager.hgweb_config
def shutdown( self ):
pass
diff -r 4471a94e8fbff8d8c165c58f0f76867500953b82 -r 3419a45c1f01790b3108d1726253fcb46feedbf4 lib/galaxy/webapps/community/util/hgweb_config.py
--- a/lib/galaxy/webapps/community/util/hgweb_config.py
+++ b/lib/galaxy/webapps/community/util/hgweb_config.py
@@ -4,6 +4,11 @@
log = logging.getLogger( __name__ )
+new_hgweb_config_template = """
+[paths]
+
+"""
+
class HgWebConfigManager( object ):
def __init__( self ):
self.hgweb_config_dir = None
@@ -41,7 +46,13 @@
def hgweb_config( self ):
hgweb_config = os.path.join( self.hgweb_config_dir, 'hgweb.config' )
if not os.path.exists( hgweb_config ):
- raise Exception( "Required file %s does not exist - check config setting for hgweb_config_dir." % hgweb_config )
+ # We used to raise an exception here...
+ # raise Exception( "Required file %s does not exist - check config setting for hgweb_config_dir." % hgweb_config )
+ # ...but now we just log the missing file and create a new empty one.
+ log.debug( "Required file %s does not exist, so creating a new, empty file. Check your config setting for hgweb_config_dir." % hgweb_config )
+ hgweb_config_file = open( hgweb_config, 'wb' )
+ hgweb_config_file.write( new_hgweb_config_template )
+ hgweb_config_file.close()
return os.path.abspath( hgweb_config )
def make_backup( self ):
# Make a backup of the hgweb.config file.
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.
1 new commit in galaxy-central:
https://bitbucket.org/galaxy/galaxy-central/changeset/3024a86c0d0d/
changeset: 3024a86c0d0d
user: greg
date: 2012-11-12 22:39:49
summary: Move the important details to the begining of the new tool shed repository alert email template, and include the repository name in the email subject.
affected #: 1 file
diff -r 74a7bc65f1ed8bde40425d1823ad8761b6cdcea8 -r 3024a86c0d0d21b1a85ff1b91516f34f416bcfcb lib/galaxy/webapps/community/controllers/common.py
--- a/lib/galaxy/webapps/community/controllers/common.py
+++ b/lib/galaxy/webapps/community/controllers/common.py
@@ -25,25 +25,23 @@
log = logging.getLogger( __name__ )
new_repo_email_alert_template = """
-GALAXY TOOL SHED NEW REPOSITORY ALERT
------------------------------------------------------------------------------
-You received this alert because you registered to receive email when
-new repositories were created in the Galaxy tool shed named "${host}".
------------------------------------------------------------------------------
+Revision: ${revision}
+Change description:
+${description}
Repository name: ${repository_name}
+Uploaded by: ${username}
Date content uploaded: ${display_date}
-Uploaded by: ${username}
-
-Revision: ${revision}
-Change description:
-${description}
${content_alert_str}
-----------------------------------------------------------------------------
This change alert was sent from the Galaxy tool shed hosted on the server
"${host}"
+-----------------------------------------------------------------------------
+You received this alert because you registered to receive email when
+new repositories were created in the Galaxy tool shed named "${host}".
+-----------------------------------------------------------------------------
"""
email_alert_template = """
@@ -497,7 +495,8 @@
admin_users = trans.app.config.get( "admin_users", "" ).split( "," )
frm = email_from
if new_repo_alert:
- subject = "New Galaxy tool shed repository alert"
+ subject = "Galaxy tool shed alert for new repository named %s" % str( repository.name )
+ subject = subject[ :80 ]
email_alerts = []
for user in trans.sa_session.query( trans.model.User ) \
.filter( and_( trans.model.User.table.c.deleted == False,
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.