fix: add new protocl script

This commit is contained in:
yj 2021-04-22 12:46:44 -05:00
parent 9cff4293fa
commit f17780856f
2 changed files with 40 additions and 1 deletions

View File

@ -8,7 +8,16 @@ do
echo "Pass in the name of the protocol whose info you want to add. e.g: ./add_new_protocol.sh rarible"
else
mkdir -p ./$arg
mkdir -p ./$arg/calls
mkdir -p ./$arg/resources
mkdir -p ./$arg/resources/calls
mkdir -p ./$arg/resources/Gov Weekly
mkdir -p ./$arg/contracts
touch ./$arg/contracts/governance.json
touch ./$arg/contracts/token.json
touch ./$arg/index.json
touch ./$arg/events.json
touch ./$arg/overview.md
touch ./$arg/logo.png

30
types.d.ts vendored Normal file
View File

@ -0,0 +1,30 @@
import * as t from "io-ts";
export declare const ProtocolIo: t.TypeC<{
cname: t.StringC;
name: t.StringC;
description: t.StringC;
path: t.StringC;
previousPaths: t.UnionC<[t.ArrayC<t.StringC>, t.UndefinedC]>;
folder: t.StringC;
type: t.UnionC<[t.LiteralC<"snapshot">, t.LiteralC<"compoundish">]>;
suffix: t.StringC;
coinGeckoPriceString: t.StringC;
tokenContractAddress: t.StringC;
governanceContractAddress: t.UnionC<[t.StringC, t.UndefinedC]>;
isEnabled: t.BooleanC;
hasOnchain: t.BooleanC;
isHybrid: t.BooleanC;
hasDelegation: t.BooleanC;
snapshotSpaceName: t.UnionC<[t.StringC, t.UndefinedC]>;
invalidSnapshots: t.UnionC<[t.ArrayC<t.StringC>, t.UndefinedC]>;
branding: t.UnionC<[t.PartialC<{
primaryColor: t.StringC;
accentColor: t.StringC;
}>, t.UndefinedC]>;
discourseForum: t.UnionC<[t.PartialC<{
url: t.StringC;
categoryId: t.StringC;
}>, t.UndefinedC]>;
safeAddress: t.UnionC<[t.StringC, t.NullC]>;
}>;
export declare type Protocol = t.TypeOf<typeof ProtocolIo>;