forked from kitschpatrol/shared-config
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: update prettier to latest config standard
- Loading branch information
1 parent
9d88591
commit c2bb52e
Showing
12 changed files
with
295 additions
and
287 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,58 +1,8 @@ | ||
# Prettier Ignore | ||
# Does not inherit from .gitignore | ||
|
||
# @envsa/repo-config boilerplate | ||
# ===== | ||
# Craft | ||
# ===== | ||
.env | ||
.env.* | ||
!.env.example | ||
vendor/ | ||
/web/assets/* | ||
|
||
# ====== | ||
# Builds | ||
# ====== | ||
node_modules/ | ||
**/*.min.js | ||
|
||
# ===== | ||
# Tests | ||
# ===== | ||
/test-results/ | ||
/playwright-report/ | ||
/playwright/.cache/ | ||
|
||
# ==== | ||
# Misc | ||
# ==== | ||
.cache | ||
.DS_Store | ||
_junk/ | ||
tmp/ | ||
temp/ | ||
.project | ||
.settings | ||
*.esproj | ||
*.sublime-workspace | ||
*.sublime-project | ||
*.tmproj | ||
*.tmproject | ||
config.codekit3 | ||
prepros-6.config | ||
# Also respects .gitignore | ||
|
||
# @envsa/prettier-config boilerplate | ||
pnpm-lock.yaml | ||
package-lock.json | ||
composer.lock | ||
config/project/**/* | ||
storage/config-deltas/**/* | ||
storage/**/* | ||
web/cpresources/**/* | ||
web/web.config | ||
*.svg | ||
.ddev/ | ||
|
||
# Customizations | ||
bin/ |
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,57 +1,8 @@ | ||
# Prettier Ignore | ||
# Does not inherit from .gitignore | ||
|
||
# @envsa/repo-config boilerplate | ||
# ===== | ||
# Craft | ||
# ===== | ||
.env | ||
.env.* | ||
!.env.example | ||
vendor/ | ||
/web/assets/* | ||
|
||
# ====== | ||
# Builds | ||
# ====== | ||
node_modules/ | ||
**/*.min.js | ||
|
||
# ===== | ||
# Tests | ||
# ===== | ||
/test-results/ | ||
/playwright-report/ | ||
/playwright/.cache/ | ||
|
||
# ==== | ||
# Misc | ||
# ==== | ||
.cache | ||
.DS_Store | ||
_junk/ | ||
tmp/ | ||
temp/ | ||
.project | ||
.settings | ||
*.esproj | ||
*.sublime-workspace | ||
*.sublime-project | ||
*.tmproj | ||
*.tmproject | ||
config.codekit3 | ||
prepros-6.config | ||
# Also respects .gitignore | ||
|
||
# @envsa/prettier-config boilerplate | ||
pnpm-lock.yaml | ||
package-lock.json | ||
composer.lock | ||
config/project/**/* | ||
storage/config-deltas/**/* | ||
storage/**/* | ||
web/cpresources/**/* | ||
web/web.config | ||
*.svg | ||
.ddev/ | ||
|
||
# Customizations |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,3 @@ | ||
import sharedConfig from '@envsa/prettier-config'; | ||
import { prettierConfig } from '@envsa/prettier-config'; | ||
|
||
/** @type {import("prettier").Config} */ | ||
const localConfig = { | ||
// Config overrides | ||
// overrides: [ | ||
// ...sharedConfig.overrides, | ||
// { | ||
// // Per-file overrides overrides | ||
// }, | ||
// ], | ||
}; | ||
export default { | ||
...sharedConfig, | ||
...localConfig, | ||
}; | ||
export default prettierConfig(); |
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,61 +1,71 @@ | ||
{ | ||
"name": "@envsa/prettier-config", | ||
"version": "8.2.0", | ||
"type": "module", | ||
"description": "Prettier configuration for @envsa/shared-config.", | ||
"repository": { | ||
"type": "git", | ||
"url": "[email protected]:envsa/shared-config.git", | ||
"directory": "packages/prettier-config" | ||
}, | ||
"bugs": { | ||
"url": "https://github.com/envsa/shared-config/issues", | ||
"email": "[email protected]" | ||
}, | ||
"author": { | ||
"name": "Liam Rella", | ||
"email": "[email protected]", | ||
"url": "https://github.com/rellafella" | ||
}, | ||
"license": "MIT", | ||
"engines": { | ||
"node": ">=22.0.0", | ||
"pnpm": ">=10.0.0" | ||
}, | ||
"bin": { | ||
"prettier-config": "bin/cli.js" | ||
}, | ||
"main": "prettier.config.js", | ||
"files": [ | ||
"bin/*", | ||
"init/*" | ||
], | ||
"keywords": [ | ||
"shared-config", | ||
"prettier-config", | ||
"prettier", | ||
"cli" | ||
], | ||
"scripts": { | ||
"build": "../../scripts/build.ts && mdat readme", | ||
"cli": "node ./bin/cli.js", | ||
"prepublishOnly": "pnpm run build" | ||
}, | ||
"peerDependencies": { | ||
"prettier": "^3.3.1" | ||
}, | ||
"name": "@envsa/prettier-config", | ||
"version": "8.2.0", | ||
"description": "Prettier configuration for @envsa/shared-config.", | ||
"keywords": [ | ||
"shared-config", | ||
"prettier-config", | ||
"prettier", | ||
"cli" | ||
], | ||
"homepage": "https://github.com/envsa/shared-config/packages/prettier-config", | ||
"bugs": { | ||
"url": "https://github.com/envsa/shared-config/issues", | ||
"email": "[email protected]" | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "[email protected]:envsa/shared-config.git", | ||
"directory": "packages/prettier-config" | ||
}, | ||
"license": "MIT", | ||
"author": { | ||
"name": "Liam Rella", | ||
"email": "[email protected]", | ||
"url": "https://github.com/rellafella" | ||
}, | ||
"type": "module", | ||
"exports": { | ||
".": { | ||
"import": "./dist/index.js", | ||
"types": "./dist/index.d.ts" | ||
} | ||
}, | ||
"main": "dist/index.js", | ||
"types": "dist/index.d.ts", | ||
"bin": { | ||
"envsa-prettier": "bin/cli.js" | ||
}, | ||
"files": [ | ||
"bin/*", | ||
"dist/*", | ||
"init/*" | ||
], | ||
"scripts": { | ||
"build": "tsc && ../../scripts/build.ts", | ||
"cli": "node ./bin/cli.js", | ||
"prepublishOnly": "pnpm run build" | ||
}, | ||
"dependencies": { | ||
"@pinojs/json-colorizer": "^4.0.0", | ||
"@prettier/plugin-php": "^0.22.2", | ||
"@prettier/plugin-xml": "^3.4.1", | ||
"@zackad/prettier-plugin-twig": "^0.13.0", | ||
"cosmiconfig": "^9.0.0", | ||
"deepmerge-ts": "^7.1.4", | ||
"execa": "^9.5.2", | ||
"find-workspaces": "^0.3.1", | ||
"fs-extra": "^11.2.0", | ||
"prettier-plugin-pkg": "^0.18.1", | ||
"prettier": "^3.3.1", | ||
"prettier-plugin-packagejson": "^2.5.8", | ||
"prettier-plugin-sh": "^0.14.0", | ||
"prettier-plugin-svelte": "^3.3.2", | ||
"prettier-plugin-tailwindcss": "^0.6.9" | ||
"prettier-plugin-tailwindcss": "^0.6.9", | ||
"sort-package-json": "^2.14.0" | ||
}, | ||
"engines": { | ||
"node": ">=22.0.0", | ||
"pnpm": ">=10.0.0" | ||
}, | ||
"publishConfig": { | ||
"access": "public" | ||
|
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 |
---|---|---|
@@ -1,29 +1,5 @@ | ||
#!/usr/bin/env node | ||
import { buildCommands } from '$root/src/command-builder.ts'; | ||
import { buildCommands } from '../../../src/command-builder.js' | ||
import { commandDefinition } from './command.js' | ||
|
||
// TODO bad idea? | ||
// At least test the ruby situation | ||
const sharedOptions = [ | ||
'--log-level=warn', | ||
'--plugin=@prettier/plugin-php', | ||
'--plugin=@prettier/plugin-xml', | ||
'--plugin=prettier-plugin-pkg', | ||
'--plugin=prettier-plugin-sh', | ||
'--plugin=prettier-plugin-svelte', | ||
'--plugin=prettier-plugin-tailwindcss', | ||
]; | ||
|
||
await buildCommands('prettier-config', '[Prettier]', 'blue', { | ||
check: { | ||
command: 'prettier', | ||
defaultArguments: ['.'], | ||
options: [...sharedOptions, '--check'], | ||
}, | ||
fix: { | ||
command: 'prettier', | ||
defaultArguments: ['.'], | ||
options: [...sharedOptions, '--write'], | ||
}, | ||
init: {}, | ||
printConfig: {}, | ||
}); | ||
await buildCommands(commandDefinition) |
Oops, something went wrong.