Skip to content

Commit 60fde57

Browse files
mlreric-schneider
andauthored
Updates for unified build (#24)
* Updates for unified doc site * Add workflow for pull request draft builds * Add unified docs assets --------- Co-authored-by: Eric Schneider <[email protected]>
1 parent 9790628 commit 60fde57

17 files changed

+642
-877
lines changed
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
name: Deploy Draft
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- '*'
7+
8+
jobs:
9+
dispatch-deploy:
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
# Determine the build branch and draft branch for dispatch.
14+
- name: Determine Dispatch Parameters
15+
run: |
16+
if [ "${{ github.event_name }}" == "pull_request" ]; then
17+
# If this workflow is kicked off by a pull request, build
18+
# a draft using the pull request base branch and PR branch.
19+
build_branch="${{ github.base_ref }}"
20+
draft_branch="${{ github.event.pull_request.head.ref }}"
21+
else
22+
if [ "$(basename ${{ github.event.ref }})" == "stage" ]; then
23+
# This was a merge to stage so kick off a build to update stage draft.
24+
build_branch=stage
25+
draft_branch=stage
26+
else
27+
# Otherwise this is a push to one of the source branches so
28+
# dispatch a build for the main draft to pick up the changes.
29+
build_branch=main
30+
draft_branch=main
31+
fi
32+
fi
33+
echo "build_branch=$build_branch" >> $GITHUB_OUTPUT
34+
echo "draft_branch=$draft_branch" >> $GITHUB_OUTPUT
35+
id: branches
36+
37+
- name: Deploy Draft
38+
uses: convictional/[email protected]
39+
with:
40+
owner: riptano
41+
repo: datastax-docs-site
42+
github_token: ${{ secrets.DISPATCH_GITHUB_TOKEN }}
43+
github_user: ${{ secrets.DISPATCH_GITHUB_USER }}
44+
workflow_file_name: deploy-draft.yml
45+
client_payload: '{ "build_repository": "${{ github.event.repository.full_name }}", "build_branch": "${{ steps.branches.outputs.build_branch }}", "draft_branch": "${{ steps.branches.outputs.draft_branch }}", "pull_request_number": "${{ github.event.pull_request.number }}" }'

.gitignore

Lines changed: 15 additions & 110 deletions
Original file line numberDiff line numberDiff line change
@@ -1,110 +1,15 @@
1-
build
2-
*~
3-
package-lock.json
4-
.vscode
5-
.DS_Store
6-
7-
# Logs
8-
logs
9-
*.log
10-
npm-debug.log*
11-
yarn-debug.log*
12-
yarn-error.log*
13-
lerna-debug.log*
14-
15-
# Diagnostic reports (https://nodejs.org/api/report.html)
16-
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json
17-
18-
# Runtime data
19-
pids
20-
*.pid
21-
*.seed
22-
*.pid.lock
23-
24-
# Directory for instrumented libs generated by jscoverage/JSCover
25-
lib-cov
26-
27-
# Coverage directory used by tools like istanbul
28-
coverage
29-
*.lcov
30-
31-
# nyc test coverage
32-
.nyc_output
33-
34-
# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
35-
.grunt
36-
37-
# Bower dependency directory (https://bower.io/)
38-
bower_components
39-
40-
# node-waf configuration
41-
.lock-wscript
42-
43-
# Compiled binary addons (https://nodejs.org/api/addons.html)
44-
build/Release
45-
46-
# Dependency directories
47-
node_modules/
48-
jspm_packages/
49-
50-
# TypeScript v1 declaration files
51-
typings/
52-
53-
# TypeScript cache
54-
*.tsbuildinfo
55-
56-
# Optional npm cache directory
57-
.npm
58-
59-
# Optional eslint cache
60-
.eslintcache
61-
62-
# Microbundle cache
63-
.rpt2_cache/
64-
.rts2_cache_cjs/
65-
.rts2_cache_es/
66-
.rts2_cache_umd/
67-
68-
# Optional REPL history
69-
.node_repl_history
70-
71-
# Output of 'npm pack'
72-
*.tgz
73-
74-
# Yarn Integrity file
75-
.yarn-integrity
76-
77-
# dotenv environment variables file
78-
.env
79-
.env.test
80-
81-
# parcel-bundler cache (https://parceljs.org/)
82-
.cache
83-
84-
# Next.js build output
85-
.next
86-
87-
# Nuxt.js build / generate output
88-
.nuxt
89-
dist
90-
91-
# Gatsby files
92-
.cache/
93-
# Comment in the public line in if your project uses Gatsby and *not* Next.js
94-
# https://nextjs.org/blog/next-9-1#public-directory-support
95-
# public
96-
97-
# vuepress build output
98-
.vuepress/dist
99-
100-
# Serverless directories
101-
.serverless/
102-
103-
# FuseBox cache
104-
.fusebox/
105-
106-
# DynamoDB Local files
107-
.dynamodb/
108-
109-
# TernJS port file
110-
.tern-port
1+
#OS
2+
**/.DS_Store
3+
**/.git-credentials
4+
5+
#IDE
6+
**/.vscode/
7+
**/.idea
8+
**/*.iml
9+
*.http
10+
**/.java-version
11+
12+
#build
13+
**/package-lock.json
14+
**/node_modules/
15+
/build/

0 commit comments

Comments
 (0)