From 48d3ed79a7b09d03b27cc2ee3cb29b66bb037fef Mon Sep 17 00:00:00 2001 From: Mike Pirog Date: Tue, 27 Feb 2024 16:21:39 -0500 Subject: [PATCH] update setup art --- lib/art.js | 71 +++++++++++++++++++++++++----------------------------- 1 file changed, 33 insertions(+), 38 deletions(-) diff --git a/lib/art.js b/lib/art.js index d2a864d0f..d5f027a27 100644 --- a/lib/art.js +++ b/lib/art.js @@ -300,48 +300,43 @@ exports.newContent = (type = 'guide') => [ '', ].join(os.EOL); -exports.setupHeader = (bengine = process.platform === 'linux' ? 'Engine' : 'Desktop') => [ - '', - chalk.magenta(niceFont('Lando Setup!', 'Small Slant')), - '', - `${chalk.bold('lando setup')} is a convenience command to help you satisify the dependencies needed`, - 'to run Lando. Typically it includes the installation and setup of some combination of the below', - 'However, if you already have the needed dependencies it will happily do nothing and exit.', - '', - chalk.cyan(` ${figures.squareSmallFilled} Common Lando Plugins`), - chalk.cyan(` ${figures.squareSmallFilled} Docker ${bengine}`), - chalk.cyan(` ${figures.squareSmallFilled} Docker Compose`), - '', - 'It will attempt to install plugins first and then it will run any needed setup tasks. For more information on', - `customizing setup please run ${chalk.bold('lando setup --help')}`, - '', -].join(os.EOL); +exports.setupHeader = (bengine = process.platform === 'linux' ? 'Engine' : 'Desktop') => ` +${chalk.magenta(niceFont('Lando Setup!', 'Small Slant'))} + +${chalk.bold('lando setup')} is a hidden convenience command to help you satisify the +dependencies needed to run Lando. Typically it includes the installation and +setup of some combination of the below: + +${chalk.cyan(`${figures.squareSmallFilled} Common Lando Plugins`)} +${chalk.cyan(`${figures.squareSmallFilled} Docker ${bengine}`)} +${chalk.cyan(`${figures.squareSmallFilled} Docker Compose`)} + +However, if you already have the needed dependencies it will happily do nothing +and exit. It will attempt to install plugins first and then it will run any +needed setup tasks. + +For more information on customizing setup please run ${chalk.bold('lando setup --help')} +or visit ${chalk.magenta('https://docs.lando.dev/cli/setup.html')} +`; /* * Helper to show NO DOCKER error message */ -exports.noDockerDep = (dep = 'Docker Desktop') => [ - '', - chalk.red(niceFont('Uh oh!', 'ANSI Shadow')), - '', - `Lando could not detect an installation of ${dep.toUpperCase()} which is a required dependency!`, - 'This most often happens if you have installed Lando manually or from source and have not RTFM.', - '', - `You should run ${chalk.bold('lando setup')} which will attempt to install the things Lando needs to work`, - 'correctly.', - '', - 'When you have completed the above, try running Lando again. If you still have issues', - 'we recommend you install Lando using the convenience script as this will install', - 'and setup the needed dependencies for you.', - chalk.green('https://github.com/lando/lando/releases'), - '', - 'If you are still having issues after that we recommend you post an issue on Github', - 'or ping us in the Slack channel', - '', - chalk.magenta(` ${figures.squareSmallFilled} Slack - https://launchpass.com/devwithlando`), - chalk.magenta(` ${figures.squareSmallFilled} GitHub - https://github.com/lando/lando/issues/new/choose`), - '', -].join(os.EOL); +exports.noDockerDep = (dep = 'Docker Desktop') => ` +${chalk.yellow(niceFont('U Need Setup!', 'Small Slant'))} + +Lando has detected that it does not have all the dependencies it needs to run. +But ${chalk.bold('FEAR NOT')} because we have a special hidden convenience command called ${chalk.bold('lando setup')} +which will do the heavy lifting and set you right. + +Run ${chalk.bold('lando setup')} and when it completes try running Lando again. + +If you get an error or have any issues we recommend you post an issue on +GitHub or ping us in our Slack channel! + +${chalk.magenta(`${figures.squareSmallFilled} Slack - https://launchpass.com/devwithlando`)} +${chalk.magenta(`${figures.squareSmallFilled} GitHub - https://github.com/lando/lando/issues/new/choose`)} +`; /* * Helper to show status of secret toggle