Batch upload your files to Arweave.
npm installor
yarn installName your Arweave key as arweave-key.json and put it in the root directory.
- Store the files to be uploaded in
./upload/folder. - Prepare the CSV file with
filenameandipfsHashfields: Thefilenamefield should list the filenames match files in./upload/folder. - Launch the program:
The resulting Arweave hash will be show on both console and
node index.js [list.csv]
./output-list.csv.
Note that both filename and ipfsHash fields are optinal, but either one should be provided for each row of data:
- Program will check and update the
ipfsHashif local file is found. - Program will get file from IPFS and store in
./upload/folder if local file isn't found. - Program will skip uploading the file if file with the same
ipfsHashtag can already be found in Arweave.
Note that the mime type of text-based formats like .txt, .csv, .svg, etc is difficult to detect. Program will not add a mime tag for files loaded from IPFS when uploading.
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.