mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-09-24 22:00:12 +01:00
Also a small pass on workflow names. Note, I'm a little concerned that the test/nightly release/pre-commit endpoints may be fragile. At the same time, it's also where it may be most useful, to prevent network access by arbitrary test code. I think this is imperfect, but maybe we can try it out and see if it's much of an issue. Note, the discord wiki action is currently broken, this should fix it.
41 lines
1.2 KiB
YAML
41 lines
1.2 KiB
YAML
# Part of the Carbon Language project, under the Apache License v2.0 with LLVM
|
|
# Exceptions. See /LICENSE for license information.
|
|
# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
|
|
|
|
# Applies the "proposal rfc" label when a proposal is marked ready for review.
|
|
|
|
name: Proposal ready for review
|
|
on:
|
|
pull_request_target:
|
|
types:
|
|
- ready_for_review
|
|
|
|
permissions:
|
|
pull-requests: write # For gh to edit labels.
|
|
|
|
jobs:
|
|
proposal_ready:
|
|
if: contains(github.event.pull_request.labels.*.name, 'proposal')
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Harden Runner
|
|
uses: step-security/harden-runner@17d0e2bd7d51742c71671bd19fa12bdc9d40a3d6 # v2.8.1
|
|
with:
|
|
disable-sudo: true
|
|
egress-policy: block
|
|
# prettier-ignore
|
|
allowed-endpoints: >
|
|
api.github.com:443
|
|
|
|
- name: rfc
|
|
run: |
|
|
gh pr edit "${PR}" \
|
|
--remove-label "proposal draft" \
|
|
--remove-label "proposal accepted" \
|
|
--remove-label "proposal declined" \
|
|
--remove-label "proposal deferred" \
|
|
--add-label "proposal rfc"
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
PR: ${{ github.event.pull_request.html_url }}
|