Unverified Commit 1d07af8d authored by Marek Szuba's avatar Marek Szuba Committed by GitHub
Browse files

Merge pull request #394 from Ensembl/ontology_sql_fix

The ontology schema patches have been moved from ensembl/misc_scripts…
parents 61442151 85446eb8
...@@ -285,7 +285,7 @@ foreach my $thing ( [ 'ensembl', 'core', 'table.sql' ], ...@@ -285,7 +285,7 @@ foreach my $thing ( [ 'ensembl', 'core', 'table.sql' ],
[ 'ensembl-funcgen', 'funcgen', 'table.sql' ], [ 'ensembl-funcgen', 'funcgen', 'table.sql' ],
[ 'ensembl-variation', 'variation', 'table.sql' ], [ 'ensembl-variation', 'variation', 'table.sql' ],
[ 'ensembl-production', 'production', 'table.sql' ], [ 'ensembl-production', 'production', 'table.sql' ],
[ 'ensembl', 'ontology', 'tables.sql' ] ) [ 'ols-ensembl-loader', 'ontology', 'tables.sql' ] )
{ {
my ($git_repo, $schema_type, $schema_file) = @{$thing}; my ($git_repo, $schema_type, $schema_file) = @{$thing};
...@@ -687,12 +687,7 @@ sub _sql_dir { ...@@ -687,12 +687,7 @@ sub _sql_dir {
$directories = curdir() unless $directories; $directories = curdir() unless $directories;
$git_dir = catdir($directories, updir(), updir()); $git_dir = catdir($directories, updir(), updir());
} }
my $sql_dir; my $sql_dir = rel2abs(canonpath( catdir( $git_dir, $git_repo, 'sql' ) ));
if ($schema_type eq 'ontology') {
$sql_dir = rel2abs(canonpath( catdir( $git_dir, $git_repo, 'misc-scripts', 'ontology', 'sql' ) ));
} else {
$sql_dir = rel2abs(canonpath( catdir( $git_dir, $git_repo, 'sql' ) ));
}
my $schema_location = catfile($sql_dir, $schema_file); my $schema_location = catfile($sql_dir, $schema_file);
if(! -f $schema_location) { if(! -f $schema_location) {
if($opt_verbose) { if($opt_verbose) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment