-
-
Notifications
You must be signed in to change notification settings - Fork 208
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(v4.0.0): refactor monorepo, change structure
- Loading branch information
1 parent
65cf600
commit 169f54a
Showing
82 changed files
with
7,056 additions
and
9,192 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 |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# Changesets | ||
|
||
Hello and welcome! This folder has been automatically generated by `@changesets/cli`, a build tool that works | ||
with multi-package repos, or single-package repos to help you version and publish your code. You can | ||
find the full documentation for it [in our repository](https://github.com/changesets/changesets) | ||
|
||
We have a quick list of common questions to get you started engaging with this project in | ||
[our documentation](https://github.com/changesets/changesets/blob/main/docs/common-questions.md) |
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 |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"$schema": "https://unpkg.com/@changesets/[email protected]/schema.json", | ||
"changelog": "@changesets/cli/changelog", | ||
"commit": false, | ||
"fixed": [], | ||
"linked": [], | ||
"access": "restricted", | ||
"baseBranch": "master", | ||
"updateInternalDependencies": "patch", | ||
"ignore": [] | ||
} |
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 |
---|---|---|
|
@@ -13,4 +13,6 @@ docs | |
.cache | ||
tmp | ||
sandbox | ||
/tmp/ | ||
tmp/ | ||
.turbo | ||
build/ |
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 |
---|---|---|
@@ -0,0 +1,18 @@ | ||
{ | ||
"git": { | ||
"commitMessage": "chore: release v${version}" | ||
}, | ||
"github": { | ||
"release": true, | ||
"releaseName": "v${version}" | ||
}, | ||
"npm": { | ||
"publish": false | ||
}, | ||
"plugins": { | ||
"@release-it/conventional-changelog": { | ||
"preset": "conventionalcommits", | ||
"infile": "CHANGELOG.md" | ||
} | ||
} | ||
} |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
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 |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/usr/bin/env node | ||
|
||
require('../dist/jscpd') |
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 |
---|---|---|
@@ -0,0 +1,10 @@ | ||
import {jscpd} from "../src"; | ||
|
||
(async () => { | ||
try { | ||
await jscpd(process.argv, process.exit) | ||
} catch(e) { | ||
console.log(e); | ||
process.exit(1); | ||
} | ||
})() |
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 |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"$schema": "https://json.schemastore.org/nodemon.json", | ||
"watch": ["./src/**"], | ||
"ignoreRoot": [], | ||
"ext": "ts,js", | ||
"exec": "pnpm build" | ||
} |
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,6 +1,6 @@ | ||
{ | ||
"name": "jscpd", | ||
"version": "3.5.10", | ||
"version": "4.0.0-rc.0", | ||
"description": "detector of copy/paste in files", | ||
"author": "Andrey Kucherenko <[email protected]>", | ||
"homepage": "https://github.com/kucherenko/jscpd#readme", | ||
|
@@ -26,28 +26,31 @@ | |
"url": "git+ssh://[email protected]/kucherenko/jscpd.git" | ||
}, | ||
"scripts": { | ||
"build": "yarn clean && yarn compile", | ||
"clean": "rm -rf ./dist", | ||
"compile": "tsc -p tsconfig.build.json", | ||
"prepare": "ts-node ../../build-utils/publish-util.ts ./package.json dist/index", | ||
"postpublish": "ts-node ../../build-utils/publish-util.ts ./package.json src/index", | ||
"prepublishOnly": "yarn build" | ||
"build": "tsup", | ||
"dev": "nodemon", | ||
"test": "vitest run", | ||
"typecheck": "tsc", | ||
"cleanup": "rimraf ./dist .turbo" | ||
}, | ||
"dependencies": { | ||
"@jscpd/core": "^3.5.4", | ||
"@jscpd/finder": "^3.5.10", | ||
"@jscpd/html-reporter": "^3.5.10", | ||
"@jscpd/tokenizer": "^3.5.4", | ||
"colors": "1.4.0", | ||
"commander": "^5.0.0", | ||
"fs-extra": "^9.1.0", | ||
"@jscpd/core": "workspace:*", | ||
"@jscpd/finder": "workspace:*", | ||
"@jscpd/html-reporter": "workspace:*", | ||
"@jscpd/tokenizer": "workspace:*", | ||
"colors": "^1.4.0", | ||
"commander": "^12.1.0", | ||
"fs-extra": "^11.2.0", | ||
"gitignore-to-glob": "^0.3.0" | ||
}, | ||
"devDependencies": { | ||
"@types/colors": "^1.2.1", | ||
"@types/fs-extra": "^8.1.0", | ||
"@tsconfig/node20": "^20.1.4", | ||
"@types/fs-extra": "^11.0.4", | ||
"jscpd-badge-reporter": "^1.1.3", | ||
"ts-node": "^8.8.2" | ||
"nodemon": "^3.1.0", | ||
"ts-node": "^10.9.2", | ||
"tsup": "^8.0.2", | ||
"typescript": "^5.4.5", | ||
"vitest": "^1.6.0" | ||
}, | ||
"preferGlobal": true, | ||
"gitHead": "87a118f80343288c0099a4e3e47ccd875476bf6c" | ||
|
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
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
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
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 |
---|---|---|
@@ -0,0 +1,28 @@ | ||
{ | ||
"extends": "@tsconfig/node20/tsconfig.json", | ||
"compilerOptions": { | ||
"outDir": "dist/src", | ||
"baseUrl": ".", | ||
"module": "esnext", | ||
"moduleResolution": "bundler", | ||
"allowUnusedLabels": false, | ||
"allowUnreachableCode": false, | ||
"noFallthroughCasesInSwitch": true, | ||
"noUncheckedIndexedAccess": true, | ||
"noUnusedLocals": true, | ||
"noUnusedParameters": true, | ||
"forceConsistentCasingInFileNames": true, | ||
"declaration": true, | ||
"sourceMap": true, | ||
"resolveJsonModule": true | ||
}, | ||
"include": ["src"], | ||
"exclude": ["dist", "bundle", "node_modules"], | ||
"ts-node": { | ||
// these options are overrides used only by ts-node | ||
// same as the --compilerOptions flag and the TS_NODE_COMPILER_OPTIONS environment variable | ||
"compilerOptions": { | ||
"module": "commonjs" | ||
} | ||
}, | ||
} |
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 |
---|---|---|
@@ -0,0 +1,8 @@ | ||
import { defineConfig } from 'tsup' | ||
|
||
export default defineConfig({ | ||
entry: ['bin/jscpd.ts'], | ||
splitting: false, | ||
sourcemap: false, | ||
clean: true, | ||
}) |
This file was deleted.
Oops, something went wrong.
This file was deleted.
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 |
---|---|---|
|
@@ -3,78 +3,19 @@ | |
"private": true, | ||
"npmClient": "yarn", | ||
"useWorkspaces": true, | ||
"version": "3.3.0-rc.0", | ||
"version": "4.0.0-rc.0", | ||
"scripts": { | ||
"commit": "npx git-cz", | ||
"bootstrap": "lerna bootstrap", | ||
"postinstall": "yarn bootstrap", | ||
"clean": "lerna run clean", | ||
"build": "lerna run build", | ||
"pub": "lerna publish", | ||
"test": "nyc yarn run test:unit", | ||
"test:unit": "mocha -r source-map-support/register -r ts-node/register packages/*/__tests__/**/*.test.ts", | ||
"coverage": "run-s build test cov:html cov:check", | ||
"lint": "eslint --cache --ext .ts packages/*/src", | ||
"cov": "run-s build test cov:html && open coverage/lcov-report/index.html", | ||
"cov:html": "nyc report --reporter=lcov", | ||
"cov:check": "nyc report && nyc check-coverage --lines 90 --functions 90 --branches 77", | ||
"doc": "run-s doc:html && open docs/index.html", | ||
"doc:html": "typedoc --out ./docs ./packages", | ||
"doc:publish": "gh-pages -m \"[ci skip] Updates\" -d docs", | ||
"reset": "git clean -dfx && git reset --hard && yarn", | ||
"all": "run-s reset test cov:check doc:html", | ||
"changelog": "lerna-changelog" | ||
}, | ||
"nyc": { | ||
"reporter": [ | ||
"lcov" | ||
], | ||
"include": [ | ||
"packages/*/src/**/*.ts" | ||
], | ||
"exclude": [ | ||
"packages/examples/**" | ||
], | ||
"extends": "@istanbuljs/nyc-config-typescript", | ||
"all": true | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "git+ssh://[email protected]/kucherenko/jscpd.git" | ||
"build": "turbo run build", | ||
"generate": "turbo run generate", | ||
"dev": "turbo run dev --parallel", | ||
"lint": "turbo run lint", | ||
"lint:fix": "turbo run lint:fix", | ||
"test": "turbo run test", | ||
"cleanup": "turbo run cleanup" | ||
}, | ||
"devDependencies": { | ||
"@istanbuljs/nyc-config-typescript": "^1.0.1", | ||
"@types/chai": "^4.2.11", | ||
"@types/mocha": "^7.0.2", | ||
"@types/proxyquire": "^1.3.28", | ||
"@types/sinon": "^9.0.0", | ||
"@typescript-eslint/eslint-plugin": "^2.30.0", | ||
"@typescript-eslint/parser": "^2.30.0", | ||
"chai": "^4.2.0", | ||
"conventional-changelog-cli": "^2.0.31", | ||
"cz-conventional-changelog": "^3.1.0", | ||
"eslint": "^6.8.0", | ||
"eslint-plugin-sonarjs": "^0.5.0", | ||
"gh-pages": "^2.2.0", | ||
"git-cz": "^4.3.1", | ||
"lerna": "^3.20.2", | ||
"lerna-changelog": "^1.0.1", | ||
"mocha": "^7.1.2", | ||
"npm-run-all": "^4.1.5", | ||
"nyc": "^15.0.1", | ||
"open-cli": "^5.0.0", | ||
"proxyquire": "^2.1.3", | ||
"sinon": "^9.0.2", | ||
"source-map-support": "^0.5.19", | ||
"typedoc": "~0.17.6", | ||
"typedoc-plugin-lerna-packages": "~0.3.0", | ||
"typescript": "^3.8.3" | ||
"@changesets/cli": "^2.27.3", | ||
"turbo": "^1.13.3" | ||
}, | ||
"workspaces": [ | ||
"packages/*" | ||
], | ||
"readmeFilename": "README.md", | ||
"dependencies": { | ||
"codecov": "^3.7.2" | ||
} | ||
"readmeFilename": "README.md" | ||
} |
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 |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"$schema": "https://json.schemastore.org/nodemon.json", | ||
"watch": ["./src/**"], | ||
"ignoreRoot": [], | ||
"ext": "ts,js", | ||
"exec": "pnpm typecheck && pnpm build" | ||
} |
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 |
---|---|---|
|
@@ -11,8 +11,24 @@ | |
"author": "Andrey Kucherenko <[email protected]>", | ||
"homepage": "https://github.com/kucherenko/jscpd#readme", | ||
"license": "MIT", | ||
"main": "src/index", | ||
"types": "src/index", | ||
"main": "dist/index.js", | ||
"module": "dist/index.mjs", | ||
"typings": "dist/index.d.mts", | ||
"exports": { | ||
".": { | ||
"types": "./dist/index.d.ts", | ||
"import": "./dist/index.mjs", | ||
"require": "./dist/index.js" | ||
}, | ||
"./README.md": "./README.md" | ||
}, | ||
"scripts": { | ||
"build": "tsup", | ||
"dev": "nodemon", | ||
"test": "vitest run", | ||
"typecheck": "tsc", | ||
"cleanup": "rimraf ./dist .turbo" | ||
}, | ||
"directories": { | ||
"src": "src", | ||
"test": "__tests__" | ||
|
@@ -27,19 +43,17 @@ | |
"type": "git", | ||
"url": "git+ssh://[email protected]/kucherenko/jscpd.git" | ||
}, | ||
"scripts": { | ||
"build": "yarn clean && yarn compile", | ||
"clean": "rm -rf ./dist", | ||
"compile": "tsc -p tsconfig.build.json", | ||
"prepare": "ts-node ../../build-utils/publish-util.ts ./package.json dist/index", | ||
"postpublish": "ts-node ../../build-utils/publish-util.ts ./package.json src/index", | ||
"prepublishOnly": "yarn build" | ||
}, | ||
"bugs": { | ||
"url": "https://github.com/kucherenko/jscpd/issues" | ||
}, | ||
"dependencies": { | ||
"badgen": "^3.2.2", | ||
"fs-extra": "^9.0.1" | ||
"badgen": "^3.2.3", | ||
"fs-extra": "^11.2.0" | ||
}, | ||
"devDependencies": { | ||
"@tsconfig/node20": "^20.1.4", | ||
"@types/node": "^20.12.12", | ||
"nodemon": "^3.1.0", | ||
"tsup": "^8.0.2" | ||
} | ||
} |
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 |
---|---|---|
@@ -0,0 +1,9 @@ | ||
import {defineConfig} from 'tsup' | ||
|
||
export default defineConfig({ | ||
entry: ['src/index.ts'], | ||
splitting: true, | ||
sourcemap: true, | ||
clean: true, | ||
format: ['esm', 'cjs'] | ||
}) |
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 |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"$schema": "https://json.schemastore.org/nodemon.json", | ||
"watch": ["./src/**"], | ||
"ignoreRoot": [], | ||
"ext": "ts,js", | ||
"exec": "pnpm typecheck && pnpm build" | ||
} |
Oops, something went wrong.