Skip to content

Commit f0f21d1

Browse files
author
M0nkeyFl0wer
committed
fix: migrate 40 projects to new schema (project_status + ecosystem + usecases)
1 parent c7cb78e commit f0f21d1

File tree

42 files changed

+422
-218
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

42 files changed

+422
-218
lines changed

migrate-project-status.mjs

Lines changed: 114 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,114 @@
1+
#!/usr/bin/env node
2+
import { readFile, writeFile } from 'fs/promises';
3+
import { parse, stringify } from 'yaml';
4+
import { join } from 'path';
5+
6+
const projects = [
7+
'fileverse', 'mysterium-network', 'elusiv', 'zkvote', 'starkex', 'hopr',
8+
'deeper-network', 'firo', 'oasis-network', 'zcash', 'privatepool',
9+
'tornado-cash', 'iden3', 'circom', 'zksync', 'darkfi', 'sentinel',
10+
'snarkjs', 'findora', 'cake-wallet', 'typhoon-network', 'iron-fish',
11+
'concordium', 'zk-money', 'suterusu', 'oxen', 'orchid', 'rotki',
12+
'mobilecoin', 'sienna-network', 'monero', 'zano', 'zeal', 'xx-network',
13+
'mask-network', 'fluidkey', 'webb-protocol', 'wasabi-wallet', 'semaphore',
14+
'incognito', 'umbra-wallet' // added umbra-wallet
15+
];
16+
17+
const validUsecases = [
18+
'wallets', 'defi', 'currency', 'infrastructure', 'computing', 'eth-layer-2',
19+
'hardware', 'vpn', 'did', 'dao', 'bridge', 'messaging', 'browser',
20+
'kyc-solution', 'rpc-provider', 'storage', 'dapps', 'operating-systems',
21+
'nft-community', 'alliances', 'mixing-management', 'data-management',
22+
'donate-charity', 'research-and-development', 'mixing-service', 'node',
23+
'events', 'ai', 'tee', 'mpc', 'fhe', 'sunset', 'other'
24+
];
25+
26+
const validCategories = [
27+
'infrastructure', 'social-and-communications', 'hardware',
28+
'applications', 'defi', 'archived-projects'
29+
];
30+
31+
const validEcosystems = [
32+
'ethereum', 'bitcoin', 'solana', 'cosmos', 'monero', 'other', 'multichain'
33+
];
34+
35+
const validAssets = [
36+
'eth', 'btc', 'usdc', 'usdt', 'dai', 'atom', 'scrt', 'dot',
37+
'sol', 'zcash', 'xmr', 'aleph', 'nam', 'other'
38+
];
39+
40+
async function migrateProject(projectName) {
41+
const filePath = join('src/projects', projectName, 'index.yaml');
42+
try {
43+
const content = await readFile(filePath, 'utf8');
44+
const data = parse(content);
45+
46+
// Fix project_status
47+
if (!data.project_status || data.project_status.live_status === undefined) {
48+
const version = data.project_status?.version || '';
49+
let mainnet = false, testnet = false, live_status = false;
50+
51+
if (version.toLowerCase().includes('mainnet')) {
52+
mainnet = true;
53+
live_status = true;
54+
} else if (version.toLowerCase().includes('testnet')) {
55+
testnet = true;
56+
live_status = true;
57+
}
58+
59+
data.project_status = {
60+
live_status,
61+
version: data.project_status?.version || '',
62+
testnet,
63+
mainnet,
64+
...data.project_status
65+
};
66+
}
67+
68+
// Fix categories
69+
if (data.categories && Array.isArray(data.categories)) {
70+
data.categories = data.categories
71+
.map(c => c.toLowerCase())
72+
.map(c => {
73+
if (c === 'wallets') return 'applications'; // wallets -> applications
74+
return validCategories.includes(c) ? c : 'applications';
75+
});
76+
}
77+
78+
// Fix ecosystem
79+
if (data.ecosystem && Array.isArray(data.ecosystem)) {
80+
data.ecosystem = data.ecosystem
81+
.map(e => e.toLowerCase())
82+
.map(e => validEcosystems.includes(e) ? e : 'other');
83+
}
84+
85+
// Fix assets_used
86+
if (data.assets_used && Array.isArray(data.assets_used)) {
87+
data.assets_used = data.assets_used
88+
.map(a => a.toLowerCase())
89+
.map(a => validAssets.includes(a) ? a : 'other');
90+
}
91+
92+
// Fix usecases
93+
if (data.usecases && Array.isArray(data.usecases)) {
94+
data.usecases = data.usecases
95+
.map(u => u.toLowerCase().replace(/\s+/g, '-')) // "mixing service" -> "mixing-service"
96+
.map(u => validUsecases.includes(u) ? u : 'other')
97+
.filter((v, i, arr) => arr.indexOf(v) === i); // dedupe
98+
}
99+
100+
// Remove invalid top-level properties
101+
delete data.privacy;
102+
delete data.security;
103+
104+
await writeFile(filePath, stringify(data, { lineWidth: 0, indent: 2 }), 'utf8');
105+
console.log(`✓ ${projectName}`);
106+
return { status: 'success' };
107+
} catch (error) {
108+
console.error(`✗ ${projectName}: ${error.message}`);
109+
return { status: 'error' };
110+
}
111+
}
112+
113+
const results = await Promise.all(projects.map(migrateProject));
114+
console.log(`\nDone: ${results.filter(r => r.status === 'success').length}/${projects.length}`);

