Last active
July 11, 2020 01:08
-
-
Save neerajsingh0101/c09a2346fdce525a770cd8729bb19926 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<% branch_name = `git symbolic-ref HEAD 2>/dev/null`.chomp.sub('refs/heads/', '') %> | |
<% repository_name = `git rev-parse --show-toplevel`.split('/').last.strip %> | |
default: &default | |
adapter: postgresql | |
encoding: unicode | |
host: localhost | |
pool: 5 | |
password: | |
development: | |
<<: *default | |
database: <%= "#{repository_name}_development" %> | |
test: | |
<<: *default | |
database: <%= "#{repository_name}_test" %> | |
staging: | |
<<: *default | |
database: <%= "#{repository_name}_staging" %> | |
production: | |
<<: *default | |
database: <%= "#{repository_name}_production" %> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment