mirror of
https://github.com/chromebrew/chromebrew.git
synced 2026-01-09 15:37:56 -05:00
Update workflows and adjust variable in const.rb to fix updater workflow runs. (#12233)
* Fix env variable check in const.rb Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Adjust workflows. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Remove since_last_remote_commit:true Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Handle Draft PRs. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Move manifest reporting section of PRs. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Adjust inputs for generate PR workflow. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * workflow cleanup Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Add unbuilt updated pip packages to updates-2025-07-21-02-47 * Build on linux/386 to branch updates-2025-07-21-02-47. * Updating package files for linux/386 to branch updates-2025-07-21-02-47. * Updating package files for linux/amd64 to branch updates-2025-07-21-02-47. * Updating package files for linux/arm/v7 to branch updates-2025-07-21-02-47. * fixup Signed-off-by: Satadru Pramanik <satadru@gmail.com> * ADjust PR title Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Adjust branch name for automatic updates Signed-off-by: Satadru Pramanik <satadru@gmail.com> * fixup Signed-off-by: Satadru Pramanik <satadru@gmail.com> --------- Signed-off-by: Satadru Pramanik <satadru@gmail.com> Co-authored-by: Satadru Pramanik <satadru@gmail.com> Co-authored-by: satmandu <satmandu@users.noreply.github.com> Co-authored-by: chromebrew-actions[bot] <chromebrew-actions[bot]@users.noreply.github.com> Co-authored-by: Ed Reel <edreel@gmail.com>
This commit is contained in:
committed by
GitHub
parent
205ba1dcf8
commit
1829b8fc0e
65
.github/workflows/Build.yml
vendored
65
.github/workflows/Build.yml
vendored
@@ -75,19 +75,24 @@ jobs:
|
||||
TIMESTAMP="$(date -u +%F-%H%Z)"
|
||||
export TIMESTAMP
|
||||
echo "TIMESTAMP=${TIMESTAMP}" >> "$GITHUB_OUTPUT"
|
||||
- name: Get all changed package files
|
||||
id: changed-ruby-files
|
||||
- name: Get changed files
|
||||
id: changed-files
|
||||
uses: tj-actions/changed-files@v46
|
||||
with:
|
||||
base_sha: master
|
||||
files: packages/*.rb
|
||||
since_last_remote_commit: true
|
||||
files_yaml: |
|
||||
packages:
|
||||
- packages/*.rb
|
||||
- name: Export variables to github context
|
||||
id: changed-packages
|
||||
run: |
|
||||
# Convert "packages/foo.rb packages/bar.rb" (from steps.changed-ruby-files.outputs.all_changed_files) into "foo bar"
|
||||
echo "CHANGED_PACKAGES=$(echo "${{ steps.changed-ruby-files.outputs.all_changed_files }}" | xargs basename -s .rb | xargs)" >> "$GITHUB_ENV"
|
||||
echo "CHANGED_PACKAGES=$(echo "${{ steps.changed-ruby-files.outputs.all_changed_files }}" | xargs basename -s .rb | xargs)" >> "$GITHUB_OUTPUT"
|
||||
if [[ -z "${{ steps.changed-files.outputs.packages_all_changed_files }}" ]]; then
|
||||
echo "Branch ${{ env.BRANCH }} has no changed package files."
|
||||
exit 1
|
||||
fi
|
||||
# Convert "packages/foo.rb packages/bar.rb" (from steps.changed-files.outputs.packages_all_changed_files) into "foo bar"
|
||||
echo "CHANGED_PACKAGES=$(echo "${{ steps.changed-files.outputs.packages_all_changed_files }}" | xargs basename -s .rb | xargs)" >> "$GITHUB_ENV"
|
||||
echo "CHANGED_PACKAGES=$(echo "${{ steps.changed-files.outputs.packages_all_changed_files }}" | xargs basename -s .rb | xargs)" >> "$GITHUB_OUTPUT"
|
||||
- name: Determine glibc and architecture package compatibility
|
||||
id: get-compatibility
|
||||
run: |
|
||||
@@ -448,34 +453,23 @@ jobs:
|
||||
git reset --hard "origin/${{ env.BRANCH }}"
|
||||
git pull --rebase origin master && git push -f
|
||||
git log --oneline -10
|
||||
- name: Get all changed manifest files
|
||||
id: changed-manifest-files
|
||||
uses: tj-actions/changed-files@v46
|
||||
with:
|
||||
base_sha: master
|
||||
files: manifest/**
|
||||
since_last_remote_commit: true
|
||||
- name: Get all changed GitHub config files
|
||||
id: changed-GitHub-config-files
|
||||
uses: tj-actions/changed-files@v46
|
||||
with:
|
||||
base_sha: master
|
||||
files: .github/**
|
||||
since_last_remote_commit: true
|
||||
- name: Get other changed files
|
||||
id: other-changed-files
|
||||
- name: Get changed files
|
||||
id: changed-files
|
||||
uses: tj-actions/changed-files@v46
|
||||
with:
|
||||
base_sha: master
|
||||
files_yaml: |
|
||||
manifest:
|
||||
- manifest/**
|
||||
packages:
|
||||
- packages/*.rb
|
||||
workflow:
|
||||
github:
|
||||
- .github/**
|
||||
crew:
|
||||
other:
|
||||
- ./**
|
||||
- '!manifest/**'
|
||||
- '!packages/*.rb'
|
||||
- '!.github/**'
|
||||
- 'packages/*.rb'
|
||||
since_last_remote_commit: true
|
||||
- name: Get GH Token
|
||||
id: get_workflow_token
|
||||
uses: peter-murray/workflow-application-token-action@v4
|
||||
@@ -487,9 +481,9 @@ jobs:
|
||||
- name: Create Pull Request
|
||||
if: ${{ github.event.inputs.with_pr == 'true' }}
|
||||
env:
|
||||
CHANGED_GITHUB_CONFIG_FILES: ${{ steps.changed-GitHub-config-files.outputs.all_changed_files }}
|
||||
CHANGED_MANIFEST_FILES: ${{ steps.changed-manifest-files.outputs.all_changed_files }}
|
||||
CHANGED_OTHER_FILES: ${{ steps.other-changed-files.outputs.all_changed_files }}
|
||||
CHANGED_GITHUB_CONFIG_FILES: ${{ steps.changed-files.outputs.github_all_changed_files }}
|
||||
CHANGED_MANIFEST_FILES: ${{ steps.changed-files.outputs.manifest_all_changed_files }}
|
||||
CHANGED_OTHER_FILES: ${{ steps.changed-files.outputs.other_all_changed_files }}
|
||||
CHANGED_PACKAGES: ${{ needs.setup.outputs.changed_packages }}
|
||||
GH_TOKEN: ${{ steps.get_workflow_token.outputs.token }}
|
||||
TIMESTAMP: ${{ needs.setup.outputs.timestamp }}
|
||||
@@ -518,9 +512,6 @@ jobs:
|
||||
[ -n "${i686_PACKAGES}" ] && echo -e "- [x] \`i686\`" >> /tmp/pr.txt
|
||||
[ -n "${armv7l_PACKAGES}" ] && echo -e "- [x] \`armv7l\`" >> /tmp/pr.txt
|
||||
fi
|
||||
if [[ "${CHANGED_MANIFEST_FILES}" == "" ]]; then
|
||||
echo -e "##\n- [x] This PR has no manifest .filelist changes. _(Package changes have neither added nor removed files.)_" >> /tmp/pr.txt
|
||||
fi
|
||||
if [[ "${CHANGED_OTHER_FILES}" != "" ]]; then
|
||||
echo -e "### Other changed files:" >> /tmp/pr.txt
|
||||
for file in ${CHANGED_OTHER_FILES}
|
||||
@@ -528,11 +519,15 @@ jobs:
|
||||
echo "- ${file}" >> /tmp/pr.txt
|
||||
done
|
||||
fi
|
||||
if [[ "${CHANGED_MANIFEST_FILES}" == "" ]]; then
|
||||
echo -e "##\n- [x] This PR has no manifest .filelist changes. _(Package changes have neither added nor removed files.)_" >> /tmp/pr.txt
|
||||
fi
|
||||
echo -e "##\n### Run the following to get this pull request's changes locally for testing.\n\`\`\`bash" >> /tmp/pr.txt
|
||||
echo -e "CREW_REPO=https://github.com/chromebrew/chromebrew.git CREW_BRANCH=${{ env.BRANCH }} crew update \\" >> /tmp/pr.txt
|
||||
echo -e "&& yes | crew upgrade\n\`\`\`" >> /tmp/pr.txt
|
||||
cat /tmp/pr.txt
|
||||
PR_NUMBER=$(gh pr create --reviewer chromebrew/active--title "Build: ${{ env.BRANCH }} started at ${TIMESTAMP}." -F /tmp/pr.txt | rev | cut -d"/" -f1 | rev)
|
||||
gh pr merge "${PR_NUMBER}" --auto
|
||||
PR_NUMBER=$(gh pr create --reviewer chromebrew/active --title "Build: ${{ env.BRANCH }} started at ${TIMESTAMP}." -F /tmp/pr.txt | rev | cut -d"/" -f1 | rev)
|
||||
# Draft PRs can not be set to automerge.
|
||||
gh pr merge "${PR_NUMBER}" --auto || true
|
||||
echo "PR_NUMBER is ${PR_NUMBER}"
|
||||
echo "PR_NUMBER=${PR_NUMBER}" >> "$GITHUB_ENV"
|
||||
|
||||
67
.github/workflows/Generate-PR.yml
vendored
67
.github/workflows/Generate-PR.yml
vendored
@@ -3,11 +3,6 @@ name: Generate PR
|
||||
on:
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
with_pr:
|
||||
description: "Create a PR from a branch."
|
||||
required: false
|
||||
type: boolean
|
||||
default: 'true'
|
||||
branch:
|
||||
description: "Branch of chromebrew/chromebrew to run on, if different from this branch."
|
||||
required: false
|
||||
@@ -70,19 +65,20 @@ jobs:
|
||||
TIMESTAMP="$(date -u +%F-%H%Z)"
|
||||
export TIMESTAMP
|
||||
echo "TIMESTAMP=${TIMESTAMP}" >> "$GITHUB_OUTPUT"
|
||||
- name: Get all changed package files
|
||||
id: changed-ruby-files
|
||||
- name: Get changed files
|
||||
id: changed-files
|
||||
uses: tj-actions/changed-files@v46
|
||||
with:
|
||||
base_sha: master
|
||||
files: packages/*.rb
|
||||
since_last_remote_commit: true
|
||||
files_yaml: |
|
||||
packages:
|
||||
- packages/*.rb
|
||||
- name: Export variables to github context
|
||||
id: changed-packages
|
||||
run: |
|
||||
# Convert "packages/foo.rb packages/bar.rb" (from steps.changed-ruby-files.outputs.all_changed_files) into "foo bar"
|
||||
echo "CHANGED_PACKAGES=$(echo "${{ steps.changed-ruby-files.outputs.all_changed_files }}" | xargs basename -s .rb | xargs)" >> "$GITHUB_ENV"
|
||||
echo "CHANGED_PACKAGES=$(echo "${{ steps.changed-ruby-files.outputs.all_changed_files }}" | xargs basename -s .rb | xargs)" >> "$GITHUB_OUTPUT"
|
||||
# Convert "packages/foo.rb packages/bar.rb" (from steps.changed-files.outputs.packages_all_changed_files) into "foo bar"
|
||||
echo "CHANGED_PACKAGES=$(echo "${{ steps.changed-files.outputs.packages_all_changed_files }}" | xargs basename -s .rb | xargs)" >> "$GITHUB_ENV"
|
||||
echo "CHANGED_PACKAGES=$(echo "${{ steps.changed-files.outputs.packages_all_changed_files }}" | xargs basename -s .rb | xargs)" >> "$GITHUB_OUTPUT"
|
||||
- name: Determine glibc and architecture package compatibility
|
||||
id: get-compatibility
|
||||
run: |
|
||||
@@ -155,34 +151,23 @@ jobs:
|
||||
git reset --hard "origin/${{ env.BRANCH }}"
|
||||
git pull --rebase origin master && git push -f
|
||||
git log --oneline -10
|
||||
- name: Get all changed manifest files
|
||||
id: changed-manifest-files
|
||||
uses: tj-actions/changed-files@v46
|
||||
with:
|
||||
base_sha: master
|
||||
files: manifest/**
|
||||
since_last_remote_commit: true
|
||||
- name: Get all changed GitHub config files
|
||||
id: changed-GitHub-config-files
|
||||
uses: tj-actions/changed-files@v46
|
||||
with:
|
||||
base_sha: master
|
||||
files: .github/**
|
||||
since_last_remote_commit: true
|
||||
- name: Get other changed files
|
||||
id: other-changed-files
|
||||
- name: Get changed files
|
||||
id: changed-files
|
||||
uses: tj-actions/changed-files@v46
|
||||
with:
|
||||
base_sha: master
|
||||
files_yaml: |
|
||||
manifest:
|
||||
- manifest/**
|
||||
packages:
|
||||
- packages/*.rb
|
||||
workflow:
|
||||
github:
|
||||
- .github/**
|
||||
crew:
|
||||
other:
|
||||
- ./**
|
||||
- '!manifest/**'
|
||||
- '!packages/*.rb'
|
||||
- '!.github/**'
|
||||
- 'packages/*.rb'
|
||||
since_last_remote_commit: true
|
||||
- name: Get GH Token
|
||||
id: get_workflow_token
|
||||
uses: peter-murray/workflow-application-token-action@v4
|
||||
@@ -192,11 +177,10 @@ jobs:
|
||||
organization: chromebrew
|
||||
revoke_token: true
|
||||
- name: Create Pull Request
|
||||
if: ${{ github.event.inputs.with_pr == 'true' }}
|
||||
env:
|
||||
CHANGED_GITHUB_CONFIG_FILES: ${{ steps.changed-GitHub-config-files.outputs.all_changed_files }}
|
||||
CHANGED_MANIFEST_FILES: ${{ steps.changed-manifest-files.outputs.all_changed_files }}
|
||||
CHANGED_OTHER_FILES: ${{ steps.other-changed-files.outputs.all_changed_files }}
|
||||
CHANGED_GITHUB_CONFIG_FILES: ${{ steps.changed-files.outputs.github_all_changed_files }}
|
||||
CHANGED_MANIFEST_FILES: ${{ steps.changed-files.outputs.manifest_all_changed_files }}
|
||||
CHANGED_OTHER_FILES: ${{ steps.changed-files.outputs.other_all_changed_files }}
|
||||
CHANGED_PACKAGES: ${{ needs.setup.outputs.changed_packages }}
|
||||
CREW_BRANCH: ${{ inputs.branch || github.ref_name }}
|
||||
GH_TOKEN: ${{ steps.get_workflow_token.outputs.token }}
|
||||
@@ -225,9 +209,6 @@ jobs:
|
||||
[ -n "${i686_PACKAGES}" ] && echo -e "- [x] \`i686\`" >> /tmp/pr.txt
|
||||
[ -n "${armv7l_PACKAGES}" ] && echo -e "- [x] \`armv7l\`" >> /tmp/pr.txt
|
||||
fi
|
||||
if [[ "${CHANGED_MANIFEST_FILES}" == "" ]]; then
|
||||
echo -e "##\n- [x] This PR has no manifest .filelist changes. _(Package changes have neither added nor removed files.)_" >> /tmp/pr.txt
|
||||
fi
|
||||
if [[ "${CHANGED_OTHER_FILES}" != "" ]]; then
|
||||
echo -e "### Other changed files:" >> /tmp/pr.txt
|
||||
for file in ${CHANGED_OTHER_FILES}
|
||||
@@ -235,16 +216,20 @@ jobs:
|
||||
echo "- ${file}" >> /tmp/pr.txt
|
||||
done
|
||||
fi
|
||||
if [[ "${CHANGED_MANIFEST_FILES}" == "" ]]; then
|
||||
echo -e "##\n- [x] This PR has no manifest .filelist changes. _(Package changes have neither added nor removed files.)_" >> /tmp/pr.txt
|
||||
fi
|
||||
echo -e "##\n### Run the following to get this pull request's changes locally for testing.\n\`\`\`bash" >> /tmp/pr.txt
|
||||
echo -e "CREW_REPO=https://github.com/chromebrew/chromebrew.git CREW_BRANCH=${{ env.BRANCH }} crew update \\" >> /tmp/pr.txt
|
||||
echo -e "&& yes | crew upgrade\n\`\`\`" >> /tmp/pr.txt
|
||||
cat /tmp/pr.txt
|
||||
PR_NUMBER=$(gh pr list -H ${CREW_BRANCH}| cut -f1)
|
||||
if [[ -z ${PR_NUMBER} ]]; then
|
||||
PR_NUMBER=$(gh pr create --reviewer chromebrew/active --title "Changes from ${{ env.BRANCH }} at ${TIMESTAMP}." -F /tmp/pr.txt | rev | cut -d"/" -f1 | rev)
|
||||
PR_NUMBER=$(gh pr create --reviewer chromebrew/active --title "${{ env.BRANCH }} at ${TIMESTAMP}." -F /tmp/pr.txt | rev | cut -d"/" -f1 | rev)
|
||||
else
|
||||
gh pr edit -F /tmp/pr.txt
|
||||
fi
|
||||
gh pr merge "${PR_NUMBER}" --auto
|
||||
# Draft PRs can not be set to automerge.
|
||||
gh pr merge "${PR_NUMBER}" --auto || true
|
||||
echo "PR_NUMBER is ${PR_NUMBER}"
|
||||
echo "PR_NUMBER=${PR_NUMBER}" >> "$GITHUB_ENV"
|
||||
|
||||
2
.github/workflows/Linter-Handoff.yml
vendored
2
.github/workflows/Linter-Handoff.yml
vendored
@@ -15,7 +15,7 @@ jobs:
|
||||
fetch-depth: 0
|
||||
- name: Get changed files
|
||||
id: changed-files
|
||||
uses: tj-actions/changed-files@v45
|
||||
uses: tj-actions/changed-files@v46
|
||||
- name: Get extensions of changed files
|
||||
id: changed-file-extensions
|
||||
run: |
|
||||
|
||||
100
.github/workflows/No-Compile-Needed.yml
vendored
100
.github/workflows/No-Compile-Needed.yml
vendored
@@ -67,23 +67,24 @@ jobs:
|
||||
TIMESTAMP="$(date -u +%F-%H%Z)"
|
||||
export TIMESTAMP
|
||||
echo "TIMESTAMP=${TIMESTAMP}" >> "$GITHUB_OUTPUT"
|
||||
- name: Get all changed package files
|
||||
id: changed-ruby-files
|
||||
uses: tj-actions/changed-files@v45
|
||||
- name: Get changed files
|
||||
id: changed-files
|
||||
uses: tj-actions/changed-files@v46
|
||||
with:
|
||||
base_sha: master
|
||||
files: packages/*.rb
|
||||
since_last_remote_commit: true
|
||||
files_yaml: |
|
||||
packages:
|
||||
- packages/*.rb
|
||||
- name: Export variables to github context
|
||||
id: changed-packages
|
||||
run: |
|
||||
if [[ -z "${{ steps.changed-ruby-files.outputs.all_changed_files }}" ]]; then
|
||||
echo "Branch ${{ env.BRANCH }} has no changed files."
|
||||
if [[ -z "${{ steps.changed-files.outputs.packages_all_changed_files }}" ]]; then
|
||||
echo "Branch ${{ env.BRANCH }} has no changed package files."
|
||||
exit 1
|
||||
fi
|
||||
# Convert "packages/foo.rb packages/bar.rb" (from steps.changed-ruby-files.outputs.all_changed_files) into "foo bar"
|
||||
echo "CHANGED_PACKAGES=$(echo "${{ steps.changed-ruby-files.outputs.all_changed_files }}" | xargs basename -s .rb | xargs)" >> "$GITHUB_ENV"
|
||||
echo "CHANGED_PACKAGES=$(echo "${{ steps.changed-ruby-files.outputs.all_changed_files }}" | xargs basename -s .rb | xargs)" >> "$GITHUB_OUTPUT"
|
||||
# Convert "packages/foo.rb packages/bar.rb" (from steps.changed-files.outputs.packages_all_changed_files) into "foo bar"
|
||||
echo "CHANGED_PACKAGES=$(echo "${{ steps.changed-files.outputs.packages_all_changed_files }}" | xargs basename -s .rb | xargs)" >> "$GITHUB_ENV"
|
||||
echo "CHANGED_PACKAGES=$(echo "${{ steps.changed-files.outputs.packages_all_changed_files }}" | xargs basename -s .rb | xargs)" >> "$GITHUB_OUTPUT"
|
||||
- name: Determine glibc and architecture package compatibility
|
||||
id: get-compatibility
|
||||
run: |
|
||||
@@ -316,13 +317,6 @@ jobs:
|
||||
fetch-depth: 0
|
||||
persist-credentials: true
|
||||
ref: ${{ inputs.branch || github.ref_name }}
|
||||
- name: Get all changed manifest files
|
||||
id: changed-manifest-files
|
||||
uses: tj-actions/changed-files@v45
|
||||
with:
|
||||
base_sha: master
|
||||
files: manifest/**
|
||||
since_last_remote_commit: true
|
||||
- name: Rebase to master
|
||||
run: |
|
||||
git config user.name "${{ github.actor }}"
|
||||
@@ -332,6 +326,23 @@ jobs:
|
||||
git reset --hard "origin/${{ env.BRANCH }}"
|
||||
git pull --rebase origin master && git push -f
|
||||
git log --oneline -10
|
||||
- name: Get changed files
|
||||
id: changed-files
|
||||
uses: tj-actions/changed-files@v46
|
||||
with:
|
||||
base_sha: master
|
||||
files_yaml: |
|
||||
manifest:
|
||||
- manifest/**
|
||||
packages:
|
||||
- packages/*.rb
|
||||
github:
|
||||
- .github/**
|
||||
other:
|
||||
- ./**
|
||||
- '!manifest/**'
|
||||
- '!packages/*.rb'
|
||||
- '!.github/**'
|
||||
- name: Get GH Token
|
||||
id: get_workflow_token
|
||||
uses: peter-murray/workflow-application-token-action@v4
|
||||
@@ -342,9 +353,11 @@ jobs:
|
||||
revoke_token: true
|
||||
- name: Create Pull Request
|
||||
env:
|
||||
CHANGED_MANIFEST_FILES: ${{ steps.changed-manifest-files.outputs.all_changed_files }}
|
||||
CHANGED_GITHUB_CONFIG_FILES: ${{ steps.changed-files.outputs.github_all_changed_files }}
|
||||
CHANGED_MANIFEST_FILES: ${{ steps.changed-files.outputs.manifest_all_changed_files }}
|
||||
CHANGED_OTHER_FILES: ${{ steps.changed-files.outputs.other_all_changed_files }}
|
||||
CHANGED_PACKAGES: ${{ needs.setup.outputs.changed_packages }}
|
||||
GH_BACKUP_TOKEN: ${{ steps.get_workflow_token.outputs.token }}
|
||||
GH_TOKEN: ${{ steps.get_workflow_token.outputs.token }}
|
||||
TIMESTAMP: ${{ needs.setup.outputs.timestamp }}
|
||||
i686_PACKAGES: ${{ needs.setup.outputs.i686_packages }}
|
||||
x86_64_PACKAGES: ${{ needs.setup.outputs.x86_64_packages }}
|
||||
@@ -352,16 +365,32 @@ jobs:
|
||||
run: |
|
||||
rm -rf /tmp/pr.txt
|
||||
echo -e "## Description" >> /tmp/pr.txt
|
||||
echo -e "- This PR has package updates using the No-Compile-Needed.yml workflow, which was pointed to the ${{ env.BRANCH }} branch.\n" >> /tmp/pr.txt
|
||||
echo -e "Updated packages:" >> /tmp/pr.txt
|
||||
for file in ${CHANGED_PACKAGES}
|
||||
do
|
||||
echo "- ${file}" >> /tmp/pr.txt
|
||||
done
|
||||
echo -e "##\nUpdates attempted for:" >> /tmp/pr.txt
|
||||
[ -n "${x86_64_PACKAGES}" ] && echo -e "- [x] \`x86_64\`" >> /tmp/pr.txt
|
||||
[ -n "${i686_PACKAGES}" ] && echo -e "- [x] \`i686\`" >> /tmp/pr.txt
|
||||
[ -n "${armv7l_PACKAGES}" ] && echo -e "- [x] \`armv7l\`" >> /tmp/pr.txt
|
||||
echo -e "- This PR was built using the No-Compile-Needed.yml workflow, which was pointed to the ${{ env.BRANCH }} branch.\n" >> /tmp/pr.txt
|
||||
if [[ "${CHANGED_GITHUB_CONFIG_FILES}" != "" ]]; then
|
||||
echo -e "### Updated GitHub configuration files:" >> /tmp/pr.txt
|
||||
for file in ${CHANGED_GITHUB_CONFIG_FILES}
|
||||
do
|
||||
echo "- ${file}" >> /tmp/pr.txt
|
||||
done
|
||||
fi
|
||||
if [[ "${CHANGED_PACKAGES}" != "" ]]; then
|
||||
echo -e "### Packages with Updated versions or Changed package files:" >> /tmp/pr.txt
|
||||
for file in ${CHANGED_PACKAGES}
|
||||
do
|
||||
echo "- ${file}" >> /tmp/pr.txt
|
||||
done
|
||||
echo -e "##\nBuilds attempted for:" >> /tmp/pr.txt
|
||||
[ -n "${x86_64_PACKAGES}" ] && echo -e "- [x] \`x86_64\`" >> /tmp/pr.txt
|
||||
[ -n "${i686_PACKAGES}" ] && echo -e "- [x] \`i686\`" >> /tmp/pr.txt
|
||||
[ -n "${armv7l_PACKAGES}" ] && echo -e "- [x] \`armv7l\`" >> /tmp/pr.txt
|
||||
fi
|
||||
if [[ "${CHANGED_OTHER_FILES}" != "" ]]; then
|
||||
echo -e "### Other changed files:" >> /tmp/pr.txt
|
||||
for file in ${CHANGED_OTHER_FILES}
|
||||
do
|
||||
echo "- ${file}" >> /tmp/pr.txt
|
||||
done
|
||||
fi
|
||||
if [[ "${CHANGED_MANIFEST_FILES}" == "" ]]; then
|
||||
echo -e "##\n- [x] This PR has no manifest .filelist changes. _(Package changes have neither added nor removed files.)_" >> /tmp/pr.txt
|
||||
fi
|
||||
@@ -369,15 +398,8 @@ jobs:
|
||||
echo -e "CREW_REPO=https://github.com/chromebrew/chromebrew.git CREW_BRANCH=${{ env.BRANCH }} crew update \\" >> /tmp/pr.txt
|
||||
echo -e "&& yes | crew upgrade\n\`\`\`" >> /tmp/pr.txt
|
||||
cat /tmp/pr.txt
|
||||
gh auth status >/dev/null 2>&1 || export GH_TOKEN="${GH_BACKUP_TOKEN}"
|
||||
PR_NUMBER=$(gh pr create --title "AutoUpdate: ${{ env.BRANCH }} started at ${TIMESTAMP}." -F /tmp/pr.txt | rev | cut -d"/" -f1 | rev)
|
||||
PR_NUMBER=$(gh pr create --reviewer chromebrew/active --title "Build: ${{ env.BRANCH }} started at ${TIMESTAMP}." -F /tmp/pr.txt | rev | cut -d"/" -f1 | rev)
|
||||
# Draft PRs can not be set to automerge.
|
||||
gh pr merge "${PR_NUMBER}" --auto || true
|
||||
echo "PR_NUMBER is ${PR_NUMBER}"
|
||||
echo "PR_NUMBER=${PR_NUMBER}" >> "$GITHUB_ENV"
|
||||
- name: Trigger Unit Test Workflow & Add Reviewer Team
|
||||
env:
|
||||
GH_BACKUP_TOKEN: ${{ steps.get_workflow_token.outputs.token }}
|
||||
GH_TOKEN: ${{ secrets.CREW_PR_TOKEN }}
|
||||
run: |
|
||||
gh auth status >/dev/null 2>&1 || export GH_TOKEN="${GH_BACKUP_TOKEN}"
|
||||
gh pr edit "${PR_NUMBER}" --add-reviewer chromebrew/active
|
||||
gh pr merge "${PR_NUMBER}" --auto
|
||||
|
||||
4
.github/workflows/Unit-Test.yml
vendored
4
.github/workflows/Unit-Test.yml
vendored
@@ -66,7 +66,7 @@ jobs:
|
||||
run: echo "$MATRIX_CONTEXT"
|
||||
- name: Get non-pkg changed files
|
||||
id: non-pkg-changed-files
|
||||
uses: tj-actions/changed-files@v45
|
||||
uses: tj-actions/changed-files@v46
|
||||
with:
|
||||
files_ignore: |
|
||||
.github/**
|
||||
@@ -76,7 +76,7 @@ jobs:
|
||||
tools/repology.json
|
||||
- name: Get all changed package files
|
||||
id: changed-ruby-files
|
||||
uses: tj-actions/changed-files@v45
|
||||
uses: tj-actions/changed-files@v46
|
||||
with:
|
||||
files: packages/*.rb
|
||||
- name: Export variables to github context
|
||||
|
||||
2
.github/workflows/Updater.yml
vendored
2
.github/workflows/Updater.yml
vendored
@@ -42,7 +42,7 @@ jobs:
|
||||
id: set-variables
|
||||
run: |
|
||||
export TIMESTAMP="$(date -u +%F-%H-%M)"
|
||||
export UPDATE_BRANCH_NAME="updates-${TIMESTAMP}"
|
||||
export UPDATE_BRANCH_NAME="automatic-updates-${TIMESTAMP}"
|
||||
echo "TIMESTAMP=${TIMESTAMP}" >> "$GITHUB_OUTPUT"
|
||||
echo "UPDATE_BRANCH_NAME=${UPDATE_BRANCH_NAME}" >> "$GITHUB_OUTPUT"
|
||||
- name: Git setup
|
||||
|
||||
Reference in New Issue
Block a user