-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(deployments): Auto-publish deployments to npm [SIM-236] (#35)
- Loading branch information
Showing
11 changed files
with
2,425 additions
and
72 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
titleOnly: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
{ | ||
"branches": [ | ||
{ "name": "master" } | ||
], | ||
"plugins": [ | ||
["@semantic-release/commit-analyzer", { | ||
"preset": "angular", | ||
"releaseRules": [ | ||
{"type": "feat", "scope":"ethereum/deployments/outputs/1-production.json", "release": "minor"}, | ||
{"type": "feat", "scope":"ethereum/deployments/outputs/1-staging.json", "release": "minor"}, | ||
{"type": "feat", "scope":"optimism/deployments/outputs/10-production.json", "release": "minor"}, | ||
{"type": "feat", "scope":"optimism/deployments/outputs/10-staging.json", "release": "minor"}, | ||
{"type": "feat", "scope":"polygon/deployments/outputs/137-production.json", "release": "minor"}, | ||
{"type": "feat", "scope":"polygon/deployments/outputs/137-staging.json", "release": "minor"} | ||
] | ||
}], | ||
"@semantic-release/release-notes-generator", | ||
"@semantic-release/npm", | ||
"@semantic-release/github" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
# set-v2-strategies-deployments | ||
|
||
This repository contains contract addresses for all [set-v2-strategies][1] staging and production deployments. | ||
|
||
SetProtocolV2 Strategies currently deploys to three networks: | ||
+ Ethereum | ||
+ Optimism | ||
+ Polygon | ||
|
||
## Install | ||
|
||
``` | ||
yarn add @setprotocol/set-v2-strategies-deployments | ||
``` | ||
|
||
## Usage | ||
|
||
The package consists of `.json` files located and usable as below: | ||
|
||
``` | ||
deployments/<network_name>/production.json | ||
deployments/<network_name>/staging.json | ||
``` | ||
|
||
```js | ||
> const production = require("@setprotocol/set-v2-strategies-deployments/deployments/ethereum/production"); | ||
> production.addresses | ||
{ | ||
"ManagerCore": "0x7a397B3ed39E84C6181e47309CE940574290f4e7", | ||
"DelegatedManagerFactory": "0x5132044c71b98315bDD5D8E6900bcf93EB2EbeC0", | ||
"IssuanceExtension": "0x05C5c57E5E75FC8EaD83FE06ebe4aCc471Fb2948", | ||
... | ||
} | ||
``` | ||
|
||
|
||
[1]: https://github.com/SetProtocol/set-v2-strategies |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
{ | ||
"name": "@setprotocol/set-v2-strategies-deployments", | ||
"version": "0.0.1", | ||
"description": "Contract addresses for all SetProtocol Strategies (V2) staging and production deployments", | ||
"files": [ | ||
"deployments" | ||
], | ||
"scripts": { | ||
"postpublish": "./scripts/postpublish.sh", | ||
"semantic-release": "semantic-release" | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "git+https://github.com/SetProtocol/set-v2-strategies-deployments.git" | ||
}, | ||
"author": "felix2feng", | ||
"license": "MIT", | ||
"homepage": "https://github.com/SetProtocol/set-v2-strategies-deployments", | ||
"devDependencies": { | ||
"semantic-release": "^19.0.2" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
#!/usr/bin/env bash | ||
|
||
set -o errexit | ||
|
||
cp github.README.md README.md | ||
rm github.README.md | ||
|
||
cp github.package.json package.json | ||
rm github.package.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
#!/usr/bin/env bash | ||
|
||
set -o errexit | ||
|
||
rm -rf deployments | ||
|
||
# Create publication folder | ||
mkdir deployments | ||
mkdir deployments/ethereum | ||
mkdir deployments/optimism | ||
mkdir deployments/polygon | ||
|
||
# Copy publishable assets to publication folder | ||
cp ethereum/deployments/outputs/1-production.json deployments/ethereum/production.json | ||
cp ethereum/deployments/outputs/1-staging.json deployments/ethereum/staging.json | ||
|
||
cp optimism/deployments/outputs/10-production.json deployments/optimism/production.json | ||
cp optimism/deployments/outputs/10-staging.json deployments/optimism/staging.json | ||
|
||
cp polygon/deployments/outputs/137-production.json deployments/polygon/production.json | ||
cp polygon/deployments/outputs/137-staging.json deployments/polygon/staging.json | ||
|
||
# Copy npm README version to README (this will be reversed in the postpublish hook) | ||
cp README.md github.README.md | ||
cp publish/npm.README.md README.md | ||
|
||
cp package.json github.package.json | ||
cp publish/npm.package.json package.json |
Oops, something went wrong.