Skip to content

Commit e2b2f6e

Browse files
authored
simplify prettier setup (WebOfTrust#223)
1 parent 6574f30 commit e2b2f6e

11 files changed

+62
-64
lines changed

.jsdoc.json

+2-4
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,7 @@
88
"includePattern": ".ts$",
99
"excludePattern": "(node_modules/|docs|dist|examples|test)"
1010
},
11-
"plugins": [
12-
"plugins/markdown"
13-
],
11+
"plugins": ["plugins/markdown"],
1412
"templates": {
1513
"cleverLinks": false,
1614
"monospaceLinks": true,
@@ -24,4 +22,4 @@
2422
"recurse": true,
2523
"template": "./node_modules/minami"
2624
}
27-
}
25+
}

.prettierignore

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
diagrams/
2+
docs/
3+
package.json
4+
package-lock.json
5+
.github/

.prettierrc

+6-6
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
2-
"semi": true,
3-
"trailingComma": "es5",
4-
"singleQuote": true,
5-
"printWidth": 80,
6-
"tabWidth": 4
7-
}
2+
"semi": true,
3+
"trailingComma": "es5",
4+
"singleQuote": true,
5+
"printWidth": 80,
6+
"tabWidth": 4
7+
}

README.md

+5-8
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ Project Name: signify-ts
99

1010
## Signify - KERI Signing at the Edge
1111

12-
Of the five functions in a KERI agent,
12+
Of the five functions in a KERI agent,
1313

1414
1. Key generation
1515
2. Encrypted key storage
@@ -19,20 +19,18 @@ Of the five functions in a KERI agent,
1919

