@@ -222,12 +222,50 @@ tasks:
222222 owner : cdenizet@mozilla.com
223223 source : ${repository}/raw/${head_rev}/.taskcluster.yml
224224
225+ - $if : ' tasks_for == "github-push" && head_branch[:10] == "refs/tags/"'
226+ then :
227+ taskId : {$eval: as_slugid("publish_crates")}
228+ dependencies :
229+ - {$eval: as_slugid("test_mozilla_central")}
230+ - {$eval: as_slugid("build_documentation")}
231+ created : {$fromNow: ''}
232+ deadline : {$fromNow: '2 hour'}
233+ provisionerId : proj-relman
234+ workerType : ci
235+ scopes :
236+ - secrets:get:project/relman/rust-code-analysis/deploy
237+ payload :
238+ features :
239+ taskclusterProxy : true
240+ maxRunTime : 3600
241+ image : " mozilla/taskboot:0.3.3"
242+ env :
243+ TASKCLUSTER_SECRET : project/relman/rust-code-analysis/deploy
244+ command :
245+ - " /bin/sh"
246+ - " -cx"
247+ - " git config --global user.email moz-tools-bot@moz.tools &&
248+ git config --global user.name moz.tools Bot &&
249+ git clone --quiet ${repository} &&
250+ cd rust-code-analysis &&
251+ cd tree-sitter-ccomment && taskboot cargo-publish --ignore-published && cd .. &&
252+ cd tree-sitter-preproc && taskboot cargo-publish --ignore-published && cd .. &&
253+ cd tree-sitter-mozjs && taskboot cargo-publish --ignore-published && cd .. &&
254+ cd tree-sitter-mozcpp && taskboot cargo-publish --ignore-published && cd .. &&
255+ taskboot cargo-publish &&
256+ cd rust-code-analysis-cli && taskboot cargo-publish && cd .. &&
257+ cd rust-code-analysis-web && taskboot cargo-publish"
258+ metadata :
259+ name : " rust-code-analysis release publication ${head_branch[10:]}"
260+ description : rust-code-analysis publish on crates.io
261+ owner : cdenizet@mozilla.com
262+ source : ${repository}/raw/${head_rev}/.taskcluster.yml
263+
225264 - $if : ' tasks_for == "github-push" && head_branch[:10] == "refs/tags/"'
226265 then :
227266 taskId : {$eval: as_slugid("build_linux_release")}
228267 dependencies :
229- - {$eval: as_slugid("lint_test_task")}
230- - {$eval: as_slugid("windows_test_task")}
268+ - {$eval: as_slugid("publish_crates")}
231269 created : {$fromNow: ''}
232270 deadline : {$fromNow: '2 hour'}
233271 provisionerId : proj-relman
@@ -345,19 +383,12 @@ tasks:
345383 git config --global user.name moz.tools Bot &&
346384 git clone --quiet ${repository} &&
347385 cd rust-code-analysis &&
348- cd tree-sitter-ccomment && taskboot cargo-publish --ignore-published && cd .. &&
349- cd tree-sitter-preproc && taskboot cargo-publish --ignore-published && cd .. &&
350- cd tree-sitter-mozjs && taskboot cargo-publish --ignore-published && cd .. &&
351- cd tree-sitter-mozcpp && taskboot cargo-publish --ignore-published && cd .. &&
352386 taskboot retrieve-artifact --output-path=. --artifacts=public/book.tar.gz &&
353387 tar xfz book.tar.gz -C rust-code-analysis-book &&
354388 ./rust-code-analysis-book/deploy-to-GitHub-Pages &&
355389 taskboot git-push --force-push github.com/mozilla/rust-code-analysis moz-tools-bot gh-pages &&
356390 taskboot github-release mozilla/rust-code-analysis ${head_branch[10:]} --asset ${linux_cli}:public/${linux_cli} ${linux_web}:public/${linux_web} ${win_cli}:public/${win_cli} ${win_web}:public/${win_web} &&
357- rm -rf book.tar.gz &&
358- taskboot cargo-publish &&
359- cd rust-code-analysis-cli && taskboot cargo-publish && cd .. &&
360- cd rust-code-analysis-web && taskboot cargo-publish"
391+ rm -rf book.tar.gz"
361392 metadata :
362393 name : " rust-code-analysis release publication ${head_branch[10:]}"
363394 description : rust-code-analysis release publication on Github
0 commit comments