-
Notifications
You must be signed in to change notification settings - Fork 14
47 lines (45 loc) · 1.84 KB
/
build-and-publish-docs.yml
File metadata and controls
47 lines (45 loc) · 1.84 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
name: 'Build and publish documentation to sdk-docs'
on:
workflow_dispatch: {}
workflow_call:
secrets:
SSH_DEPLOY_KEY:
required: true
jobs:
build-and-deploy-documentation:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Read version from gradle.properties
id: version
run: |
VERSION=$(grep "pineconeClientVersion" gradle.properties | cut -d'=' -f2 | tr -d ' ')
echo "CLIENT_VERSION=$VERSION" >> $GITHUB_ENV
echo "CLIENT_VERSION=$VERSION" >> $GITHUB_OUTPUT
- name: Generate Javadoc documentation
uses: ./.github/actions/build-docs
- name: Push documentation artifacts to sdk-docs (latest)
uses: cpina/github-action-push-to-another-repository@main
env:
SSH_DEPLOY_KEY: ${{ secrets.SSH_DEPLOY_KEY }}
with:
source-directory: docs
destination-github-username: pinecone-io
destination-repository-name: sdk-docs
user-email: clients@pinecone.io
target-branch: main
target-directory: java
commit-message: "Java: automated documentation build (latest) \n\n pinecone-java-client merge SHA: ${{ github.sha }}"
- name: Push documentation artifacts to sdk-docs (versioned)
uses: cpina/github-action-push-to-another-repository@main
env:
SSH_DEPLOY_KEY: ${{ secrets.SSH_DEPLOY_KEY }}
with:
source-directory: docs
destination-github-username: pinecone-io
destination-repository-name: sdk-docs
user-email: clients@pinecone.io
target-branch: main
target-directory: java/v${{ env.CLIENT_VERSION }}
commit-message: "Java: automated documentation build for v${{ env.CLIENT_VERSION }} \n\n pinecone-java-client merge SHA: ${{ github.sha }}"