anyway, I would like to continue to use the java c...
# sdf
s
anyway, I would like to continue to use the java cli due to it's safety net prompting me prior to deploy (compared to
suitecloud
).
a
you can always set an alias
suitecloud
->
sc
😄
s
true!
a
FWIW, you could extend the CLI through the
suitecloud.config.js
to add that layer: This should work:
Copy code
const prompts = require('prompts');

module.exports = {
	defaultProjectFolder: 'src',
	commands: {
		'project:deploy': {
			projectFolder: 'dist',
			beforeExecuting: async options => {
				const response = await prompts({
					type: 'confirm',
					name: 'value',
					message: 'Are you sure you want to deploy?',
				});
				if (!response.value) {
					throw 'Stopping deployment!';
				}
				return options;
			},
		},
	},
};
You need to install the prompts library in your project:
npm install prompts -D
of course, this code does not check if it's an actual production account. I guess you'd need to find a way to know that (we should help to give that information)