-
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.
Merge pull request #194 from VenusProtocol/pre-add-semantic-release
Pre add semantic release
- Loading branch information
Showing
48 changed files
with
6,239 additions
and
2,034 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,7 +11,7 @@ jobs: | |
|
||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: 18 | ||
node-version: 20 | ||
cache: "yarn" | ||
|
||
- name: Install deps | ||
|
@@ -62,16 +62,16 @@ jobs: | |
|
||
- name: Generate Core Pool graphql types | ||
run: | | ||
docker exec -i subgraph-hardhat-node yarn workspace venus-subgraph run prepare:docker | ||
docker exec -i subgraph-hardhat-node yarn workspace venus-subgraph run codegen | ||
docker exec -i subgraph-hardhat-node yarn workspace venus-subgraph run create:docker | ||
docker exec -i subgraph-hardhat-node yarn workspace venus-subgraph run deploy:docker | ||
docker exec -i subgraph-hardhat-node yarn workspace @venusprotocol/core-pool-subgraph run prepare:docker | ||
docker exec -i subgraph-hardhat-node yarn workspace @venusprotocol/core-pool-subgraph run codegen | ||
docker exec -i subgraph-hardhat-node yarn workspace @venusprotocol/core-pool-subgraph run create:docker | ||
docker exec -i subgraph-hardhat-node yarn workspace @venusprotocol/core-pool-subgraph run deploy:docker | ||
sleep 5s | ||
docker exec -i subgraph-hardhat-node yarn workspace venus-subgraph run generate-subgraph-types | ||
docker exec -i subgraph-hardhat-node yarn workspace @venusprotocol/core-pool-subgraph run generate-subgraph-types | ||
- name: Run Core Pool integration tests | ||
run: | | ||
docker exec -i subgraph-hardhat-node yarn workspace venus-subgraph run test:integration --bail | ||
docker exec -i subgraph-hardhat-node yarn workspace @venusprotocol/core-pool-subgraph run test:integration --bail | ||
- name: Stop containers | ||
if: always() | ||
|
@@ -95,16 +95,16 @@ jobs: | |
|
||
- name: Generate Isolated Pools graphql types | ||
run: | | ||
docker exec -i subgraph-hardhat-node yarn workspace isolated-pools-subgraph run prepare:docker | ||
docker exec -i subgraph-hardhat-node yarn workspace isolated-pools-subgraph run codegen | ||
docker exec -i subgraph-hardhat-node yarn workspace isolated-pools-subgraph run create:docker | ||
docker exec -i subgraph-hardhat-node yarn workspace isolated-pools-subgraph run deploy:docker | ||
docker exec -i subgraph-hardhat-node yarn workspace @venusprotocol/isolated-pools-subgraph run prepare:docker | ||
docker exec -i subgraph-hardhat-node yarn workspace @venusprotocol/isolated-pools-subgraph run codegen | ||
docker exec -i subgraph-hardhat-node yarn workspace @venusprotocol/isolated-pools-subgraph run create:docker | ||
docker exec -i subgraph-hardhat-node yarn workspace @venusprotocol/isolated-pools-subgraph run deploy:docker | ||
sleep 5s | ||
docker exec -i subgraph-hardhat-node yarn workspace isolated-pools-subgraph run generate-subgraph-types | ||
docker exec -i subgraph-hardhat-node yarn workspace @venusprotocol/isolated-pools-subgraph run generate-subgraph-types | ||
- name: Run Isolated Pools integration tests | ||
run: | | ||
docker exec -i subgraph-hardhat-node yarn workspace isolated-pools-subgraph run test:integration --bail | ||
docker exec -i subgraph-hardhat-node yarn workspace @venusprotocol/isolated-pools-subgraph run test:integration --bail | ||
- name: Stop containers | ||
if: always() | ||
|
@@ -128,19 +128,49 @@ jobs: | |
|
||
- name: Generate Governance graphql types | ||
run: | | ||
docker exec -i subgraph-hardhat-node yarn workspace venus-governance-subgraph run prepare:docker | ||
docker exec -i subgraph-hardhat-node yarn workspace venus-governance-subgraph run codegen | ||
docker exec -i subgraph-hardhat-node yarn workspace venus-governance-subgraph run create:docker | ||
docker exec -i subgraph-hardhat-node yarn workspace venus-governance-subgraph run deploy:docker | ||
docker exec -i subgraph-hardhat-node yarn workspace @venusprotocol/governance-subgraph run prepare:docker | ||
docker exec -i subgraph-hardhat-node yarn workspace @venusprotocol/governance-subgraph run codegen | ||
docker exec -i subgraph-hardhat-node yarn workspace @venusprotocol/governance-subgraph run create:docker | ||
docker exec -i subgraph-hardhat-node yarn workspace @venusprotocol/governance-subgraph run deploy:docker | ||
sleep 5s | ||
docker exec -i subgraph-hardhat-node yarn workspace venus-governance-subgraph run generate-subgraph-types | ||
docker exec -i subgraph-hardhat-node yarn workspace @venusprotocol/governance-subgraph run generate-subgraph-types | ||
- name: Run Governance integration integration tests | ||
run: | | ||
docker exec -i subgraph-hardhat-node yarn workspace venus-governance-subgraph run test:integration --bail | ||
docker exec -i subgraph-hardhat-node yarn workspace @venusprotocol/governance-subgraph run test:integration --bail | ||
- name: Stop containers | ||
if: always() | ||
run: | | ||
docker compose down -v | ||
docker system prune -f -a --volumes | ||
release: | ||
runs-on: ubuntu-20.04 | ||
# needs: [unit-test, lint, integration-test-core-pool, integration-test-isolated-pools, integration-test-governance] | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: 20 | ||
cache: "yarn" | ||
|
||
- name: Install deps | ||
run: yarn | ||
|
||
- name: Version subgraphs | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.VENUS_TOOLS_TOKEN }} | ||
GIT_AUTHOR_NAME: Venus Tools | ||
GIT_AUTHOR_EMAIL: [email protected] | ||
GIT_COMMITTER_NAME: Venus Tools | ||
GIT_COMMITTER_EMAIL: [email protected] | ||
run: | | ||
yarn workspace @venusprotocol/cross-chain-governance-subgraph run semantic-release | ||
yarn workspace @venusprotocol/etherfi-promo-subgraph run semantic-release | ||
yarn workspace @venusprotocol/isolated-pools-subgraph run semantic-release | ||
yarn workspace @venusprotocol/protocol-reserve-subgraph run semantic-release | ||
yarn workspace @venusprotocol/core-pool-subgraph run semantic-release | ||
yarn workspace @venusprotocol/governance-subgraph run semantic-release |
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 |
---|---|---|
@@ -1,10 +1,17 @@ | ||
module.exports = { | ||
...require('prettier-airbnb-config'), | ||
trailingComma: 'all', | ||
bracketSpacing: true, | ||
importOrder: [ | ||
'^[./]', | ||
], | ||
importOrderSeparation: true, | ||
importOrderSortSpecifiers: true, | ||
singleQuote: true, | ||
printWidth: 100, | ||
arrowParens: "avoid", | ||
proseWrap: "always", | ||
quoteProps: "as-needed", | ||
semi: true, | ||
tabWidth: 2, | ||
useTabs: false | ||
}; |
This file was deleted.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
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,5 @@ | ||
module.exports = { | ||
extends: ["@commitlint/config-conventional"], | ||
ignores: [commit => commit.includes("[skip ci]"), commit => commit.includes("Merge pull request")], | ||
"type-enum": [2, "always", ["build", "chore", "ci", "docs", "feat", "fix", "refactor", "test"]], | ||
}; |
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 |
---|---|---|
@@ -1,5 +1,5 @@ | ||
{ | ||
"name": "subgraphs", | ||
"name": "@venusprotocol/subgraphs", | ||
"private": true, | ||
"version": "0.0.0", | ||
"repository": "https://github.com/VenusProtocol/subgraphs", | ||
|
@@ -13,6 +13,7 @@ | |
], | ||
"scripts": { | ||
"codegen": "yarn workspaces foreach run codegen", | ||
"semantic-release": "yarn workspaces foreach run semantic-release", | ||
"build:docker": "yarn workspaces foreach run build:docker", | ||
"build:chapel": "yarn workspaces foreach run build:chapel", | ||
"build:bsc": "yarn workspaces foreach run build:bsc", | ||
|
@@ -33,6 +34,8 @@ | |
}, | ||
"devDependencies": { | ||
"@chainlink/contracts": "^0.5.1", | ||
"@commitlint/cli": "^17.0.3", | ||
"@commitlint/config-conventional": "^17.0.3", | ||
"@graphprotocol/client-cli": "3.0.0", | ||
"@graphprotocol/graph-cli": "^0.80.0", | ||
"@graphprotocol/graph-ts": "^0.35.1", | ||
|
@@ -41,7 +44,10 @@ | |
"@nomicfoundation/hardhat-network-helpers": "^1.0.4", | ||
"@nomiclabs/hardhat-ethers": "^2.1.1", | ||
"@nomiclabs/hardhat-etherscan": "^3.1.0", | ||
"@trivago/prettier-plugin-sort-imports": "^3.2.0", | ||
"@semantic-release/changelog": "^6.0.3", | ||
"@semantic-release/exec": "^6.0.3", | ||
"@semantic-release/git": "^10.0.1", | ||
"@trivago/prettier-plugin-sort-imports": "^4.3.0", | ||
"@typechain/ethers-v5": "^10.1.0", | ||
"@typechain/hardhat": "^6.1.2", | ||
"@types/mocha": "^9.1.1", | ||
|
@@ -74,15 +80,15 @@ | |
"module-alias": "^2.2.2", | ||
"mustache": "^4.2.0", | ||
"patch-package": "6.5.1", | ||
"prettier": "^2.5.1", | ||
"prettier-airbnb-config": "^1.0.0", | ||
"prettier": "^3.0.3", | ||
"ts-node": "^10.9.2", | ||
"typechain": "^8.1.0", | ||
"typescript": "^4.8.4" | ||
}, | ||
"resolutions": { | ||
"@venusprotocol/governance-contracts": "2.5.0-dev.4", | ||
"@venusprotocol/venus-protocol": "9.3.0" | ||
"@venusprotocol/venus-protocol": "9.3.0", | ||
"prettier": "^3.0.3" | ||
}, | ||
"husky": { | ||
"hooks": { | ||
|
@@ -92,5 +98,8 @@ | |
"packageManager": "[email protected]", | ||
"_moduleAliases": { | ||
"@nomiclabs/hardhat-ethers": "node_modules/hardhat-deploy-ethers" | ||
}, | ||
"dependencies": { | ||
"semantic-release-yarn": "^3.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
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,86 @@ | ||
{ | ||
"extends": "semantic-release-monorepo", | ||
"plugins": [ | ||
[ | ||
"@semantic-release/commit-analyzer", | ||
{ | ||
"preset": "conventionalcommits", | ||
"releaseRules": [ | ||
{ | ||
"breaking": true, | ||
"release": "major" | ||
}, | ||
{ | ||
"type": "build", | ||
"release": false | ||
}, | ||
{ | ||
"type": "chore", | ||
"release": false | ||
}, | ||
{ | ||
"type": "docs", | ||
"release": "patch" | ||
}, | ||
{ | ||
"type": "ci", | ||
"release": false | ||
}, | ||
{ | ||
"type": "feat", | ||
"release": "minor" | ||
}, | ||
{ | ||
"type": "fix", | ||
"release": "patch" | ||
}, | ||
{ | ||
"type": "refactor", | ||
"release": "patch" | ||
}, | ||
{ | ||
"type": "test", | ||
"release": false | ||
} | ||
], | ||
"parserOpts": { | ||
"noteKeywords": [ | ||
"BREAKING CHANGE", | ||
"BREAKING CHANGES" | ||
] | ||
} | ||
} | ||
], | ||
[ | ||
"@semantic-release/release-notes-generator", | ||
{ | ||
"preset": "conventionalcommits" | ||
} | ||
], | ||
[ | ||
"semantic-release-yarn", | ||
{ | ||
"npmPublish": false | ||
} | ||
], | ||
[ | ||
"@semantic-release/git", | ||
{ | ||
"assets": [ | ||
"package.json", | ||
"yarn.lock" | ||
], | ||
"message": "chore(release): ${nextRelease.version} [skip ci]\n\n${nextRelease.notes}" | ||
} | ||
] | ||
], | ||
"branches": [ | ||
{ | ||
"name": "main" | ||
}, | ||
{ | ||
"name": "pre-*", | ||
"prerelease": "pre" | ||
} | ||
] | ||
} |
Oops, something went wrong.