-
Notifications
You must be signed in to change notification settings - Fork 842
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' of github.com:krausest/js-framework-benchmark
- Loading branch information
Showing
49 changed files
with
4,270 additions
and
12,970 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,33 +1,40 @@ | ||
var _ = require('lodash'); | ||
var exec = require('child_process').execSync; | ||
var fs = require('fs'); | ||
var commandExists = require('command-exists'); | ||
const path = require('path'); | ||
const rimraf = require('rimraf'); | ||
const fs = require("fs"); | ||
const path = require("path"); | ||
|
||
function rmIfExists(base, name) { | ||
let dir = path.join(base, name); | ||
if(fs.existsSync(dir)) { | ||
console.log("Clean ",dir); | ||
rimraf.sync(dir); | ||
} | ||
/** | ||
* @param {string} dir | ||
*/ | ||
function rmIfExists(dir) { | ||
if (fs.existsSync(dir)) { | ||
console.log("Cleaning", dir); | ||
fs.rmSync(dir, { recursive: true }); | ||
} | ||
} | ||
|
||
for (let keyedType of ['keyed', 'non-keyed']) { | ||
let dir = path.resolve('frameworks', keyedType); | ||
let directories = fs.readdirSync(dir); | ||
/** | ||
* @param {string} basePath | ||
* @param {string} keyedTypes | ||
*/ | ||
function cleanFrameworkDirectories(basePath, keyedTypes) { | ||
for (const keyedType of keyedTypes) { | ||
const frameworkDir = path.resolve(basePath, keyedType); | ||
const directories = fs.readdirSync(frameworkDir); | ||
|
||
for (let name of directories) { | ||
let fd = path.resolve(dir, name); | ||
console.log('cleaning ', fd); | ||
if(fs.existsSync(fd+"/node_modules")) { | ||
rimraf.sync(fd+"/node_modules"); | ||
} | ||
rmIfExists(fd, "package-lock.json"); | ||
rmIfExists(fd, "yarn.lock"); | ||
rmIfExists(fd, "dist"); | ||
rmIfExists(fd, "elm-stuff"); | ||
rmIfExists(fd, "bower_components"); | ||
rmIfExists(fd, "node_modules"); | ||
} | ||
for (const directory of directories) { | ||
const frameworkPath = path.resolve(frameworkDir, directory); | ||
console.log("cleaning ", frameworkPath); | ||
|
||
rmIfExists(path.join(frameworkPath, "package-lock.json")); | ||
rmIfExists(path.join(frameworkPath, "yarn.lock")); | ||
rmIfExists(path.join(frameworkPath, "node_modules")); | ||
rmIfExists(path.join(frameworkPath, "dist")); | ||
rmIfExists(path.join(frameworkPath, "elm-stuff")); | ||
rmIfExists(path.join(frameworkPath, "bower_components")); | ||
} | ||
} | ||
} | ||
|
||
const keyedTypes = ["keyed", "non-keyed"]; | ||
const frameworksPath = path.resolve("frameworks"); | ||
|
||
cleanFrameworkDirectories(frameworksPath, keyedTypes); |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,15 +6,17 @@ | |
"js-framework-benchmark": { | ||
"frameworkVersionFromPackage": "apprun", | ||
"frameworkHomeURL": "https://apprun.js.org/", | ||
"issues": [801] | ||
"issues": [ | ||
801 | ||
] | ||
}, | ||
"scripts": { | ||
"build-dev": "esbuild src/main.tsx --bundle --outfile=dist/main.js --serve=8080 --servedir=.", | ||
"build-prod": "esbuild src/main.tsx --bundle --outfile=dist/main.js --minify" | ||
}, | ||
"keywords": [ | ||
"apprun", | ||
"js benmarks" | ||
"js benchmarks" | ||
], | ||
"author": "Yiyi Sun <[email protected]", | ||
"license": "Apache-2.0", | ||
|
@@ -24,9 +26,9 @@ | |
"url": "https://github.com/yysun/js-framework-benchmark.git" | ||
}, | ||
"devDependencies": { | ||
"esbuild": "^0.8.54" | ||
"esbuild": "^0.18.13" | ||
}, | ||
"dependencies": { | ||
"apprun": "^2.27.7" | ||
"apprun": "^3.30.2" | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.