mirror of
https://github.com/valitydev/dominant-cache-proto.git
synced 2024-11-06 09:25:20 +00:00
TD-237: Add frontend codegen (#4)
This commit is contained in:
parent
65e625263f
commit
5e9a9109f1
2
.github/settings.yml
vendored
Normal file
2
.github/settings.yml
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
# These settings are synced to GitHub by https://probot.github.io/apps/settings/
|
||||
_extends: .github
|
7
.github/workflows/basic-linters.yml
vendored
7
.github/workflows/basic-linters.yml
vendored
@ -3,12 +3,7 @@ name: Vality basic linters
|
||||
on:
|
||||
pull_request:
|
||||
branches:
|
||||
- master
|
||||
- main
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
- main
|
||||
- "*"
|
||||
|
||||
jobs:
|
||||
lint:
|
||||
|
29
.github/workflows/build.yml
vendored
29
.github/workflows/build.yml
vendored
@ -1,29 +0,0 @@
|
||||
name: Build Artifact
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
branches:
|
||||
- '*'
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-20.04
|
||||
steps:
|
||||
- name: Install thrift
|
||||
uses: valitydev/action-setup-thrift@v0.0.1
|
||||
- name: Checkout Repo
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
fetch-depth: 0
|
||||
- name: Set up Maven
|
||||
uses: actions/setup-java@v2
|
||||
with:
|
||||
java-version: '15'
|
||||
distribution: 'adopt'
|
||||
- name: Retrieve commit info
|
||||
run: |
|
||||
echo "::set-output name=COMMIT_NUMBER::$(git rev-list HEAD --count)"
|
||||
echo "::set-output name=SHA_7::${GITHUB_SHA::7}"
|
||||
id: commit_info
|
||||
- name: Build package
|
||||
run: mvn --batch-mode -Dcommit.number=${{ steps.commit_info.outputs.COMMIT_NUMBER }} -Drevision="1.${{ steps.commit_info.outputs.COMMIT_NUMBER }}-${{ steps.commit_info.outputs.SHA_7 }}" clean compile -f pom.xml
|
31
.github/workflows/deploy.yml
vendored
31
.github/workflows/deploy.yml
vendored
@ -1,31 +0,0 @@
|
||||
name: Deploy Artifact
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- 'master'
|
||||
- 'main'
|
||||
|
||||
jobs:
|
||||
deploy:
|
||||
runs-on: ubuntu-20.04
|
||||
steps:
|
||||
- name: Install thrift
|
||||
uses: valitydev/action-setup-thrift@v0.0.1
|
||||
- name: Checkout Repo
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
fetch-depth: 0
|
||||
- name: Retrieve commit info
|
||||
run: |
|
||||
echo "::set-output name=COMMIT_NUMBER::$(git rev-list HEAD --count)"
|
||||
echo "::set-output name=SHA_7::${GITHUB_SHA::7}"
|
||||
id: commit_info
|
||||
- name: Deploy package
|
||||
uses: valitydev/action-deploy-jdk-package@v1.0.9
|
||||
with:
|
||||
server-username: ${{ secrets.OSSRH_USERNAME }}
|
||||
server-password: ${{ secrets.OSSRH_TOKEN }}
|
||||
deploy-secret-key: ${{ secrets.OSSRH_GPG_SECRET_KEY }}
|
||||
deploy-secret-key-password: ${{ secrets.OSSRH_GPG_SECRET_KEY_PASSWORD }}
|
||||
maven-args: '-Dcommit.number=${{ steps.commit_info.outputs.COMMIT_NUMBER }} -Drevision="1.${{ steps.commit_info.outputs.COMMIT_NUMBER }}-${{ steps.commit_info.outputs.SHA_7 }}"'
|
34
.github/workflows/erlang-pr.yml
vendored
Normal file
34
.github/workflows/erlang-pr.yml
vendored
Normal file
@ -0,0 +1,34 @@
|
||||
name: Erlang build
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
branches:
|
||||
- "*"
|
||||
|
||||
jobs:
|
||||
build:
|
||||
name: Build and verify
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- uses: valitydev/action-setup-thrift@v1
|
||||
|
||||
- uses: erlef/setup-beam@v1
|
||||
id: beam
|
||||
with:
|
||||
otp-version: "24"
|
||||
rebar3-version: "3.18"
|
||||
|
||||
- name: Restore PLT cache
|
||||
uses: actions/cache@v2
|
||||
id: plt-cache
|
||||
with:
|
||||
key: |
|
||||
${{ runner.os }}-${{ steps.beam.outputs.otp-version }}-plt
|
||||
path: |
|
||||
_build/default/rebar3_*_plt
|
||||
|
||||
- run: rebar3 compile
|
||||
- run: rebar3 xref
|
||||
- run: rebar3 dialyzer
|
21
.github/workflows/frontend-pr.yml
vendored
Normal file
21
.github/workflows/frontend-pr.yml
vendored
Normal file
@ -0,0 +1,21 @@
|
||||
name: 'Frontend: PR'
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
branches: ['*']
|
||||
|
||||
jobs:
|
||||
configured:
|
||||
uses: valitydev/action-frontend/.github/workflows/configured.yml@v0.1
|
||||
check:
|
||||
name: Check
|
||||
runs-on: ubuntu-latest
|
||||
needs: configured
|
||||
if: needs.configured.outputs.exists == 'true'
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- uses: valitydev/action-frontend/setup@v0.1
|
||||
- uses: valitydev/action-setup-thrift@v1.0.0
|
||||
- run: npm ci
|
||||
- name: Codegen
|
||||
run: npm run codegen
|
22
.github/workflows/frontend-publish.yml
vendored
Normal file
22
.github/workflows/frontend-publish.yml
vendored
Normal file
@ -0,0 +1,22 @@
|
||||
name: 'Frontend: Publish'
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: ['master', 'main']
|
||||
|
||||
jobs:
|
||||
configured:
|
||||
uses: valitydev/action-frontend/.github/workflows/configured.yml@v0.1
|
||||
publish:
|
||||
name: Publish
|
||||
runs-on: ubuntu-latest
|
||||
needs: configured
|
||||
if: needs.configured.outputs.exists == 'true'
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- uses: valitydev/action-frontend/setup@v0.1
|
||||
- uses: valitydev/action-setup-thrift@v1.0.0
|
||||
- run: npm ci
|
||||
- name: Build
|
||||
run: npm run codegen
|
||||
- uses: valitydev/action-frontend/publish@v0.1
|
17
.github/workflows/java-deploy.yml
vendored
Normal file
17
.github/workflows/java-deploy.yml
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
name: Java deploy
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- "master"
|
||||
- "main"
|
||||
|
||||
jobs:
|
||||
deploy:
|
||||
uses: valitydev/java-workflow/.github/workflows/maven-thrift-deploy.yml@v1
|
||||
secrets:
|
||||
server-username: ${{ secrets.OSSRH_USERNAME }}
|
||||
server-password: ${{ secrets.OSSRH_TOKEN }}
|
||||
deploy-secret-key: ${{ secrets.OSSRH_GPG_SECRET_KEY }}
|
||||
deploy-secret-key-password: ${{ secrets.OSSRH_GPG_SECRET_KEY_PASSWORD }}
|
||||
mm-webhook-url: ${{ secrets.MATTERMOST_WEBHOOK_URL }}
|
10
.github/workflows/java-pr.yml
vendored
Normal file
10
.github/workflows/java-pr.yml
vendored
Normal file
@ -0,0 +1,10 @@
|
||||
name: Java build
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
branches:
|
||||
- "*"
|
||||
|
||||
jobs:
|
||||
build:
|
||||
uses: valitydev/java-workflow/.github/workflows/maven-thrift-build.yml@v1
|
4
.gitignore
vendored
4
.gitignore
vendored
@ -76,3 +76,7 @@ fabric.properties
|
||||
# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml
|
||||
hs_err_pid*
|
||||
env.list
|
||||
|
||||
# frontend
|
||||
node_modules
|
||||
lib
|
||||
|
1678
package-lock.json
generated
Normal file
1678
package-lock.json
generated
Normal file
File diff suppressed because it is too large
Load Diff
26
package.json
Normal file
26
package.json
Normal file
@ -0,0 +1,26 @@
|
||||
{
|
||||
"name": "@vality/dominant-cache-proto",
|
||||
"version": "1.0.0",
|
||||
"scripts": {
|
||||
"codegen": "thrift-codegen"
|
||||
},
|
||||
"publishConfig": {
|
||||
"access": "public",
|
||||
"registry": "https://registry.npmjs.org/"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git+https://github.com/valitydev/dominant-cache-proto.git"
|
||||
},
|
||||
"license": "Apache-2.0",
|
||||
"homepage": "https://github.com/valitydev/dominant-cache-proto#readme",
|
||||
"files": [
|
||||
"lib/**/*.{js,d.ts,json}",
|
||||
"**/*.thrift"
|
||||
],
|
||||
"main": "./lib/dominant_cache.js",
|
||||
"types": "./lib/dominant_cache.d.ts",
|
||||
"devDependencies": {
|
||||
"@vality/thrift-codegen": "0.1.1-e636464.0"
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user