diff --git a/config.rb b/config.rb new file mode 100755 index 0000000..a6a6cd1 --- /dev/null +++ b/config.rb @@ -0,0 +1,12 @@ +#!/usr/local/bin/ruby +config = File.new("db.rb", "w") +config.print("require mysql\n") +print "hostname: " +hostname = gets +print "username: " +username = gets +print "password: " +password = gets +print "dbname: " +dbname = gets +config.print("my = Mysql.connect('" + hostname.strip + "', '" + username.strip + "', '" + password.strip + "', '" + dbname.strip + "')\n") diff --git a/db.rb b/db.rb deleted file mode 100644 index c18ba82..0000000 --- a/db.rb +++ /dev/null @@ -1,2 +0,0 @@ -require "mysql" -$my = Mysql.connect('localhost', 'dice', 'Yqv8JPzsYew34YY7', 'dieroller')