From 5258257d2366a21256add2f7348ecb902dc0c053 Mon Sep 17 00:00:00 2001 From: Phillip Barta Date: Mon, 9 Oct 2023 20:12:32 +0200 Subject: [PATCH] refactor: move files to a near standalone setup --- .github/workflows/ci.yml | 4 +-- .versionrc.json | 2 +- e2e/.eslintrc.json | 18 ++++++++++ e2e/{nx-stylelint-e2e => }/jest.config.ts | 6 ++-- e2e/nx-stylelint-e2e/project.json | 17 ---------- e2e/nx-stylelint-e2e/tsconfig.spec.json | 9 ----- e2e/project.json | 31 +++++++++++++++++ .../tests/nx-stylelint.spec.ts | 4 +-- e2e/{nx-stylelint-e2e => }/tsconfig.json | 2 +- e2e/tsconfig.spec.json | 9 +++++ .../.eslintrc.json | 6 ++-- .../executors.json | 0 .../generators.json | 0 .../jest.config.ts | 4 +-- .../migrations.json | 0 .../migrations.spec.ts | 0 .../package.json | 3 +- .../project.json | 34 +++++++++---------- .../src/executors/lint/compat.ts | 0 .../src/executors/lint/executor.spec.ts | 0 .../src/executors/lint/executor.ts | 0 .../src/executors/lint/schema.d.ts | 0 .../src/executors/lint/schema.json | 0 .../src/generators/configuration/compat.ts | 0 .../configuration/generator.spec.ts | 0 .../src/generators/configuration/generator.ts | 0 .../src/generators/configuration/schema.d.ts | 0 .../src/generators/configuration/schema.json | 0 .../src/generators/init/compat.ts | 0 .../src/generators/init/generator.spec.ts | 0 .../src/generators/init/generator.ts | 0 .../src/generators/init/schema.d.ts | 0 .../src/generators/init/schema.json | 0 .../src/generators/scss/compat.ts | 0 .../src/generators/scss/generator.spec.ts | 0 .../src/generators/scss/generator.ts | 0 .../src/generators/scss/schema.d.ts | 0 .../src/generators/scss/schema.json | 0 .../src/index.ts | 0 .../update-configs/update-configs.spec.ts | 0 .../update-configs/update-configs.ts | 0 .../update-stylelint-targets.spec.ts | 0 .../update-stylelint-targets.ts | 0 .../rename-config-option.spec.ts | 0 .../rename-config-option.ts | 0 .../update-15-0-0/migrate-to-inputs.spec.ts | 0 .../update-15-0-0/migrate-to-inputs.ts | 0 .../src/utils/config-file.ts | 0 .../src/utils/formatter.ts | 0 .../src/utils/stylelint.ts | 0 .../src/utils/versions.ts | 0 .../tsconfig.json | 2 +- .../tsconfig.lib.json | 2 +- .../tsconfig.spec.json | 2 +- nx.json | 5 --- tsconfig.base.json | 2 +- 56 files changed, 96 insertions(+), 66 deletions(-) create mode 100644 e2e/.eslintrc.json rename e2e/{nx-stylelint-e2e => }/jest.config.ts (73%) delete mode 100644 e2e/nx-stylelint-e2e/project.json delete mode 100644 e2e/nx-stylelint-e2e/tsconfig.spec.json create mode 100644 e2e/project.json rename e2e/{nx-stylelint-e2e => }/tests/nx-stylelint.spec.ts (99%) rename e2e/{nx-stylelint-e2e => }/tsconfig.json (72%) create mode 100644 e2e/tsconfig.spec.json rename {packages/nx-stylelint => nx-stylelint}/.eslintrc.json (71%) rename {packages/nx-stylelint => nx-stylelint}/executors.json (100%) rename {packages/nx-stylelint => nx-stylelint}/generators.json (100%) rename {packages/nx-stylelint => nx-stylelint}/jest.config.ts (79%) rename {packages/nx-stylelint => nx-stylelint}/migrations.json (100%) rename {packages/nx-stylelint => nx-stylelint}/migrations.spec.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/package.json (94%) rename {packages/nx-stylelint => nx-stylelint}/project.json (51%) rename {packages/nx-stylelint => nx-stylelint}/src/executors/lint/compat.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/executors/lint/executor.spec.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/executors/lint/executor.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/executors/lint/schema.d.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/executors/lint/schema.json (100%) rename {packages/nx-stylelint => nx-stylelint}/src/generators/configuration/compat.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/generators/configuration/generator.spec.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/generators/configuration/generator.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/generators/configuration/schema.d.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/generators/configuration/schema.json (100%) rename {packages/nx-stylelint => nx-stylelint}/src/generators/init/compat.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/generators/init/generator.spec.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/generators/init/generator.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/generators/init/schema.d.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/generators/init/schema.json (100%) rename {packages/nx-stylelint => nx-stylelint}/src/generators/scss/compat.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/generators/scss/generator.spec.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/generators/scss/generator.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/generators/scss/schema.d.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/generators/scss/schema.json (100%) rename {packages/nx-stylelint => nx-stylelint}/src/index.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/migrations/update-13-0-0/update-configs/update-configs.spec.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/migrations/update-13-0-0/update-configs/update-configs.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/migrations/update-13-0-0/update-stylelint-targets/update-stylelint-targets.spec.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/migrations/update-13-0-0/update-stylelint-targets/update-stylelint-targets.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/migrations/update-13-2-0/rename-config-option/rename-config-option.spec.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/migrations/update-13-2-0/rename-config-option/rename-config-option.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/migrations/update-15-0-0/migrate-to-inputs.spec.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/migrations/update-15-0-0/migrate-to-inputs.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/utils/config-file.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/utils/formatter.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/utils/stylelint.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/src/utils/versions.ts (100%) rename {packages/nx-stylelint => nx-stylelint}/tsconfig.json (90%) rename {packages/nx-stylelint => nx-stylelint}/tsconfig.lib.json (86%) rename {packages/nx-stylelint => nx-stylelint}/tsconfig.spec.json (83%) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 65f29914..9422a36b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -93,7 +93,7 @@ jobs: - name: Publish to NPM if: env.IS_BETA_RELEASE == 'false' run: | - cd dist/packages/nx-stylelint/ + cd dist/nx-stylelint/ npm publish --access public env: NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} @@ -101,7 +101,7 @@ jobs: - name: Publish Beta to NPM if: env.IS_BETA_RELEASE == 'true' run: | - cd dist/packages/nx-stylelint/ + cd dist/nx-stylelint/ npm publish --access public --tag beta env: NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} diff --git a/.versionrc.json b/.versionrc.json index c8ac49be..46311976 100644 --- a/.versionrc.json +++ b/.versionrc.json @@ -32,7 +32,7 @@ "type": "json" }, { - "filename": "packages/nx-stylelint/package.json", + "filename": "nx-stylelint/package.json", "type": "json" } ] diff --git a/e2e/.eslintrc.json b/e2e/.eslintrc.json new file mode 100644 index 00000000..1ad7cf02 --- /dev/null +++ b/e2e/.eslintrc.json @@ -0,0 +1,18 @@ +{ + "extends": ["../.eslintrc.json"], + "ignorePatterns": ["!**/*"], + "overrides": [ + { + "files": ["*.ts", "*.tsx", "*.js", "*.jsx"], + "rules": {} + }, + { + "files": ["*.ts", "*.tsx"], + "rules": {} + }, + { + "files": ["*.js", "*.jsx"], + "rules": {} + } + ] +} diff --git a/e2e/nx-stylelint-e2e/jest.config.ts b/e2e/jest.config.ts similarity index 73% rename from e2e/nx-stylelint-e2e/jest.config.ts rename to e2e/jest.config.ts index c068ed8b..00656f30 100644 --- a/e2e/nx-stylelint-e2e/jest.config.ts +++ b/e2e/jest.config.ts @@ -2,8 +2,8 @@ import type { Config } from '@jest/types'; const config: Config.InitialOptions = { - displayName: 'nx-stylelint-e2e', - preset: '../../jest.preset.js', + displayName: 'e2e', + preset: '../jest.preset.js', globals: {}, transform: { '^.+\\.[tj]s$': [ @@ -14,7 +14,7 @@ const config: Config.InitialOptions = { ], }, moduleFileExtensions: ['ts', 'js', 'html'], - coverageDirectory: '../../coverage/e2e/nx-stylelint-e2e', + coverageDirectory: '../coverage/e2e', testEnvironment: 'node', }; diff --git a/e2e/nx-stylelint-e2e/project.json b/e2e/nx-stylelint-e2e/project.json deleted file mode 100644 index dc1f65a1..00000000 --- a/e2e/nx-stylelint-e2e/project.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "nx-stylelint-e2e", - "$schema": "../../node_modules/nx/schemas/project-schema.json", - "projectType": "application", - "sourceRoot": "e2e/nx-stylelint-e2e/src", - "targets": { - "e2e": { - "executor": "@nx/jest:jest", - "options": { - "jestConfig": "e2e/nx-stylelint-e2e/jest.config.ts", - "runInBand": true - }, - "dependsOn": ["nx-stylelint:build"] - } - }, - "implicitDependencies": ["nx-stylelint"] -} diff --git a/e2e/nx-stylelint-e2e/tsconfig.spec.json b/e2e/nx-stylelint-e2e/tsconfig.spec.json deleted file mode 100644 index 50785ba8..00000000 --- a/e2e/nx-stylelint-e2e/tsconfig.spec.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "extends": "./tsconfig.json", - "compilerOptions": { - "outDir": "../../dist/out-tsc", - "module": "commonjs", - "types": ["jest", "node"] - }, - "include": ["**/*.spec.ts", "**/*.d.ts", "jest.config.ts"] -} diff --git a/e2e/project.json b/e2e/project.json new file mode 100644 index 00000000..13f7d7e1 --- /dev/null +++ b/e2e/project.json @@ -0,0 +1,31 @@ +{ + "name": "e2e", + "$schema": "../node_modules/nx/schemas/project-schema.json", + "projectType": "application", + "sourceRoot": "e2e/tests", + "targets": { + "e2e": { + "executor": "@nx/jest:jest", + "outputs": ["{workspaceRoot}/coverage/{projectRoot}"], + "options": { + "jestConfig": "e2e/jest.config.ts", + "runInBand": true + }, + "configurations": { + "ci": { + "ci": true, + "codeCoverage": true + } + }, + "dependsOn": ["^build"] + }, + "lint": { + "executor": "@nx/linter:eslint", + "outputs": ["{options.outputFile}"], + "options": { + "lintFilePatterns": ["e2e/**/*.ts"] + } + } + }, + "implicitDependencies": ["nx-stylelint"] +} diff --git a/e2e/nx-stylelint-e2e/tests/nx-stylelint.spec.ts b/e2e/tests/nx-stylelint.spec.ts similarity index 99% rename from e2e/nx-stylelint-e2e/tests/nx-stylelint.spec.ts rename to e2e/tests/nx-stylelint.spec.ts index db51eec8..3341c4b7 100644 --- a/e2e/nx-stylelint-e2e/tests/nx-stylelint.spec.ts +++ b/e2e/tests/nx-stylelint.spec.ts @@ -2,13 +2,13 @@ import { checkFilesExist, ensureNxProject, readJson, runNxCommandAsync, cleanup, import { NxJsonConfiguration, ProjectConfiguration, TargetConfiguration } from '@nx/devkit'; import type { Config } from 'stylelint'; -describe('nx-stylelint-e2e', () => { +describe('nx-stylelint E2E tests', () => { beforeAll(() => { cleanup(); }); beforeEach(() => { - ensureNxProject('nx-stylelint', 'dist/packages/nx-stylelint'); + ensureNxProject('nx-stylelint', 'dist/nx-stylelint'); }); describe('nx-stylelint:init', () => { diff --git a/e2e/nx-stylelint-e2e/tsconfig.json b/e2e/tsconfig.json similarity index 72% rename from e2e/nx-stylelint-e2e/tsconfig.json rename to e2e/tsconfig.json index b9c9d953..0d3349c4 100644 --- a/e2e/nx-stylelint-e2e/tsconfig.json +++ b/e2e/tsconfig.json @@ -1,5 +1,5 @@ { - "extends": "../../tsconfig.base.json", + "extends": "../tsconfig.base.json", "files": [], "include": [], "references": [ diff --git a/e2e/tsconfig.spec.json b/e2e/tsconfig.spec.json new file mode 100644 index 00000000..66dc5f8a --- /dev/null +++ b/e2e/tsconfig.spec.json @@ -0,0 +1,9 @@ +{ + "extends": "./tsconfig.json", + "compilerOptions": { + "outDir": "../dist/out-tsc", + "module": "commonjs", + "types": ["jest", "node"] + }, + "include": ["jest.config.ts", "tests/**/*.test.ts", "tests/**/*.spec.ts", "tests/**/*.d.ts"] +} diff --git a/packages/nx-stylelint/.eslintrc.json b/nx-stylelint/.eslintrc.json similarity index 71% rename from packages/nx-stylelint/.eslintrc.json rename to nx-stylelint/.eslintrc.json index 3888b8fc..5751043f 100644 --- a/packages/nx-stylelint/.eslintrc.json +++ b/nx-stylelint/.eslintrc.json @@ -1,5 +1,5 @@ { - "extends": ["../../.eslintrc.json"], + "extends": ["../.eslintrc.json"], "ignorePatterns": ["!**/*"], "overrides": [ { @@ -13,7 +13,9 @@ "@nx/nx-plugin-checks": "error", "@nx/dependency-checks": [ "error", - { "ignoredDependencies": ["stylelint-config-standard", "stylelint-config-standard-scss"] } + { + "ignoredDependencies": ["stylelint-config-standard", "stylelint-config-standard-scss"] + } ] } } diff --git a/packages/nx-stylelint/executors.json b/nx-stylelint/executors.json similarity index 100% rename from packages/nx-stylelint/executors.json rename to nx-stylelint/executors.json diff --git a/packages/nx-stylelint/generators.json b/nx-stylelint/generators.json similarity index 100% rename from packages/nx-stylelint/generators.json rename to nx-stylelint/generators.json diff --git a/packages/nx-stylelint/jest.config.ts b/nx-stylelint/jest.config.ts similarity index 79% rename from packages/nx-stylelint/jest.config.ts rename to nx-stylelint/jest.config.ts index 00062098..8b101ce6 100644 --- a/packages/nx-stylelint/jest.config.ts +++ b/nx-stylelint/jest.config.ts @@ -3,7 +3,7 @@ import type { Config } from '@jest/types'; const config: Config.InitialOptions = { displayName: 'nx-stylelint', - preset: '../../jest.preset.js', + preset: '../jest.preset.js', globals: {}, transform: { '^.+\\.[tj]s$': [ @@ -14,7 +14,7 @@ const config: Config.InitialOptions = { ], }, moduleFileExtensions: ['ts', 'js'], - coverageDirectory: '../../coverage/packages/nx-stylelint', + coverageDirectory: '../coverage/nx-stylelint', testEnvironment: 'node', }; diff --git a/packages/nx-stylelint/migrations.json b/nx-stylelint/migrations.json similarity index 100% rename from packages/nx-stylelint/migrations.json rename to nx-stylelint/migrations.json diff --git a/packages/nx-stylelint/migrations.spec.ts b/nx-stylelint/migrations.spec.ts similarity index 100% rename from packages/nx-stylelint/migrations.spec.ts rename to nx-stylelint/migrations.spec.ts diff --git a/packages/nx-stylelint/package.json b/nx-stylelint/package.json similarity index 94% rename from packages/nx-stylelint/package.json rename to nx-stylelint/package.json index 82efbdc9..d05b736e 100644 --- a/packages/nx-stylelint/package.json +++ b/nx-stylelint/package.json @@ -24,7 +24,8 @@ "engines": { "node": "^18.13.0 || >=20.0.0" }, - "main": "src/index.js", + "main": "./src/index.js", + "typings": "./src/index.d.ts", "schematics": "./generators.json", "builders": "./executors.json", "dependencies": { diff --git a/packages/nx-stylelint/project.json b/nx-stylelint/project.json similarity index 51% rename from packages/nx-stylelint/project.json rename to nx-stylelint/project.json index 871af265..57a3c001 100644 --- a/packages/nx-stylelint/project.json +++ b/nx-stylelint/project.json @@ -1,27 +1,27 @@ { "name": "nx-stylelint", - "$schema": "../../node_modules/nx/schemas/project-schema.json", - "sourceRoot": "packages/nx-stylelint/src", + "$schema": "../node_modules/nx/schemas/project-schema.json", + "sourceRoot": "nx-stylelint/src", "projectType": "library", "targets": { "lint": { "executor": "@nx/linter:eslint", "options": { "lintFilePatterns": [ - "packages/nx-stylelint/**/*.ts", - "packages/nx-stylelint/generators.json", - "packages/nx-stylelint/executors.json", - "packages/nx-stylelint/package.json", - "packages/nx-stylelint/migrations.json" + "nx-stylelint/**/*.ts", + "nx-stylelint/generators.json", + "nx-stylelint/executors.json", + "nx-stylelint/package.json", + "nx-stylelint/migrations.json" ] }, "outputs": ["{options.outputFile}"] }, "test": { "executor": "@nx/jest:jest", - "outputs": ["{workspaceRoot}/coverage/packages/nx-stylelint"], + "outputs": ["{workspaceRoot}/coverage/nx-stylelint"], "options": { - "jestConfig": "packages/nx-stylelint/jest.config.ts", + "jestConfig": "nx-stylelint/jest.config.ts", "passWithNoTests": true } }, @@ -29,31 +29,31 @@ "executor": "@nx/js:tsc", "outputs": ["{options.outputPath}"], "options": { - "outputPath": "dist/packages/nx-stylelint", + "outputPath": "dist/nx-stylelint", "deleteOutputPath": true, - "tsConfig": "packages/nx-stylelint/tsconfig.lib.json", - "packageJson": "packages/nx-stylelint/package.json", - "main": "packages/nx-stylelint/src/index.ts", + "tsConfig": "nx-stylelint/tsconfig.lib.json", + "packageJson": "nx-stylelint/package.json", + "main": "nx-stylelint/src/index.ts", "assets": [ "README.md", "LICENSE", { - "input": "./packages/nx-stylelint/src", + "input": "./nx-stylelint/src", "glob": "**/schema.{json,d.ts}", "output": "./src" }, { - "input": "./packages/nx-stylelint", + "input": "./nx-stylelint", "glob": "generators.json", "output": "." }, { - "input": "./packages/nx-stylelint", + "input": "./nx-stylelint", "glob": "executors.json", "output": "." }, { - "input": "./packages/nx-stylelint", + "input": "./nx-stylelint", "glob": "migrations.json", "output": "." } diff --git a/packages/nx-stylelint/src/executors/lint/compat.ts b/nx-stylelint/src/executors/lint/compat.ts similarity index 100% rename from packages/nx-stylelint/src/executors/lint/compat.ts rename to nx-stylelint/src/executors/lint/compat.ts diff --git a/packages/nx-stylelint/src/executors/lint/executor.spec.ts b/nx-stylelint/src/executors/lint/executor.spec.ts similarity index 100% rename from packages/nx-stylelint/src/executors/lint/executor.spec.ts rename to nx-stylelint/src/executors/lint/executor.spec.ts diff --git a/packages/nx-stylelint/src/executors/lint/executor.ts b/nx-stylelint/src/executors/lint/executor.ts similarity index 100% rename from packages/nx-stylelint/src/executors/lint/executor.ts rename to nx-stylelint/src/executors/lint/executor.ts diff --git a/packages/nx-stylelint/src/executors/lint/schema.d.ts b/nx-stylelint/src/executors/lint/schema.d.ts similarity index 100% rename from packages/nx-stylelint/src/executors/lint/schema.d.ts rename to nx-stylelint/src/executors/lint/schema.d.ts diff --git a/packages/nx-stylelint/src/executors/lint/schema.json b/nx-stylelint/src/executors/lint/schema.json similarity index 100% rename from packages/nx-stylelint/src/executors/lint/schema.json rename to nx-stylelint/src/executors/lint/schema.json diff --git a/packages/nx-stylelint/src/generators/configuration/compat.ts b/nx-stylelint/src/generators/configuration/compat.ts similarity index 100% rename from packages/nx-stylelint/src/generators/configuration/compat.ts rename to nx-stylelint/src/generators/configuration/compat.ts diff --git a/packages/nx-stylelint/src/generators/configuration/generator.spec.ts b/nx-stylelint/src/generators/configuration/generator.spec.ts similarity index 100% rename from packages/nx-stylelint/src/generators/configuration/generator.spec.ts rename to nx-stylelint/src/generators/configuration/generator.spec.ts diff --git a/packages/nx-stylelint/src/generators/configuration/generator.ts b/nx-stylelint/src/generators/configuration/generator.ts similarity index 100% rename from packages/nx-stylelint/src/generators/configuration/generator.ts rename to nx-stylelint/src/generators/configuration/generator.ts diff --git a/packages/nx-stylelint/src/generators/configuration/schema.d.ts b/nx-stylelint/src/generators/configuration/schema.d.ts similarity index 100% rename from packages/nx-stylelint/src/generators/configuration/schema.d.ts rename to nx-stylelint/src/generators/configuration/schema.d.ts diff --git a/packages/nx-stylelint/src/generators/configuration/schema.json b/nx-stylelint/src/generators/configuration/schema.json similarity index 100% rename from packages/nx-stylelint/src/generators/configuration/schema.json rename to nx-stylelint/src/generators/configuration/schema.json diff --git a/packages/nx-stylelint/src/generators/init/compat.ts b/nx-stylelint/src/generators/init/compat.ts similarity index 100% rename from packages/nx-stylelint/src/generators/init/compat.ts rename to nx-stylelint/src/generators/init/compat.ts diff --git a/packages/nx-stylelint/src/generators/init/generator.spec.ts b/nx-stylelint/src/generators/init/generator.spec.ts similarity index 100% rename from packages/nx-stylelint/src/generators/init/generator.spec.ts rename to nx-stylelint/src/generators/init/generator.spec.ts diff --git a/packages/nx-stylelint/src/generators/init/generator.ts b/nx-stylelint/src/generators/init/generator.ts similarity index 100% rename from packages/nx-stylelint/src/generators/init/generator.ts rename to nx-stylelint/src/generators/init/generator.ts diff --git a/packages/nx-stylelint/src/generators/init/schema.d.ts b/nx-stylelint/src/generators/init/schema.d.ts similarity index 100% rename from packages/nx-stylelint/src/generators/init/schema.d.ts rename to nx-stylelint/src/generators/init/schema.d.ts diff --git a/packages/nx-stylelint/src/generators/init/schema.json b/nx-stylelint/src/generators/init/schema.json similarity index 100% rename from packages/nx-stylelint/src/generators/init/schema.json rename to nx-stylelint/src/generators/init/schema.json diff --git a/packages/nx-stylelint/src/generators/scss/compat.ts b/nx-stylelint/src/generators/scss/compat.ts similarity index 100% rename from packages/nx-stylelint/src/generators/scss/compat.ts rename to nx-stylelint/src/generators/scss/compat.ts diff --git a/packages/nx-stylelint/src/generators/scss/generator.spec.ts b/nx-stylelint/src/generators/scss/generator.spec.ts similarity index 100% rename from packages/nx-stylelint/src/generators/scss/generator.spec.ts rename to nx-stylelint/src/generators/scss/generator.spec.ts diff --git a/packages/nx-stylelint/src/generators/scss/generator.ts b/nx-stylelint/src/generators/scss/generator.ts similarity index 100% rename from packages/nx-stylelint/src/generators/scss/generator.ts rename to nx-stylelint/src/generators/scss/generator.ts diff --git a/packages/nx-stylelint/src/generators/scss/schema.d.ts b/nx-stylelint/src/generators/scss/schema.d.ts similarity index 100% rename from packages/nx-stylelint/src/generators/scss/schema.d.ts rename to nx-stylelint/src/generators/scss/schema.d.ts diff --git a/packages/nx-stylelint/src/generators/scss/schema.json b/nx-stylelint/src/generators/scss/schema.json similarity index 100% rename from packages/nx-stylelint/src/generators/scss/schema.json rename to nx-stylelint/src/generators/scss/schema.json diff --git a/packages/nx-stylelint/src/index.ts b/nx-stylelint/src/index.ts similarity index 100% rename from packages/nx-stylelint/src/index.ts rename to nx-stylelint/src/index.ts diff --git a/packages/nx-stylelint/src/migrations/update-13-0-0/update-configs/update-configs.spec.ts b/nx-stylelint/src/migrations/update-13-0-0/update-configs/update-configs.spec.ts similarity index 100% rename from packages/nx-stylelint/src/migrations/update-13-0-0/update-configs/update-configs.spec.ts rename to nx-stylelint/src/migrations/update-13-0-0/update-configs/update-configs.spec.ts diff --git a/packages/nx-stylelint/src/migrations/update-13-0-0/update-configs/update-configs.ts b/nx-stylelint/src/migrations/update-13-0-0/update-configs/update-configs.ts similarity index 100% rename from packages/nx-stylelint/src/migrations/update-13-0-0/update-configs/update-configs.ts rename to nx-stylelint/src/migrations/update-13-0-0/update-configs/update-configs.ts diff --git a/packages/nx-stylelint/src/migrations/update-13-0-0/update-stylelint-targets/update-stylelint-targets.spec.ts b/nx-stylelint/src/migrations/update-13-0-0/update-stylelint-targets/update-stylelint-targets.spec.ts similarity index 100% rename from packages/nx-stylelint/src/migrations/update-13-0-0/update-stylelint-targets/update-stylelint-targets.spec.ts rename to nx-stylelint/src/migrations/update-13-0-0/update-stylelint-targets/update-stylelint-targets.spec.ts diff --git a/packages/nx-stylelint/src/migrations/update-13-0-0/update-stylelint-targets/update-stylelint-targets.ts b/nx-stylelint/src/migrations/update-13-0-0/update-stylelint-targets/update-stylelint-targets.ts similarity index 100% rename from packages/nx-stylelint/src/migrations/update-13-0-0/update-stylelint-targets/update-stylelint-targets.ts rename to nx-stylelint/src/migrations/update-13-0-0/update-stylelint-targets/update-stylelint-targets.ts diff --git a/packages/nx-stylelint/src/migrations/update-13-2-0/rename-config-option/rename-config-option.spec.ts b/nx-stylelint/src/migrations/update-13-2-0/rename-config-option/rename-config-option.spec.ts similarity index 100% rename from packages/nx-stylelint/src/migrations/update-13-2-0/rename-config-option/rename-config-option.spec.ts rename to nx-stylelint/src/migrations/update-13-2-0/rename-config-option/rename-config-option.spec.ts diff --git a/packages/nx-stylelint/src/migrations/update-13-2-0/rename-config-option/rename-config-option.ts b/nx-stylelint/src/migrations/update-13-2-0/rename-config-option/rename-config-option.ts similarity index 100% rename from packages/nx-stylelint/src/migrations/update-13-2-0/rename-config-option/rename-config-option.ts rename to nx-stylelint/src/migrations/update-13-2-0/rename-config-option/rename-config-option.ts diff --git a/packages/nx-stylelint/src/migrations/update-15-0-0/migrate-to-inputs.spec.ts b/nx-stylelint/src/migrations/update-15-0-0/migrate-to-inputs.spec.ts similarity index 100% rename from packages/nx-stylelint/src/migrations/update-15-0-0/migrate-to-inputs.spec.ts rename to nx-stylelint/src/migrations/update-15-0-0/migrate-to-inputs.spec.ts diff --git a/packages/nx-stylelint/src/migrations/update-15-0-0/migrate-to-inputs.ts b/nx-stylelint/src/migrations/update-15-0-0/migrate-to-inputs.ts similarity index 100% rename from packages/nx-stylelint/src/migrations/update-15-0-0/migrate-to-inputs.ts rename to nx-stylelint/src/migrations/update-15-0-0/migrate-to-inputs.ts diff --git a/packages/nx-stylelint/src/utils/config-file.ts b/nx-stylelint/src/utils/config-file.ts similarity index 100% rename from packages/nx-stylelint/src/utils/config-file.ts rename to nx-stylelint/src/utils/config-file.ts diff --git a/packages/nx-stylelint/src/utils/formatter.ts b/nx-stylelint/src/utils/formatter.ts similarity index 100% rename from packages/nx-stylelint/src/utils/formatter.ts rename to nx-stylelint/src/utils/formatter.ts diff --git a/packages/nx-stylelint/src/utils/stylelint.ts b/nx-stylelint/src/utils/stylelint.ts similarity index 100% rename from packages/nx-stylelint/src/utils/stylelint.ts rename to nx-stylelint/src/utils/stylelint.ts diff --git a/packages/nx-stylelint/src/utils/versions.ts b/nx-stylelint/src/utils/versions.ts similarity index 100% rename from packages/nx-stylelint/src/utils/versions.ts rename to nx-stylelint/src/utils/versions.ts diff --git a/packages/nx-stylelint/tsconfig.json b/nx-stylelint/tsconfig.json similarity index 90% rename from packages/nx-stylelint/tsconfig.json rename to nx-stylelint/tsconfig.json index 308a1a63..41d20b09 100644 --- a/packages/nx-stylelint/tsconfig.json +++ b/nx-stylelint/tsconfig.json @@ -1,5 +1,5 @@ { - "extends": "../../tsconfig.base.json", + "extends": "../tsconfig.base.json", "files": [], "include": [], "references": [ diff --git a/packages/nx-stylelint/tsconfig.lib.json b/nx-stylelint/tsconfig.lib.json similarity index 86% rename from packages/nx-stylelint/tsconfig.lib.json rename to nx-stylelint/tsconfig.lib.json index 3a57a8af..b1f07505 100644 --- a/packages/nx-stylelint/tsconfig.lib.json +++ b/nx-stylelint/tsconfig.lib.json @@ -2,7 +2,7 @@ "extends": "./tsconfig.json", "compilerOptions": { "module": "commonjs", - "outDir": "../../dist/out-tsc", + "outDir": "../dist/out-tsc", "declaration": true, "types": ["node"], "removeComments": true diff --git a/packages/nx-stylelint/tsconfig.spec.json b/nx-stylelint/tsconfig.spec.json similarity index 83% rename from packages/nx-stylelint/tsconfig.spec.json rename to nx-stylelint/tsconfig.spec.json index 50785ba8..abbbeff1 100644 --- a/packages/nx-stylelint/tsconfig.spec.json +++ b/nx-stylelint/tsconfig.spec.json @@ -1,7 +1,7 @@ { "extends": "./tsconfig.json", "compilerOptions": { - "outDir": "../../dist/out-tsc", + "outDir": "../dist/out-tsc", "module": "commonjs", "types": ["jest", "node"] }, diff --git a/nx.json b/nx.json index 5fa0acc0..63c71212 100644 --- a/nx.json +++ b/nx.json @@ -1,6 +1,5 @@ { "$schema": "./node_modules/nx/schemas/nx-schema.json", - "npmScope": "nx-stylelint", "affected": { "defaultBase": "main" }, @@ -15,10 +14,6 @@ } } }, - "workspaceLayout": { - "appsDir": "e2e", - "libsDir": "packages" - }, "targetDefaults": { "build": { "dependsOn": ["^build"], diff --git a/tsconfig.base.json b/tsconfig.base.json index 5abaceec..d50a70ed 100644 --- a/tsconfig.base.json +++ b/tsconfig.base.json @@ -15,7 +15,7 @@ "skipDefaultLibCheck": true, "baseUrl": ".", "paths": { - "nx-stylelint": ["packages/nx-stylelint/src/index.ts"] + "nx-stylelint": ["nx-stylelint/src/index.ts"] } }, "exclude": ["node_modules", "tmp"]