master
cyhhao 2 years ago
parent d8ed356c8e
commit cebf21c72e

@ -2,7 +2,6 @@
``` ```
yarn yarn
``` ```
# pkg # pkg
@ -15,4 +14,7 @@ yarn pkg
``` ```
yarn install-mac yarn install-mac
``` ```
# FlatDirectory Contract
https://github.com/ethstorage/evm-large-storage

@ -0,0 +1,366 @@
[
{
"inputs": [
{
"internalType": "uint8",
"name": "slotLimit",
"type": "uint8"
}
],
"stateMutability": "nonpayable",
"type": "constructor"
},
{
"stateMutability": "nonpayable",
"type": "fallback"
},
{
"inputs": [
{
"internalType": "address",
"name": "newOwner",
"type": "address"
}
],
"name": "changeOwner",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes",
"name": "name",
"type": "bytes"
},
{
"internalType": "uint256",
"name": "chunkId",
"type": "uint256"
}
],
"name": "chunkSize",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
},
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes",
"name": "name",
"type": "bytes"
}
],
"name": "countChunks",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "defaultFile",
"outputs": [
{
"internalType": "bytes",
"name": "",
"type": "bytes"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "destruct",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes",
"name": "name",
"type": "bytes"
},
{
"internalType": "uint256",
"name": "chunkId",
"type": "uint256"
}
],
"name": "getChunkHash",
"outputs": [
{
"internalType": "bytes32",
"name": "",
"type": "bytes32"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "isOptimize",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "owner",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes",
"name": "name",
"type": "bytes"
}
],
"name": "read",
"outputs": [
{
"internalType": "bytes",
"name": "",
"type": "bytes"
},
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes",
"name": "name",
"type": "bytes"
},
{
"internalType": "uint256",
"name": "chunkId",
"type": "uint256"
}
],
"name": "readChunk",
"outputs": [
{
"internalType": "bytes",
"name": "",
"type": "bytes"
},
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "refund",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes",
"name": "name",
"type": "bytes"
}
],
"name": "remove",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes",
"name": "name",
"type": "bytes"
},
{
"internalType": "uint256",
"name": "chunkId",
"type": "uint256"
}
],
"name": "removeChunk",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [],
"name": "resolveMode",
"outputs": [
{
"internalType": "bytes32",
"name": "",
"type": "bytes32"
}
],
"stateMutability": "pure",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes",
"name": "_defaultFile",
"type": "bytes"
}
],
"name": "setDefault",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes",
"name": "name",
"type": "bytes"
}
],
"name": "size",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes",
"name": "name",
"type": "bytes"
},
{
"internalType": "uint256",
"name": "chunkId",
"type": "uint256"
}
],
"name": "truncate",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes",
"name": "name",
"type": "bytes"
},
{
"internalType": "bytes",
"name": "data",
"type": "bytes"
}
],
"name": "write",
"outputs": [],
"stateMutability": "payable",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes",
"name": "name",
"type": "bytes"
},
{
"internalType": "uint256",
"name": "chunkId",
"type": "uint256"
},
{
"internalType": "bytes",
"name": "data",
"type": "bytes"
}
],
"name": "writeChunk",
"outputs": [],
"stateMutability": "payable",
"type": "function"
}
]

@ -59,6 +59,7 @@ GitRemoteHelper({
force: boolean; force: boolean;
}[]; }[];
}) => { }) => {
log("push", p) log("push", p)
return '\n'; return '\n';
}, },
@ -66,4 +67,5 @@ GitRemoteHelper({
}).catch((error: any) => { }).catch((error: any) => {
console.error("wtf"); console.error("wtf");
console.error(error); console.error(error);
}); });
Loading…
Cancel
Save