Skip to content

Move language spec upload from Github actions to cloud build: Add cloudbuild.yaml #4323

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

Merged
merged 31 commits into from
May 28, 2025
Merged
Show file tree
Hide file tree
Changes from 23 commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
838e7d0
New file
eernstg Apr 4, 2025
2e26514
WIP
eernstg Apr 4, 2025
f41d228
Ignoring generated directory
eernstg Apr 4, 2025
a66bd62
WIP
eernstg Apr 4, 2025
be66c99
Add pwd step to cloudbuild.yaml
eernstg Apr 15, 2025
cfa28c4
Use cloud logging
dart-github-bot Apr 10, 2025
cafbd90
Update cloudbuild.yaml
athomas Apr 22, 2025
ac0d168
More cloud build debugging
athomas Apr 22, 2025
c632b39
More debugging.
athomas Apr 22, 2025
f4b2a57
Try different shebang
athomas Apr 22, 2025
b941613
Run script in ubuntu
athomas Apr 22, 2025
c8ee9c3
Revert shebang
athomas Apr 22, 2025
f888bbd
Another shebang attempt
athomas Apr 22, 2025
b04f64a
Try build_pdf without sudo
athomas Apr 22, 2025
8e004a5
Install make
athomas Apr 22, 2025
181da1e
Install build-essential instead
athomas Apr 22, 2025
3c2d6c3
Say "yes"
athomas Apr 22, 2025
9758bb3
Add automap substitutions and artifacts upload
athomas May 16, 2025
ccf3205
Change output folder to match cloud build config
athomas May 16, 2025
ae314e5
Update cloudbuild.yaml
athomas May 16, 2025
5629cf5
Add the PR number to the spec PDF uploading location
eernstg May 23, 2025
f511bee
Remove the path in the location of artifacts
eernstg May 23, 2025
a322c52
Copy the spec PDF to the `artifacts/pr/$_PR_NUMBER` subdirecory, top …
eernstg May 23, 2025
6f412ee
Change PR copy to require a non-empty $_PR_NUMBER
eernstg May 23, 2025
a3ff097
Try to upload with gcr.io/cloud-builders/gsutil
athomas May 23, 2025
c9df0a4
Fix typo
athomas May 23, 2025
5c74772
Update build_pdf
athomas May 23, 2025
ff1dd18
Fix option order
athomas May 23, 2025
ee566c1
Use BRANCH_NAME
athomas May 23, 2025
816a362
Pass env explicitely
athomas May 26, 2025
493f39f
Try using `*` to move artifacts to root
athomas May 26, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions .cloud_build/specification/cloudbuild.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
steps:
- name: 'ubuntu'
args: ['specification/scripts/build_pdf']
options:
automapSubstitutions: true
logging: CLOUD_LOGGING_ONLY
artifacts:
objects:
location: 'gs://dart-specification/'
paths: ['specification/artifacts/**']
1 change: 1 addition & 0 deletions specification/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,4 @@ dartLangSpec-terse.tex
*-list.txt
.dart_tool/
.packages
firebase/
17 changes: 17 additions & 0 deletions specification/scripts/build_pdf
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/usr/bin/env -S bash --norc

apt-get update -qq
apt-get install -y --no-install-recommends \
build-essential \
texlive-latex-base \
texlive-latex-extra \
texlive-fonts-recommended \
lmodern
cd specification
make
mkdir -p artifacts
if [ "$_BASE_BRANCH" == "main" ]; then
cp dartLangSpec.pdf artifacts/DartLangSpecDraft.pdf
fi
mkdir -p artifacts/pr/$_PR_NUMBER
cp dartLangSpec.pdf artifacts/pr/$_PR_NUMBER/DartLangSpecDraft.pdf