-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
ARROW-12958: [CI][Developer] Build + host the docs for PR branches #13913
Changes from 12 commits
78480f4
3c992b8
287cd8f
3628cdf
de4a4bf
2f9e769
f6a5425
7f064b6
4c318f1
03a8233
fe04756
4d0d4ee
33ac5d5
5aaa225
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
# Licensed to the Apache Software Foundation (ASF) under one | ||
# or more contributor license agreements. See the NOTICE file | ||
# distributed with this work for additional information | ||
# regarding copyright ownership. The ASF licenses this file | ||
# to you under the Apache License, Version 2.0 (the | ||
# "License"); you may not use this file except in compliance | ||
# with the License. You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, | ||
# software distributed under the License is distributed on an | ||
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | ||
# KIND, either express or implied. See the License for the | ||
# specific language governing permissions and limitations | ||
# under the License. | ||
|
||
{% import 'macros.jinja' as macros with context %} | ||
{% set pr_number = pr_number|replace("Unset", arrow.branch) %} | ||
{{ macros.github_header() }} | ||
|
||
jobs: | ||
test: | ||
name: Docs Preview | ||
runs-on: ubuntu-latest | ||
{{ macros.github_set_env(env) }} | ||
steps: | ||
{{ macros.github_checkout_arrow(fetch_depth=fetch_depth|default(1))|indent }} | ||
{{ macros.github_install_archery()|indent }} | ||
|
||
- name: Execute Docker Build | ||
shell: bash | ||
env: | ||
ARROW_JAVA_SKIP_GIT_PLUGIN: true | ||
run: | | ||
archery docker run \ | ||
-e SETUPTOOLS_SCM_PRETEND_VERSION="{{ arrow.no_rc_version }}" \ | ||
{{ flags|default("") }} \ | ||
{{ image }} \ | ||
{{ command|default("") }} | ||
- name: Checkout Crossbow | ||
uses: actions/checkout@v3 | ||
with: | ||
ref: {{ default_branch|default("master") }} | ||
path: crossbow | ||
fetch-depth: 1 | ||
- name: Move docs | ||
run: | | ||
sudo chown -R ${USER}: build | ||
mkdir -p crossbow/docs/pr/{{ pr_number }} | ||
rsync -a --delete build/docs/ crossbow/docs/pr/{{ pr_number }} | ||
- name: Push changes | ||
run: | | ||
cd crossbow | ||
git config --local user.name "Github Actions" | ||
git config --local user.email "[email protected]" | ||
git add docs/pr/{{ pr_number }} | ||
git commit -m "Add docs preview for PR {{ pr_number }}" | ||
git push | ||
Original file line number | Diff line number | Diff line change | ||||||
---|---|---|---|---|---|---|---|---|
|
@@ -969,6 +969,8 @@ tasks: | |||||||
r-binary-packages: | ||||||||
ci: github | ||||||||
template: r/github.packages.yml | ||||||||
params: | ||||||||
custom_version: Unset | ||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is a minor fix for an issue I noticed in this PR, namely that for params to work they have to be listed in |
||||||||
artifacts: | ||||||||
- r-lib__libarrow__bin__windows__arrow-[0-9\.]+\.zip | ||||||||
- r-lib__libarrow__bin__centos-7__arrow-[0-9\.]+\.zip | ||||||||
|
@@ -1607,3 +1609,13 @@ tasks: | |||||||
type: minimal_build | ||||||||
run: {{ kind }} | ||||||||
{% endfor %} | ||||||||
|
||||||||
############################## Utility tasks ############################ | ||||||||
preview-docs: | ||||||||
ci: github | ||||||||
template: docs/github.linux.yml | ||||||||
params: | ||||||||
pr_number: Unset | ||||||||
artifacts: "build/docs.tar.gz" | ||||||||
flags: "-v $PWD/build/:/build/" | ||||||||
image: ubuntu-docs | ||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -251,7 +251,7 @@ | |
<plugin> | ||
<groupId>pl.project13.maven</groupId> | ||
<artifactId>git-commit-id-plugin</artifactId> | ||
<version>2.2.2</version> | ||
<version>4.0.5</version> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This plugin was causing problems with shallow copies, it should have been able to handle it but it looks like our version was too old. The new version introduces the cli switch I added to |
||
<executions> | ||
<execution> | ||
<id>for-jars</id> | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we maybe
echo
the URL where the docs are hosted here? Just thinking it would be nice to have a reminder where they appear in the CI output.