2020
Signify-TS splits off two, key generation and event signing into a TypeScript library to provide "signing at the edge".
2121
It accomplishes this by using [libsodium](https://doc.libsodium.org/) to generate ed25519 key pairs for signing and x25519 key pairs for encrypting the
22-
private keys, next public keys and salts used to generate the private keys. The encrypted private key and salts are then stored on a
23-
remote cloud agent that never has access to the decryption keys. New key pair sets (current and next) will be generated
22+
private keys, next public keys and salts used to generate the private keys. The encrypted private key and salts are then stored on a
23+
remote cloud agent that never has access to the decryption keys. New key pair sets (current and next) will be generated
2424
for inception and rotation events with only the public keys and blake3 hash of the next keys made available to the agent.
2525

2626
The communication protocol between a Signify client and [KERI](https://github.com/WebOfTrust/keri) agent will encode all cryptographic primitives as CESR base64
27-
encoded strings for the initial implementation. Support for binary CESR can be added in the future.
28-
27+
encoded strings for the initial implementation. Support for binary CESR can be added in the future.
2928

3029
### Environment Setup
3130

3231
The code is built using Typescript and running code locally requires a Mac or Linux OS.
3332

34-
- Install [Node.js](https://nodejs.org)
35-
33+
- Install [Node.js](https://nodejs.org)
3634

3735
- Install dependencies:
3836
```bash
@@ -117,5 +115,4 @@ Account Creation Workflow
117115

118116
![Account Creation](/diagrams/account-creation-workflow.png)
119117

120-
121118
![Account Creation Webpage](/diagrams/account-creation-webpage-workflow.png)

codecov.yaml

+9-9
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
coverage:
2-
status:
3-
project:
4-
default:
5-
target: 55
6-
paths: ["src"]
7-
patch:
8-
default:
9-
target: 75
10-
paths: ["src"]
2+
status:
3+
project:
4+
default:
5+
target: 55
6+
paths: ['src']
7+
patch:
8+
default:
9+
target: 75
10+
paths: ['src']

config/keria.json

+9-11
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,15 @@
11
{
22
"dt": "2023-12-01T10:05:25.062609+00:00",
33
"keria": {
4-
"dt": "2023-12-01T10:05:25.062609+00:00",
5-
"curls": [
6-
"http://keria:3902/"
7-
]
4+
"dt": "2023-12-01T10:05:25.062609+00:00",
5+
"curls": ["http://keria:3902/"]
86
},
97
"iurls": [
10-
"http://witness-demo:5642/oobi/BBilc4-L3tFUnfM_wJr4S4OJanAv_VmF_dJNN6vkf2Ha/controller",
11-
"http://witness-demo:5643/oobi/BLskRTInXnMxWaGqcpSyMgo0nYbalW99cGZESrz3zapM/controller",
12-
"http://witness-demo:5644/oobi/BIKKuvBwpmDVA4Ds-EpL5bt9OqPzWPja2LigFYZN2YfX/controller",
13-
"http://witness-demo:5645/oobi/BM35JN8XeJSEfpxopjn5jr7tAHCE5749f0OobhMLCorE/controller",
14-
"http://witness-demo:5646/oobi/BIj15u5V11bkbtAxMA7gcNJZcax-7TgaBMLsQnMHpYHP/controller",
15-
"http://witness-demo:5647/oobi/BF2rZTW79z4IXocYRQnjjsOuvFUQv-ptCf8Yltd7PfsM/controller"
8+
"http://witness-demo:5642/oobi/BBilc4-L3tFUnfM_wJr4S4OJanAv_VmF_dJNN6vkf2Ha/controller",
9+
"http://witness-demo:5643/oobi/BLskRTInXnMxWaGqcpSyMgo0nYbalW99cGZESrz3zapM/controller",
10+
"http://witness-demo:5644/oobi/BIKKuvBwpmDVA4Ds-EpL5bt9OqPzWPja2LigFYZN2YfX/controller",
11+
"http://witness-demo:5645/oobi/BM35JN8XeJSEfpxopjn5jr7tAHCE5749f0OobhMLCorE/controller",
12+
"http://witness-demo:5646/oobi/BIj15u5V11bkbtAxMA7gcNJZcax-7TgaBMLsQnMHpYHP/controller",
13+
"http://witness-demo:5647/oobi/BF2rZTW79z4IXocYRQnjjsOuvFUQv-ptCf8Yltd7PfsM/controller"
1614
]
17-
}
15+
}
+6-6
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
{
2-
"extends": "../../tsconfig.node.json",
3-
"compilerOptions": {
4-
"noEmit": true,
5-
"paths": {
6-
"signify-ts": ["../../src"]
2+
"extends": "../../tsconfig.node.json",
3+
"compilerOptions": {
4+
"noEmit": true,
5+
"paths": {
6+
"signify-ts": ["../../src"]
7+
}
78
}
8-
}
99
}

package.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@
2525
"lint": "npx eslint src test examples/integration-scripts",
2626
"prepare": "npm run build",
2727
"generate-docs": "node_modules/.bin/jsdoc --configure .jsdoc.json --verbose",
28-
"pretty": "prettier --config .prettierrc 'src/**/*.ts' 'test/**/*.ts' 'examples/**/*.ts' --write",
29-
"pretty:check": "prettier --config .prettierrc 'src/**/*.ts' 'test/**/*.ts' 'examples/**/*.ts' --check"
28+
"pretty": "prettier --write .",
29+
"pretty:check": "prettier --check ."
3030
},
3131
"name": "signify-ts",
3232
"author": "Phil Feairheller",

tsconfig.json

+6-6
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
{
2-
"include": ["src", "types", "test", "examples/integration-scripts"],
3-
"extends": "./tsconfig.node.json",
4-
"compilerOptions": {
5-
"noEmit": true,
6-
"allowImportingTsExtensions": true
7-
}
2+
"include": ["src", "types", "test", "examples/integration-scripts"],
3+
"extends": "./tsconfig.node.json",
4+
"compilerOptions": {
5+
"noEmit": true,
6+
"allowImportingTsExtensions": true
7+
}
88
}

tsconfig.node.json

+11-11
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
{
2-
"compilerOptions": {
3-
"target": "ES2022",
4-
"module": "ES2022",
5-
"lib": ["dom", "esnext"],
6-
"moduleResolution": "node",
7-
"strict": true,
8-
"skipLibCheck": true,
9-
"forceConsistentCasingInFileNames": true,
10-
"allowSyntheticDefaultImports": true,
11-
"esModuleInterop": true
12-
}
2+
"compilerOptions": {
3+
"target": "ES2022",
4+
"module": "ES2022",
5+
"lib": ["dom", "esnext"],
6+
"moduleResolution": "node",
7+
"strict": true,
8+
"skipLibCheck": true,
9+
"forceConsistentCasingInFileNames": true,
10+
"allowSyntheticDefaultImports": true,
11+
"esModuleInterop": true
12+
}
1313
}

types/index.d.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
declare module 'ecdsa-secp256r1';
1+
declare module 'ecdsa-secp256r1';

0 commit comments

Comments
 (0)