コード例 #1
0
 public static void InstallPackages(params string[] packageNames)
 {
     PvcRuntimeNodeJs <TPlugin> .Execute(new
     {
         packageNames = packageNames
     },
                                         @"
         pvc.lib.npm.installPackages(pvc.data.packageNames, function (err, data) {
             pvc.doneCallback(err, data);
         });
     ");
 }
コード例 #2
0
        public static void InstallPackages()
        {
            var packageJson = LoadPackageJsonFromAssembly();

            PvcRuntimeNodeJs <TPlugin> .Execute(new
            {
                packageJson = packageJson
            },
                                                @"
                pvc.lib.npm.install(JSON.parse(pvc.data.packageJson), function (err, data) {
                    pvc.doneCallback(err, data);
                });
            ");
        }