extensions/npm/src/tasks.ts/isPrePostScript
function isPrePostScript(name: string): boolean {
	const prePostScripts: Set<string> = new Set([
		'preuninstall', 'postuninstall', 'prepack', 'postpack', 'preinstall', 'postinstall',
		'prepack', 'postpack', 'prepublish', 'postpublish', 'preversion', 'postversion',
		'prestop', 'poststop', 'prerestart', 'postrestart', 'preshrinkwrap', 'postshrinkwrap',
		'pretest', 'postest', 'prepublishOnly'
	]);

	const prepost = ['pre' + name, 'post' + name];
	for (const knownScript of prePostScripts) {
		if (knownScript === prepost[0] || knownScript === prepost[1]) {
			return true;
		}
	}
	return false;
}