Skip to content

Commit

Permalink
add message in cli for whether the MySQL version is already installed…
Browse files Browse the repository at this point in the history
… or not
  • Loading branch information
Sebastian-Webster committed Dec 3, 2024
1 parent 1532dbe commit 9ec97e0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@ async function main() {
}
console.log('Creating ephemeral MySQL database...')
const db = await createDB(options);
console.log(`A MySQL database has been successfully created with the following parameters:\n\nMySQL Version: ${db.mysql.version} \nUsername: ${db.username} \nDatabase Name: ${db.dbName} \nPort: ${db.port} \nX Plugin Port: ${db.xPort} \nSocket: ${db.socket} \nX Plugin Socket: ${db.xSocket}\n`)
const installedString = db.mysql.versionIsInstalledOnSystem ? 'This MySQL database is using the system-installed version of MySQL.' : 'This MySQl database is using a version of MySQL that is not already installed on this system and was downloaded from the MySQL CDN.'
console.log(`A MySQL database has been successfully created with the following parameters:\n\nMySQL Version: ${db.mysql.version} \n${installedString} \nUsername: ${db.username} \nDatabase Name: ${db.dbName} \nPort: ${db.port} \nX Plugin Port: ${db.xPort} \nSocket: ${db.socket} \nX Plugin Socket: ${db.xSocket}\n`)
if (process.platform === 'win32') {
//The connection information logs will be different for Windows compared to other platforms.
//Windows uses mysqlsh instead of mysql to invoke the client shell, needs a --sql flag to be put into SQL mode, and also does not have a protocol flag.
Expand Down

0 comments on commit 9ec97e0

Please sign in to comment.