Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename Web3API to Polywrap #923

Merged
merged 17 commits into from
Jun 16, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
6 changes: 3 additions & 3 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
module.exports = {
root: true,
ignorePatterns: [
"**/w3/**/*.*",
"**/wrap/**/*.*",
"**/infra-modules/**/*.*",
"**/build/**/*.*",
"**/__tests__/**/*.*",
Expand Down Expand Up @@ -40,8 +40,8 @@ module.exports = {
],
format: ["camelCase"], leadingUnderscore: "allow"
},
//web3 api host methods doesn"t satisfy neither camel or snake
{selector: ["objectLiteralMethod", "typeMethod"], filter: {regex: "^_w3_.*", match: true}, format: null},
//wrap host methods doesn"t satisfy neither camel or snake
{selector: ["objectLiteralMethod", "typeMethod"], filter: {regex: "^_wrap_.*", match: true}, format: null},
//variable must be in camel or upper case
{selector: "variable", format: ["camelCase", "UPPER_CASE"], leadingUnderscore: "allow"},
//classes and types must be in PascalCase
Expand Down
22 changes: 11 additions & 11 deletions .github/workflows/release-pr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
if: |
github.event.issue.pull_request &&
startsWith(github.event.comment.body, '/workflows/release-pr') &&
github.event.comment.user.login != 'web3-api-build-bot'
github.event.comment.user.login != 'polywrap-build-bot'
runs-on: ubuntu-18.04
steps:
- name: Checkout
Expand All @@ -31,7 +31,7 @@ jobs:
if: ${{env.IS_PUBLISHER == 'false'}}
uses: actions/github-script@0.8.0
with:
github-token: ${{secrets.WEB3_API_BUILD_BOT_PAT}}
github-token: ${{secrets.POLYWRAP_BUILD_BOT_PAT}}
script: |
github.issues.createComment({
issue_number: context.issue.number,
Expand Down Expand Up @@ -62,7 +62,7 @@ jobs:
if: ${{env.TAG_EXISTS == 'true'}}
uses: actions/github-script@0.8.0
with:
github-token: ${{secrets.WEB3_API_BUILD_BOT_PAT}}
github-token: ${{secrets.POLYWRAP_BUILD_BOT_PAT}}
script: |
github.issues.createComment({
issue_number: context.issue.number,
Expand All @@ -87,15 +87,15 @@ jobs:
ref: ${{ github.event.pull_request.head.ref }}

- name: Set env.BOT to Build Bot's Username
run: echo BOT=web3-api-build-bot >> $GITHUB_ENV
run: echo BOT=polywrap-build-bot >> $GITHUB_ENV

- name: Read VERSION into env.RELEASE_VERSION
run: echo RELEASE_VERSION=$(cat VERSION) >> $GITHUB_ENV

- name: Building Release PR...
uses: actions/github-script@0.8.0
with:
github-token: ${{secrets.WEB3_API_BUILD_BOT_PAT}}
github-token: ${{secrets.POLYWRAP_BUILD_BOT_PAT}}
script: |
github.issues.createComment({
issue_number: context.issue.number,
Expand Down Expand Up @@ -123,7 +123,7 @@ jobs:
git config --global user.name '${{env.BOT}}'
git config --global user.email '${{env.BOT}}@users.noreply.github.com'
env:
GITHUB_TOKEN: ${{ secrets.WEB3_API_BUILD_BOT_PAT }}
GITHUB_TOKEN: ${{ secrets.POLYWRAP_BUILD_BOT_PAT }}

- name: Apply Rust Version & Commit
working-directory: ./packages/wasm/rs
Expand All @@ -139,18 +139,18 @@ jobs:
id: cpr
uses: peter-evans/create-pull-request@v3
with:
token: ${{ secrets.WEB3_API_BUILD_BOT_PAT }}
token: ${{ secrets.POLYWRAP_BUILD_BOT_PAT }}
push-to-fork: ${{env.BOT}}/${{github.event.repository.name}}
branch: release/${{env.RELEASE_VERSION}}
base: ${{ github.event.pull_request.head.ref }}
committer: GitHub <noreply@github.com>
author: ${{env.BOT}} <${{env.BOT}}@users.noreply.github.com>
commit-message: "${{env.RELEASE_VERSION}}"
title: 'Web3API ${{env.RELEASE_VERSION}}'
title: 'Polywrap ${{env.RELEASE_VERSION}}'
body: |
## Web3API ${{env.RELEASE_VERSION}}
## Polywrap ${{env.RELEASE_VERSION}}

TODO: Add "Web3API-Release" Label
TODO: Add "Polywrap-Release" Label

### Breaking Changes

Expand All @@ -167,7 +167,7 @@ jobs:
- name: Release PR Created...
uses: actions/github-script@0.8.0
with:
github-token: ${{secrets.WEB3_API_BUILD_BOT_PAT}}
github-token: ${{secrets.POLYWRAP_BUILD_BOT_PAT}}
script: |
github.issues.createComment({
issue_number: context.issue.number,
Expand Down
16 changes: 8 additions & 8 deletions .github/workflows/release-publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
Publish-GitHub-Release:
name: GitHub Release
if: |
github.event.pull_request.user.login == 'web3-api-build-bot' &&
github.event.pull_request.user.login == 'polywrap-build-bot' &&
github.event.pull_request.merged == true
runs-on: ubuntu-18.04
steps:
Expand Down Expand Up @@ -82,7 +82,7 @@ jobs:
Publish-NPM-Release:
name: NPM Release
if: |
github.event.pull_request.user.login == 'web3-api-build-bot' &&
github.event.pull_request.user.login == 'polywrap-build-bot' &&
github.event.pull_request.merged == true
runs-on: ubuntu-18.04
steps:
Expand All @@ -106,7 +106,7 @@ jobs:
if: ${{env.TAG_EXISTS}} == 'false'
run: |
npm config set registry https://registry.npmjs.org/
npm config set //registry.npmjs.org/:_authToken=${{secrets.WEB3_API_BUILD_BOT_NPM_PAT}}
npm config set //registry.npmjs.org/:_authToken=${{secrets.POLYWRAP_BUILD_BOT_NPM_PAT}}
echo $(npm whoami --registry https://registry.npmjs.org/)

- name: Install JS dependencies
Expand All @@ -121,7 +121,7 @@ jobs:
if: ${{env.TAG_EXISTS}} == 'false'
run: yarn publish:npm
env:
NPM_AUTH_TOKEN: ${{secrets.WEB3_API_BUILD_BOT_NPM_PAT}}
NPM_AUTH_TOKEN: ${{secrets.POLYWRAP_BUILD_BOT_NPM_PAT}}

- uses: actions/github-script@0.8.0
if: ${{env.TAG_EXISTS}} == 'false'
Expand All @@ -132,13 +132,13 @@ jobs:
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: '**[NPM Release Published](https://www.npmjs.com/search?q=%40web3api) `${{env.RELEASE_VERSION}}`** 🎉'
body: '**[NPM Release Published](https://www.npmjs.com/search?q=%40polywrap) `${{env.RELEASE_VERSION}}`** 🎉'
})

Publish-Crates-dot-io-Release:
name: crates.io Release
if: |
github.event.pull_request.user.login == 'web3-api-build-bot' &&
github.event.pull_request.user.login == 'polywrap-build-bot' &&
github.event.pull_request.merged == true
runs-on: ubuntu-18.04
steps:
Expand Down Expand Up @@ -169,7 +169,7 @@ jobs:
- name: Upload Rust Crates To Crates.io
if: ${{env.TAG_EXISTS}} == 'false'
working-directory: ./packages/wasm/rs
run: cargo publish --token ${{secrets.WEB3_API_BUILD_BOT_CRATES_PAT}}
run: cargo publish --token ${{secrets.POLYWRAP_BUILD_BOT_CRATES_PAT}}

- uses: actions/github-script@0.8.0
if: ${{env.TAG_EXISTS}} == 'false'
Expand All @@ -180,5 +180,5 @@ jobs:
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: '**[Crates.io Release Published](https://crates.io/search?q=web3api) `${{env.RELEASE_VERSION}}`** 🎉'
body: '**[Crates.io Release Published](https://crates.io/search?q=polywrap) `${{env.RELEASE_VERSION}}`** 🎉'
})
5 changes: 3 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,15 @@ yarn-error.log
coverage
.vscode
*.log
w3
.w3
wrap
dOrgJelli marked this conversation as resolved.
Show resolved Hide resolved
.polywrap
.DS_Store
report.*
target
**/*.rs.bk
Cargo.lock
bin
!packages/cli/bin
pkg
wasm-pack.log
.env
2 changes: 1 addition & 1 deletion dependencies/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"dependencies": {
"@web3api/cli": "latest"
"polywrap": "latest"
},
"resolutions": {
"colors": "1.4.0"
Expand Down
32 changes: 15 additions & 17 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
{
"name": "root",
"description": "Web3API Monorepo",
"description": "Polywrap Monorepo",
"license": "MIT",
"private": true,
"repository": {
"type": "git",
"url": "https://github.com/web3-api/monorepo.git"
"url": "https://github.com/polywrap/monorepo.git"
},
"workspaces": {
"packages": [
"./packages/apis/**",
"./packages/cli",
"./packages/core-interfaces/**",
"./packages/js/**",
Expand All @@ -23,25 +22,24 @@
},
"scripts": {
"reset": "yarn clean && yarn && yarn build",
"clean": "npx rimraf ./**/node_modules ./**/yarn.lock ./**/build ./**/coverage ./**/.w3",
"clean": "npx rimraf ./**/node_modules ./**/yarn.lock ./**/build ./**/coverage ./**/.polywrap",
"dependencies:install": "cd dependencies && yarn",
"preinstall": "yarn dependencies:install",
"build": "yarn build:core && yarn build:plugins && yarn build:client && yarn build:test-env && yarn build:cli && yarn build:plugins:patch",
"build:core": "lerna run build --no-private --ignore @web3api/*-plugin-js --ignore @web3api/cli* --ignore @web3api/react --ignore @web3api/test-env-js",
"build:plugins": "lerna run build --scope @web3api/*-plugin-js --concurrency 1",
"build:client": "lerna run build --scope @web3api/client-js --scope @web3api/react",
"build:test-env": "lerna run build --scope @web3api/test-env-js",
"build:cli": "lerna run build --scope @web3api/cli",
"build:plugins:patch": "lerna run codegen:patch --scope @web3api/*-plugin-js --concurrency 1",
"build:core": "lerna run build --no-private --ignore @polywrap/*-plugin-js --ignore polywrap --ignore @polywrap/client-js --ignore @polywrap/react --ignore @polywrap/test-env-js",
"build:plugins": "lerna run build --scope @polywrap/*-plugin-js --concurrency 1",
"build:client": "lerna run build --scope @polywrap/client-js --scope @polywrap/react",
"build:test-env": "lerna run build --scope @polywrap/test-env-js",
"build:cli": "lerna run build --scope polywrap",
"build:plugins:patch": "lerna run codegen:patch --scope @polywrap/*-plugin-js --concurrency 1",
"lint": "lerna run lint",
"lint:fix": "lerna run lint -- --fix",
"lint:ci": "yarn lint",
"test": "lerna run test --no-private --ignore @web3api/client-js --concurrency 1 && lerna run test --scope @web3api/client-js",
"test:ci": "lerna run test:ci --no-private --ignore @web3api/client-js --concurrency 1 && lerna run test:ci --scope @web3api/client-js",
"test:core": "lerna run test:ci --no-private --ignore @web3api/*-plugin-js --ignore @web3api/cli* --ignore @web3api/client-js --concurrency 1",
"test:plugins": "lerna run test:ci --no-private --scope @web3api/*-plugin-js --concurrency 1",
"test:client": "lerna run test:ci --no-private --scope @web3api/client-js --concurrency 1",
"test:cli": "lerna run test:ci --no-private --scope @web3api/cli --concurrency 1",
"test": "lerna run test --no-private --ignore @polywrap/client-js --concurrency 1 && lerna run test --scope @polywrap/client-js",
"test:ci": "lerna run test:ci --no-private --ignore @polywrap/client-js --concurrency 1 && lerna run test:ci --scope @polywrap/client-js",
"test:core": "lerna run test:ci --no-private --ignore @polywrap/*-plugin-js --ignore polywrap* --ignore @polywrap/client-js --concurrency 1",
"test:plugins": "lerna run test:ci --no-private --scope @polywrap/*-plugin-js --concurrency 1",
"test:client": "lerna run test:ci --no-private --scope @polywrap/client-js --concurrency 1",
"test:cli": "lerna run test:ci --no-private --scope polywrap --concurrency 1",
"version:apply": "npx lerna version $(cat VERSION) --exact --no-git-tag-version --yes",
"postversion:apply": "git add . && git commit -m \"build(release): migrate to `cat ./VERSION`\"",
"publish:npm": "lerna publish from-package --no-private --yes --registry https://registry.npmjs.org/ --no-verify-access"
Expand Down
2 changes: 1 addition & 1 deletion packages/cli/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Web3API CLI
# Polywrap CLI
TODO:
- introduce high level usages (create, build, test, publish)
- type --help for full usage
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion packages/cli/copyfiles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const ignore = [
".idea",
".log",
".vscode",
".w3",
".polywrap",
".rs.bk",
".lock",
];
Expand Down
6 changes: 3 additions & 3 deletions packages/cli/jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@ module.exports = {
},
},
modulePathIgnorePatterns: [
"<rootDir>/src/__tests__/project/.w3"
"<rootDir>/src/__tests__/project/.polywrap"
],
testPathIgnorePatterns: [
"<rootDir>/src/__tests__/project/.w3"
"<rootDir>/src/__tests__/project/.polywrap"
],
transformIgnorePatterns: [
"<rootDir>/src/__tests__/project/.w3"
"<rootDir>/src/__tests__/project/.polywrap"
],
setupFilesAfterEnv: ["./jest.setup.js"],
};
Loading