Giter Site home page Giter Site logo

vbxprotocol-development / blockscan-tags Goto Github PK

View Code? Open in Web Editor NEW

This project forked from kleros/etherscan-tags

0.0 0.0 0.0 482 KB

Posts curate contract tags to blockscan

License: MIT License

Shell 9.00% JavaScript 13.88% TypeScript 77.12%

blockscan-tags's Introduction

Blockscan Tags

Checks Curate for contract tags and posts them to an endpoint. Works nicely with cron.

Note: At the time of publication, there is no endpoint that lets us check if a given tag was already posted, so we keep a local DB to avoid posting the same tag again. Losing this database means the tool will submit everything again.

Volta

This project uses volta.sh for node version management. See package.json for the version.

Running

Duplicate .env.example and fill the env variables. You can use network specific files such as .env.kovan and then yarn start:kovan.

Cron Job

This script plays well with cron. Here is a suggetsion on how to use it with volta.sh.

1- In the project folder, vim script-mainnet.sh paste the following and save. 2- Paste the following:

#!/bin/bash

cd /home/ubuntu/blockscan-tags

PATH=/home/ubuntu/.volta/bin:$PATH

echo "Using volta version $(volta --version)"
echo "Using node version $(node --version)"
yarn start:mainnet

3- Give script execution rights chmod +x script-mainnet.sh. 4- Setup the cron job: crontab -e and add 0 * * * * cd ~/blockscan-tags && ./script-mainnet.sh >> output-mainnet.log 2>&1

Debugging

If using vscode, use the following to debug.

.vscode/launch.json:

{
  "version": "0.2.0",
  "configurations": [
    {
      "type": "node",
      "request": "attach",
      "name": "Typescript Server",
      "protocol": "inspector",
      "port": 9229,
      "restart": true,
      "localRoot": "${workspaceFolder}",
      "remoteRoot": "."
    }
  ]
}

blockscan-tags's People

Contributors

eccentricexit avatar greenlucid avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.