src/projects/cake-wallet/index.yaml

Lines changed: 14 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,21 @@
11
name: Cake Wallet
22
categories:
3-
- wallets
3+
- applications
44
ecosystem:
5-
- Ethereum
6-
- Monero
7-
- Litecoin
8-
- Haven
5+
- ethereum
6+
- monero
7+
- other
8+
- other
99
usecases:
10-
- Wallet
11-
description: Open-source, non-custodial, privacy-focused multi-currency cryptocurrency
12-
wallet supporting Monero, Bitcoin, Ethereum, Litecoin, and other cryptocurrencies.
13-
Features built-in exchange, native Tor i...
14-
product_launch_day: '2018-01-01'
10+
- other
11+
description: Open-source, non-custodial, privacy-focused multi-currency cryptocurrency wallet supporting Monero, Bitcoin, Ethereum, Litecoin, and other cryptocurrencies. Features built-in exchange, native Tor i...
12+
product_launch_day: 2018-01-01
1513
team:
1614
anonymous: false
1715
teammembers:
18-
- name: Vikrant Sharma
19-
link: https://www.linkedin.com/company/cakewallet
20-
role: Founder & CEO
16+
- name: Vikrant Sharma
17+
link: https://www.linkedin.com/company/cakewallet
18+
role: Founder & CEO
2119
links:
2220
web: https://cakewallet.com
2321
github: https://github.com/cake-tech/cake_wallet
@@ -28,7 +26,10 @@ links:
2826
security_report: https://github.com/web3privacy/explorer-data/blob/main/src/projects/cake-wallet/reports/SECURITY.md
2927
technical_docs: https://github.com/web3privacy/explorer-data/blob/main/src/projects/cake-wallet/reports/TECHNICAL.md
3028
project_status:
29+
live_status: true
3130
version: Mainnet
31+
testnet: false
32+
mainnet: true
3233
sunset: false
3334
blockchain_features:
3435
opensource: true

src/projects/circom/index.yaml

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,11 @@
11
name: Circom
22
categories:
3-
- infrastructure
3+
- infrastructure
44
ecosystem:
5-
- Ethereum
5+
- ethereum
66
usecases:
7-
- Privacy
8-
description: Circom is a specialized compiler and circuit description language for
9-
building zero-knowledge proof applications. Written in Rust, it enables developers
10-
to design arithmetic circuits that are compi...
7+
- other
8+
description: Circom is a specialized compiler and circuit description language for building zero-knowledge proof applications. Written in Rust, it enables developers to design arithmetic circuits that are compi...
119
team:
1210
anonymous: true
1311
links:
@@ -18,7 +16,10 @@ links:
1816
technical_docs: https://github.com/web3privacy/explorer-data/blob/main/src/projects/circom/reports/technical_analysis.md
1917
docs: https://github.com/web3privacy/explorer-data/blob/main/src/projects/circom/README.md
2018
project_status:
19+
live_status: true
2120
version: Mainnet
21+
testnet: false
22+
mainnet: true
2223
sunset: false
2324
blockchain_features:
2425
opensource: true

src/projects/concordium/index.yaml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
name: Concordium
22
categories:
3-
- infrastructure
3+
- infrastructure
44
ecosystem:
5-
- Ethereum
5+
- ethereum
66
usecases:
7-
- Privacy
7+
- other
88
description: The main concordium node implementation.
99
team:
1010
anonymous: true
@@ -15,7 +15,10 @@ links:
1515
security_report: https://github.com/web3privacy/explorer-data/blob/main/src/projects/concordium/reports/SECURITY.md
1616
docs: https://github.com/web3privacy/explorer-data/blob/main/src/projects/concordium/README.md
1717
project_status:
18+
live_status: true
1819
version: Mainnet
20+
testnet: false
21+
mainnet: true
1922
sunset: false
2023
blockchain_features:
2124
opensource: true

