can install to multiple projects

master
BrOakes 2018-11-20 19:28:11 -05:00
parent bcd56daebd
commit a0572460ca
5 changed files with 7 additions and 9 deletions

2
package-lock.json generated
View File

@ -1,6 +1,6 @@
{
"name": "portapy",
"version": "0.0.7",
"version": "0.0.11",
"lockfileVersion": 1,
"requires": true,
"dependencies": {

View File

@ -1,12 +1,12 @@
{
"name": "portapy",
"version": "0.0.7",
"version": "0.0.11",
"description": "",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"postinstall": "node postinstall.js",
"preuninstall": "node uninstall.js",
"postinstall": "node scripts/postinstall.js",
"preuninstall": "node scripts/uninstall.js",
"clean": "node clean.js"
},
"bin": {

View File

@ -3,7 +3,6 @@ let {execSync} = require('child_process');
let pythonDownloader = require('../util/downloadpython.js')
pythonDownloader.download();
// execSync('"Python/Scripts/pip.exe" install --target=worldengine/lib numpy six pypng pyplatec', {
// stdio: 'inherit'

View File

@ -5,9 +5,9 @@ let installerFilename = fs.readFileSync('.installerLocation').toString();
let pythonInstallerPath = path.resolve(__dirname, 'Python-Installer', installerFilename);
let pythonPath = path.resolve(__dirname, 'Python');
// let pythonPath = path.resolve(__dirname, 'Python');
fs.rmdirSync(pythonPath);
// fs.rmdirSync(pythonPath);
// require('child_process').execSync(`${pythonInstallerPath} /passive /uninstall`, {

View File

@ -14,7 +14,6 @@ async function download() {
let url = await getPythonDownloadLink();
let filename = path.parse(url).base;
try {
fs.mkdirSync('Python-Installer');
} catch(e) {'';}
@ -31,7 +30,6 @@ async function download() {
let out_file = `Python-Installer/${filename}`
await new Promise(resolve => {
request({
uri: url,
@ -65,6 +63,7 @@ async function download() {
execSync(`${installerPath} /passive /uninstall`, {
stdio: 'inherit'
});
fs.rmdirSync(tempPath);
console.log("PordaPy Installed!");