/castore

Primary LanguageJavaScriptMIT LicenseMIT

Content addressable storage download - castore

API

"use strict";
const castore = require('castore');

//recommended storage hash
var store_path = (file_md5) => {
  return sprintf("somedirectory/%s/%s/%s", file_md5.substr(0, 2), file_md5.substr(2, 1), file_md5);
}


await castore("http://example.com/some/path?stuffs", "aa00c22a1a11a54a54a54a5a4", store_path);
//now, if needed, file has been downloaded

Build Status Coverage Status Version License Code style

References

Credits