Broaden prettier to run on all files. (#1068)

Closes https://github.com/the-draupnir-project/planning/issues/109.
This commit is contained in:
Gnuxie
2026-04-02 13:29:36 +01:00
committed by GitHub
parent e761a198aa
commit f951a48419
10 changed files with 47 additions and 27 deletions
+7 -4
View File
@@ -1,8 +1,11 @@
# 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).
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
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).
+6 -2
View File
@@ -37,7 +37,9 @@ jobs:
fetch-tags: true
- name: Set lowercase image owner
id: image_owner
run: echo "image_owner=$(echo '${{ github.repository_owner }}' | tr '[:upper:]' '[:lower:]')" >> $GITHUB_OUTPUT
run:
echo "image_owner=$(echo '${{ github.repository_owner }}' | tr
'[:upper:]' '[:lower:]')" >> $GITHUB_OUTPUT
# Needed for multi platform builds
- name: Set up QEMU
@@ -59,7 +61,9 @@ jobs:
id: meta
uses: docker/metadata-action@v6
with:
images: ghcr.io/${{ steps.image_owner.outputs.image_owner }}/${{ env.IMAGE_NAME }}
images:
ghcr.io/${{ steps.image_owner.outputs.image_owner }}/${{
env.IMAGE_NAME }}
tags: |
type=ref,event=branch
type=sha,prefix=sha-
+5 -2
View File
@@ -31,7 +31,9 @@ jobs:
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
- name: Set lowercase image owner
id: image_owner
run: echo "image_owner=$(echo '${{ github.repository_owner }}' | tr '[:upper:]' '[:lower:]')" >> $GITHUB_OUTPUT
run:
echo "image_owner=$(echo '${{ github.repository_owner }}' | tr
'[:upper:]' '[:lower:]')" >> $GITHUB_OUTPUT
# Needed for multi platform builds
- name: Set up QEMU
@@ -74,6 +76,7 @@ jobs:
id: attest
uses: actions/attest@v4
with:
subject-name: ghcr.io/${{ steps.image_owner.outputs.image_owner }}/draupnir
subject-name:
ghcr.io/${{ steps.image_owner.outputs.image_owner }}/draupnir
subject-digest: ${{ steps.push_ghcr.outputs.digest }}
push-to-registry: true
+5 -2
View File
@@ -32,7 +32,9 @@ jobs:
run: echo "release_version=${GITHUB_REF#refs/*/}" >> $GITHUB_OUTPUT
- name: Set lowercase image owner
id: image_owner
run: echo "image_owner=$(echo '${{ github.repository_owner }}' | tr '[:upper:]' '[:lower:]')" >> $GITHUB_OUTPUT
run:
echo "image_owner=$(echo '${{ github.repository_owner }}' | tr
'[:upper:]' '[:lower:]')" >> $GITHUB_OUTPUT
# Needed for multi platform builds
- name: Set up QEMU
@@ -75,6 +77,7 @@ jobs:
id: attest
uses: actions/attest@v4
with:
subject-name: ghcr.io/${{ steps.image_owner.outputs.image_owner }}/draupnir
subject-name:
ghcr.io/${{ steps.image_owner.outputs.image_owner }}/draupnir
subject-digest: ${{ steps.push_ghcr.outputs.digest }}
push-to-registry: true
+3 -1
View File
@@ -1,6 +1,8 @@
# SPDX-FileCopyrightText: 2024 Gnuxie <Gnuxie@protonmail.com>
#
# SPDX-License-Identifier: AFL-3.0
# SPDX-License-Identifier: 0BSD
dist
packages/matrix-protection-suite/docs
node_modules
package-lock.json
+13 -8
View File
@@ -19,12 +19,12 @@ const ignores = [
"**/lib/**",
"**/node_modules/**",
"**/*.js",
"**/*.jsx"
"**/*.jsx",
];
export default tseslint.config(
{
ignores
ignores,
},
{
// This is a typescript-eslint configurartion for typescript files.
@@ -80,10 +80,7 @@ export default tseslint.config(
// but other than using namespaces, we don't have granular enough modules
// to be able to depend on their behaviour. This should be revisited.
"@typescript-eslint/no-extraneous-class": "off",
"@typescript-eslint/unbound-method": [
"error",
{ ignoreStatic: true }
],
"@typescript-eslint/unbound-method": ["error", { ignoreStatic: true }],
// We want to be able to create infinite loops.
"@typescript-eslint/no-unnecessary-condition": [
"error",
@@ -100,7 +97,11 @@ export default tseslint.config(
{
allow: [
// Idk why they did this but whatever https://github.com/element-hq/matrix-bot-sdk/pull/66/changes#r2965217095
{ from: "package", name: "getRoomStateEvent", package: "@vector-im/matrix-bot-sdk" },
{
from: "package",
name: "getRoomStateEvent",
package: "@vector-im/matrix-bot-sdk",
},
],
},
],
@@ -126,7 +127,11 @@ export default tseslint.config(
{ from: "file", name: "logMessage" },
{ from: "file", name: "allocateProtection" },
// Idk why they did this but whatever https://github.com/element-hq/matrix-bot-sdk/pull/66/changes#r2965217095
{ from: "package", name: "getRoomStateEvent", package: "@vector-im/matrix-bot-sdk" },
{
from: "package",
name: "getRoomStateEvent",
package: "@vector-im/matrix-bot-sdk",
},
],
},
],
+2 -2
View File
@@ -21,7 +21,7 @@
"build:all": "tsc -b tsconfig.all.json && npm run -ws build:assets --if-present",
"build:clean": "tsc -b --clean",
"test": "npm run -ws test --if-present && npm run -w apps/draupnir test:unit",
"lint": "eslint --cache 'packages/**/*.{ts,tsx}' 'apps/**/*.{ts,tsx}' && prettier --cache --ignore-unknown --check apps packages README.md CHANGELOG.md DEPENDENCIES.md"
"lint": "eslint --cache 'packages/**/*.{ts,tsx}' 'apps/**/*.{ts,tsx}' && prettier --cache --ignore-unknown --check ."
},
"devDependencies": {
"@changesets/cli": "^2.30.0",
@@ -38,7 +38,7 @@
"@vector-im/matrix-bot-sdk": "0.8.0-element.3",
"postgres": "3.4.7"
},
"engines": {
"engines": {
"node": ">=24.0.0"
}
}
+3 -1
View File
@@ -10,7 +10,9 @@
{ "path": "./packages/matrix-basic-types/tsconfig.test.json" },
{ "path": "./packages/interface-manager/tsconfig.test.json" },
{ "path": "./packages/matrix-protection-suite/tsconfig.test.json" },
{ "path": "./packages/matrix-protection-suite-for-matrix-bot-sdk/tsconfig.test.json" },
{
"path": "./packages/matrix-protection-suite-for-matrix-bot-sdk/tsconfig.test.json"
},
{ "path": "./packages/mps-interface-adaptor/tsconfig.test.json" },
{ "path": "./apps/draupnir/tsconfig.test.json" }
]
+2 -4
View File
@@ -2,9 +2,7 @@
"compilerOptions": {
"target": "es2024",
"module": "node16",
"lib": [
"es2024"
],
"lib": ["es2024"],
"declaration": true,
"declarationMap": true,
"exactOptionalPropertyTypes": true,
@@ -21,6 +19,6 @@
"noImplicitThis": true,
"noUncheckedIndexedAccess": true,
"noUnusedLocals": true,
"noImplicitAny": true,
"noImplicitAny": true
}
}
+1 -1
View File
@@ -6,6 +6,6 @@
{ "path": "./packages/matrix-protection-suite" },
{ "path": "./packages/matrix-protection-suite-for-matrix-bot-sdk" },
{ "path": "./packages/mps-interface-adaptor" },
{ "path": "./apps/draupnir"}
{ "path": "./apps/draupnir" }
]
}