fix(format): Fixed formatting issues across multiple TypeScript files.
This commit is contained in:
@@ -4,20 +4,21 @@ import { Project } from '../classes.project.js';
|
||||
|
||||
import { logger } from '../gitzone.logging.js';
|
||||
|
||||
const incompatibleLicenses: string[] = [
|
||||
"AGPL",
|
||||
"GPL",
|
||||
"SSPL",
|
||||
];
|
||||
const incompatibleLicenses: string[] = ['AGPL', 'GPL', 'SSPL'];
|
||||
|
||||
export const run = async (projectArg: Project) => {
|
||||
const nodeModulesInstalled = await plugins.smartfile.fs.isDirectory(plugins.path.join(paths.cwd, 'node_modules'));
|
||||
const nodeModulesInstalled = await plugins.smartfile.fs.isDirectory(
|
||||
plugins.path.join(paths.cwd, 'node_modules'),
|
||||
);
|
||||
if (!nodeModulesInstalled) {
|
||||
logger.log('warn', 'No node_modules found. Skipping license check');
|
||||
return;
|
||||
}
|
||||
const licenseChecker = await plugins.smartlegal.createLicenseChecker();
|
||||
const licenseCheckResult = await licenseChecker.excludeLicenseWithinPath(paths.cwd, incompatibleLicenses);
|
||||
const licenseCheckResult = await licenseChecker.excludeLicenseWithinPath(
|
||||
paths.cwd,
|
||||
incompatibleLicenses,
|
||||
);
|
||||
if (licenseCheckResult.failingModules.length === 0) {
|
||||
logger.log('info', 'Success -> licenses passed!');
|
||||
} else {
|
||||
|
Reference in New Issue
Block a user