snapborg

0.2.0 • Public • Published

Snapshot Governance

Scrapes snapshot to pin the IPFS files to your own node.

Quickstart

you can ignore the Makefile and Dockerfile no reason to use them

  1. Install via npm/yarn, startup your local IPFS daemon

Note there is a script check-ipfs.sh if you are unsure if your IPFS daemon is working!

  1. configure the run.sh with your parameters, the default is setup to Yearn Finance's snapshot (ychad.eth)

  2. Run the command

./run.sh
  1. Examine the directory data/

How to Run

Copy and rename .env.example to .env and replace the variables with their corresponding values.

cp .env.example .env

Scrape Snapshot API and sync files to IPFS

make scrape

How it works

  • scrape.ts hits snapshots API to get all the proposals
  • It writes the file proposals.txt to use for ipfs-sync
  • It then gets all the votes from the proposals from snapshots api
  • It writes the file votes.txt
  • It then runs ipfs-sync on these four files
  • All the scripts are de-dupped so that this could run on a VM in the cloud, ping it once a day, and it will only append to the txt files. Then ipfs-sync already skips over dupes.

Readme

Keywords

none

Package Sidebar

Install

npm i snapborg

Weekly Downloads

0

Version

0.2.0

License

MIT

Unpacked Size

17.6 kB

Total Files

18

Last publish

Collaborators

  • sambacha