@atproto/dev-env 0.6.1 → 0.6.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +12 -0
- package/dist/seed/likes.d.ts +4 -0
- package/dist/seed/likes.d.ts.map +1 -0
- package/dist/seed/likes.js +37 -0
- package/dist/seed/likes.js.map +1 -0
- package/package.json +8 -8
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# @atproto/dev-env
|
|
2
2
|
|
|
3
|
+
## 0.6.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [[`b2d9a77`](https://github.com/bluesky-social/atproto/commit/b2d9a7715e00472b45ef6db2dc07f1e16be5bccd), [`924bb41`](https://github.com/bluesky-social/atproto/commit/924bb410ed9fa4a60d3ed623d8fd40aef310b142), [`aff31c8`](https://github.com/bluesky-social/atproto/commit/aff31c815dd69168f3529e667e8bc6e61272bc63), [`cded706`](https://github.com/bluesky-social/atproto/commit/cded70638b908c49961faa957892ed76b292c1b5), [`066e1b4`](https://github.com/bluesky-social/atproto/commit/066e1b4d669eee5dfaa4f7aefb986bbf722c5629), [`1f3f67c`](https://github.com/bluesky-social/atproto/commit/1f3f67c4b5bac19cc226b24f55d90ffd431d0d72), [`5c3b7c9`](https://github.com/bluesky-social/atproto/commit/5c3b7c9c87efa4d48d41bc55af61f5b1f1e04920)]:
|
|
8
|
+
- @atproto/pds@0.5.29
|
|
9
|
+
- @atproto/api@0.20.41
|
|
10
|
+
- @atproto/bsky@0.0.275
|
|
11
|
+
- @atproto/ozone@0.2.29
|
|
12
|
+
- @atproto/xrpc-server@0.12.5
|
|
13
|
+
- @atproto/sync@0.4.5
|
|
14
|
+
|
|
3
15
|
## 0.6.1
|
|
4
16
|
|
|
5
17
|
### Patch Changes
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"likes.d.ts","sourceRoot":"","sources":["../../src/seed/likes.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,aAAa,CAAA;;0BAEvB,EAAE,EAAE,UAAU"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import basicSeed from './basic.js';
|
|
2
|
+
export default async (sc) => {
|
|
3
|
+
await basicSeed(sc);
|
|
4
|
+
await sc.createAccount('eve', {
|
|
5
|
+
email: 'eve@test.com',
|
|
6
|
+
handle: 'eve.test',
|
|
7
|
+
password: 'eve-pass',
|
|
8
|
+
});
|
|
9
|
+
await sc.like(sc.dids.eve, sc.posts[sc.dids.alice][1].ref);
|
|
10
|
+
await sc.like(sc.dids.carol, sc.replies[sc.dids.bob][0].ref);
|
|
11
|
+
// give alice > 100 likes
|
|
12
|
+
for (let i = 0; i < 50; i++) {
|
|
13
|
+
const [b, c, d] = await Promise.all([
|
|
14
|
+
sc.post(sc.dids.bob, `bob post ${i}`),
|
|
15
|
+
sc.post(sc.dids.carol, `carol post ${i}`),
|
|
16
|
+
sc.post(sc.dids.dan, `dan post ${i}`),
|
|
17
|
+
]);
|
|
18
|
+
await Promise.all([
|
|
19
|
+
sc.like(sc.dids.alice, b.ref), // likes 50 of bobs posts
|
|
20
|
+
i < 45 && sc.like(sc.dids.alice, c.ref), // likes 45 of carols posts
|
|
21
|
+
i < 40 && sc.like(sc.dids.alice, d.ref), // likes 40 of dans posts
|
|
22
|
+
].filter(Boolean));
|
|
23
|
+
}
|
|
24
|
+
// couple more NPCs for suggested follows
|
|
25
|
+
await sc.createAccount('fred', {
|
|
26
|
+
email: 'fred@test.com',
|
|
27
|
+
handle: 'fred.test',
|
|
28
|
+
password: 'fred-pass',
|
|
29
|
+
});
|
|
30
|
+
await sc.createAccount('gina', {
|
|
31
|
+
email: 'gina@test.com',
|
|
32
|
+
handle: 'gina.test',
|
|
33
|
+
password: 'gina-pass',
|
|
34
|
+
});
|
|
35
|
+
return sc;
|
|
36
|
+
};
|
|
37
|
+
//# sour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AAC,GAAG,CACf;YACE,EAAE,CAAC,IAAI,CAAC,EAAE,CAAC,IAAI,CAAC,KAAK,EAAE,CAAC,CAAC,GAAG,CAAC,EAAE,yBAAyB;YACxD,CAAC,GAAG,EAAE,IAAI,EAAE,CAAC,IAAI,CAAC,EAAE,CAAC,IAAI,CAAC,KAAK,EAAE,CAAC,CAAC,GAAG,CAAC,EAAE,2BAA2B;YACpE,CAAC,GAAG,EAAE,IAAI,EAAE,CAAC,IAAI,CAAC,EAAE,CAAC,IAAI,CAAC,KAAK,EAAE,CAAC,CAAC,GAAG,CAAC,EAAE,yBAAyB;SACnE,CAAC,MAAM,CAAC,OAAO,CAAC,CAClB,CAAA;IACH,CAAC;IAED,yCAAyC;IACzC,MAAM,EAAE,CAAC,aAAa,CAAC,MAAM,EAAE;QAC7B,KAAK,EAAE,eAAe;QACtB,MAAM,EAAE,WAAW;QACnB,QAAQ,EAAE,WAAW;KACtB,CAAC,CAAA;IACF,MAAM,EAAE,CAAC,aAAa,CAAC,MAAM,EAAE;QAC7B,KAAK,EAAE,eAAe;QACtB,MAAM,EAAE,WAAW;QACnB,QAAQ,EAAE,WAAW;KACtB,CAAC,CAAA;IAEF,OAAO,EAAE,CAAA;AACX,CAAC,CAAA","sourcesContent":["import basicSeed from './basic.js'\nimport type { SeedClient } from './client.js'\n\nexport default async (sc: SeedClient) => {\n await basicSeed(sc)\n await sc.createAccount('eve', {\n email: 'eve@test.com',\n handle: 'eve.test',\n password: 'eve-pass',\n })\n await sc.like(sc.dids.eve, sc.posts[sc.dids.alice][1].ref)\n await sc.like(sc.dids.carol, sc.replies[sc.dids.bob][0].ref)\n\n // give alice > 100 likes\n for (let i = 0; i < 50; i++) {\n const [b, c, d] = await Promise.all([\n sc.post(sc.dids.bob, `bob post ${i}`),\n sc.post(sc.dids.carol, `carol post ${i}`),\n sc.post(sc.dids.dan, `dan post ${i}`),\n ])\n await Promise.all(\n [\n sc.like(sc.dids.alice, b.ref), // likes 50 of bobs posts\n i < 45 && sc.like(sc.dids.alice, c.ref), // likes 45 of carols posts\n i < 40 && sc.like(sc.dids.alice, d.ref), // likes 40 of dans posts\n ].filter(Boolean),\n )\n }\n\n // couple more NPCs for suggested follows\n await sc.createAccount('fred', {\n email: 'fred@test.com',\n handle: 'fred.test',\n password: 'fred-pass',\n })\n await sc.createAccount('gina', {\n email: 'gina@test.com',\n handle: 'gina.test',\n password: 'gina-pass',\n })\n\n return sc\n}\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atproto/dev-env",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.2",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "Local development environment helper for atproto development",
|
|
6
6
|
"keywords": [
|
|
@@ -40,19 +40,19 @@
|
|
|
40
40
|
"multiformats": "^13.0.0",
|
|
41
41
|
"uint8arrays": "^5.0.0",
|
|
42
42
|
"undici": "^8.5.0",
|
|
43
|
+
"@atproto/api": "^0.20.41",
|
|
44
|
+
"@atproto/bsky": "^0.0.275",
|
|
43
45
|
"@atproto/bsync": "^0.0.41",
|
|
44
46
|
"@atproto/common-web": "^0.5.9",
|
|
45
|
-
"@atproto/bsky": "^0.0.274",
|
|
46
|
-
"@atproto/api": "^0.20.40",
|
|
47
47
|
"@atproto/crypto": "^0.5.4",
|
|
48
|
-
"@atproto/identity": "^0.5.9",
|
|
49
48
|
"@atproto/lex": "^0.3.6",
|
|
50
49
|
"@atproto/lexicon": "^0.7.11",
|
|
51
|
-
"@atproto/pds": "^0.5.
|
|
52
|
-
"@atproto/
|
|
50
|
+
"@atproto/pds": "^0.5.29",
|
|
51
|
+
"@atproto/ozone": "^0.2.29",
|
|
52
|
+
"@atproto/sync": "^0.4.5",
|
|
53
53
|
"@atproto/syntax": "^0.7.4",
|
|
54
|
-
"@atproto/
|
|
55
|
-
"@atproto/
|
|
54
|
+
"@atproto/xrpc-server": "^0.12.5",
|
|
55
|
+
"@atproto/identity": "^0.5.9"
|
|
56
56
|
},
|
|
57
57
|
"devDependencies": {
|
|
58
58
|
"@types/express": "^4.17.13"
|