src/projects/darkfi/index.yaml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
name: Darkfi
22
categories:
3-
- infrastructure
3+
- infrastructure
44
ecosystem:
5-
- Ethereum
5+
- ethereum
66
usecases:
7-
- Privacy
7+
- other
88
description: Anonymous. Uncensored. Sovereign.
99
team:
1010
anonymous: true
@@ -15,7 +15,10 @@ links:
1515
security_report: https://github.com/web3privacy/explorer-data/blob/main/src/projects/darkfi/reports/SECURITY.md
1616
docs: https://github.com/web3privacy/explorer-data/blob/main/src/projects/darkfi/README.md
1717
project_status:
18+
live_status: true
1819
version: Mainnet
20+
testnet: false
21+
mainnet: true
1922
sunset: false
2023
blockchain_features:
2124
opensource: true

src/projects/deeper-network/index.yaml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
name: Deeper Network
22
categories:
3-
- infrastructure
3+
- infrastructure
44
ecosystem:
5-
- Ethereum
5+
- ethereum
66
usecases:
7-
- Privacy
7+
- other
88
description: deeper chain is the blockchain layer for deeper network.
99
team:
1010
anonymous: true
@@ -14,7 +14,10 @@ links:
1414
security_report: https://github.com/web3privacy/explorer-data/blob/main/src/projects/deeper-network/reports/SECURITY.md
1515
docs: https://github.com/web3privacy/explorer-data/blob/main/src/projects/deeper-network/README.md
1616
project_status:
17+
live_status: true
1718
version: Mainnet
19+
testnet: false
20+
mainnet: true
1821
sunset: false
1922
blockchain_features:
2023
opensource: true

src/projects/elusiv/index.yaml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
name: Elusiv
22
categories:
3-
- infrastructure
3+
- infrastructure
44
ecosystem:
5-
- Ethereum
5+
- ethereum
66
usecases:
7-
- Privacy
7+
- other
88
description: Elusiv Solana program library
99
team:
1010
anonymous: true
@@ -15,7 +15,10 @@ links:
1515
security_report: https://github.com/web3privacy/explorer-data/blob/main/src/projects/elusiv/reports/SECURITY.md
1616
docs: https://github.com/web3privacy/explorer-data/blob/main/src/projects/elusiv/README.md
1717
project_status:
18+
live_status: true
1819
version: Mainnet
20+
testnet: false
21+
mainnet: true
1922
sunset: false
2023
blockchain_features:
2124
opensource: true

src/projects/fileverse/index.yaml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
name: Fileverse
22
categories:
3-
- infrastructure
3+
- infrastructure
44
ecosystem:
5-
- Ethereum
5+
- ethereum
66
usecases:
7-
- Privacy
7+
- other
88
description: Privacy technology project focused on Web3 security and anonymity.
99
team:
1010
anonymous: true
@@ -16,7 +16,10 @@ links:
1616
technical_docs: https://github.com/web3privacy/explorer-data/blob/main/src/projects/fileverse/reports/technical_analysis.md
1717
docs: https://github.com/web3privacy/explorer-data/blob/main/src/projects/fileverse/README.md
1818
project_status:
19+
live_status: true
1920
version: Mainnet
21+
testnet: false
22+
mainnet: true
2023
sunset: false
2124
blockchain_features:
2225
opensource: true

src/projects/findora/index.yaml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
name: Findora
22
categories:
3-
- infrastructure
3+
- infrastructure
44
ecosystem:
5-
- Ethereum
5+
- ethereum
66
usecases:
7-
- Privacy
7+
- other
88
description: Official Implementation of Findora Network.
99
team:
1010
anonymous: true
@@ -15,7 +15,10 @@ links:
1515
security_report: https://github.com/web3privacy/explorer-data/blob/main/src/projects/findora/reports/SECURITY.md
1616
docs: https://github.com/web3privacy/explorer-data/blob/main/src/projects/findora/README.md
1717
project_status:
18+
live_status: true
1819
version: Mainnet
20+
testnet: false
21+
mainnet: true
1922
sunset: false
2023
blockchain_features:
2124
opensource: true

src/projects/firo/index.yaml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
name: Firo
22
categories:
3-
- infrastructure
3+
- infrastructure
44
ecosystem:
5-
- Ethereum
5+
- ethereum
66
usecases:
7-
- Privacy
7+
- other
88
description: The privacy-focused cryptocurrency
99
team:
1010
anonymous: true
@@ -15,7 +15,10 @@ links:
1515
security_report: https://github.com/web3privacy/explorer-data/blob/main/src/projects/firo/reports/SECURITY.md
1616
docs: https://github.com/web3privacy/explorer-data/blob/main/src/projects/firo/README.md
1717
project_status:
18+
live_status: true
1819
version: Mainnet
20+
testnet: false
21+
mainnet: true
1922
sunset: false
2023
blockchain_features:
2124
opensource: true

0 commit comments

Comments
 (0)