From 2ab4052e9fa21fcdd1ff79657ef0eb7396bf2dd6 Mon Sep 17 00:00:00 2001 From: Matthew Wang Date: Thu, 15 Jul 2021 13:52:48 -0700 Subject: [PATCH 1/3] adds doc deploy action --- .github/workflows/deploy-docs.yml | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 .github/workflows/deploy-docs.yml diff --git a/.github/workflows/deploy-docs.yml b/.github/workflows/deploy-docs.yml new file mode 100644 index 00000000000..50e69fab897 --- /dev/null +++ b/.github/workflows/deploy-docs.yml @@ -0,0 +1,29 @@ +name: Build and Deploy Docs +on: + push: + branches: + - master +jobs: + build-and-deploy-docs: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v2.3.1 + - name: Setup Node.js + uses: actions/setup-node@v2 + with: + node-version: '14.x' + # Pre-check to validate that versions match between package.json + # and package-lock.json. Needs to run before npm install + - name: Validate package.json and package-lock.json versions + run: node version-check.js + - name: Install dependencies + run: npm ci + - name: Build docs + run: npm run docs + + - name: Deploy docs + uses: JamesIves/github-pages-deploy-action@4.1.4 + with: + branch: gh-pages # The branch the action should deploy to. + folder: docs # The folder the action should deploy. \ No newline at end of file From 67586a429e6cf7d785ed50b61d4408967eb2163f Mon Sep 17 00:00:00 2001 From: Matthew Wang Date: Thu, 15 Jul 2021 14:14:46 -0700 Subject: [PATCH 2/3] updates README w/ relevant info --- README.md | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 7eaa2718a76..4d9cc084f37 100644 --- a/README.md +++ b/README.md @@ -3,6 +3,7 @@ [![Build Status](https://github.com/kubernetes-client/javascript/workflows/Kubernetes%20Javascript%20Client%20-%20Validation/badge.svg)](https://github.com/kubernetes-client/javascript/actions) [![Client Capabilities](https://img.shields.io/badge/Kubernetes%20client-Gold-blue.svg?style=flat&colorB=FFD700&colorA=306CE8)](http://bit.ly/kubernetes-client-capabilities-badge) [![Client Support Level](https://img.shields.io/badge/kubernetes%20client-beta-green.svg?style=flat&colorA=306CE8)](http://bit.ly/kubernetes-client-support-badge) +[![Build and Deploy Docs](https://github.com/kubernetes-client/javascript/actions/workflows/deploy-docs.yml/badge.svg)](https://github.com/kubernetes-client/javascript/actions/workflows/deploy-docs.yml) The Javascript clients for Kubernetes is implemented in [typescript](https://typescriptlang.org), but can be called from either @@ -99,9 +100,14 @@ const k8sApi = kc.makeApiClient(k8s.CoreV1Api); ... ``` -# Additional Examples +# Additional Examples and Documentation -There are several more examples in the [examples](https://github.com/kubernetes-client/javascript/tree/master/examples) directory. +There are several more JS and TS examples in the [examples](https://github.com/kubernetes-client/javascript/tree/master/examples) directory. + +Documentation for the library is split into two resources: + +1. The [Kubernetes API Reference](https://kubernetes.io/docs/reference/) is the source-of-truth for all Kubernetes client libraries, including this one. We suggest starting here! +2. The Typedoc autogenerated docs can be viewed [online](https://kubernetes-client.github.io/javascript) and can also be built locally (see below) # Compatibility From 74f82ff0c687f8f58cbeed0f44713c7c11a8f1a5 Mon Sep 17 00:00:00 2001 From: Matthew Wang Date: Thu, 15 Jul 2021 14:21:29 -0700 Subject: [PATCH 3/3] LF on EOF --- .github/workflows/deploy-docs.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/deploy-docs.yml b/.github/workflows/deploy-docs.yml index 50e69fab897..4e050ed1936 100644 --- a/.github/workflows/deploy-docs.yml +++ b/.github/workflows/deploy-docs.yml @@ -26,4 +26,4 @@ jobs: uses: JamesIves/github-pages-deploy-action@4.1.4 with: branch: gh-pages # The branch the action should deploy to. - folder: docs # The folder the action should deploy. \ No newline at end of file + folder: docs # The folder the action should deploy.