Skip to content

Commit 43ac885

Browse files
author
Nicolas Rodriguez
committed
Fix database creation
1 parent de46199 commit 43ac885

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

.travis.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@ services:
1818
addons:
1919
postgresql: '9.6'
2020
before_script:
21-
- mysql -e 'create database ajax_datatables_rails;'
22-
- psql -c 'create database ajax_datatables_rails;' -U postgres
21+
- sh -c "if [ '$DB_ADAPTER' = 'mysql2' ]; then mysql -e 'create database ajax_datatables_rails;'; fi"
22+
- sh -c "if [ '$DB_ADAPTER' = 'postgresql' ]; then psql -c 'create database ajax_datatables_rails;' -U postgres; fi"
2323
env:
2424
matrix:
2525
- DB_ADAPTER=postgresql

0 commit comments

Comments
 (0)