Skip to content

Commit

Permalink
Merge branch 'Homebrew:master' into daggerizing-docker-workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
marcosnils committed Jun 21, 2024
2 parents 0b767ee + 907f54a commit 3e55b31
Show file tree
Hide file tree
Showing 288 changed files with 8,740 additions and 7,490 deletions.
31 changes: 30 additions & 1 deletion .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ updates:
directory: /
schedule:
interval: daily
allow:
- dependency-type: all
# The actions in triage-issues.yml are updated in the Homebrew/.github repo
ignore:
- dependency-name: actions/stale
Expand All @@ -20,4 +22,31 @@ updates:
interval: daily
allow:
- dependency-type: all
versioning-strategy: lockfile-only

- package-ecosystem: npm
directory: /
schedule:
interval: daily
allow:
- dependency-type: all

- package-ecosystem: docker
directory: /
schedule:
interval: daily
allow:
- dependency-type: all

- package-ecosystem: devcontainers
directory: /
schedule:
interval: daily
allow:
- dependency-type: all

- package-ecosystem: pip
directory: /
schedule:
interval: daily
allow:
- dependency-type: all
2 changes: 1 addition & 1 deletion .github/maintainers.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
["Moisan","timsutton","MikeMcQuaid","singingwolfboy","issyl0","dtrodrigues","dduugg","bayandin","Bo98","reitermarkus","SMillerDev","chenrui333","samford","fxcoudert","woodruffw","EricFromCanada","iMichka","alebcay","miccal","razvanazamfirei","branchvincent","cho-m","ZhongRuoyu","carlocab","Rylan12","nandahkrishna","krehel","bevanjkay","apainintheneck","p-linnane"]
["Moisan","timsutton","MikeMcQuaid","issyl0","dtrodrigues","dduugg","bayandin","Bo98","reitermarkus","SMillerDev","chenrui333","samford","fxcoudert","woodruffw","EricFromCanada","iMichka","alebcay","miccal","razvanazamfirei","branchvincent","cho-m","ZhongRuoyu","carlocab","Rylan12","nandahkrishna","krehel","bevanjkay","apainintheneck","p-linnane"]
11 changes: 1 addition & 10 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,4 @@ jobs:
with:
version: "latest"
verb: call
args: |
publish-all --src .
--hub-username brewtestbot \
--hub-token HOMEBREW_BREW_DOCKER_TOKEN \
--gh-username BrewTestBot \
--gh-token HOMEBREW_BREW_GITHUB_PACKAGES_TOKEN \
--commit-sha ${{ github.sha }} \
--brew-version "${GITHUB_REF:10}"
args: publish-all --src . --hub-username brewtestbot --hub-token HOMEBREW_BREW_DOCKER_TOKEN --gh-username BrewTestBot --gh-token HOMEBREW_BREW_GITHUB_PACKAGES_TOKEN --commit-sha ${{ github.sha }} --repo-owner "${GITHUB_REPOSITORY_OWNER}" --repo "${GITHUB_REPOSITORY}" --brew-version "${GITHUB_REF:10}"
70 changes: 23 additions & 47 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ on:

permissions:
contents: read
pages: read

env:
HOMEBREW_DEVELOPER: 1
Expand All @@ -17,8 +18,7 @@ env:
HOMEBREW_NO_INSTALL_CLEANUP: 1

jobs:
linting:
if: github.repository == 'Homebrew/brew'
docs:
runs-on: ubuntu-22.04
steps:
- name: Set up Homebrew
Expand All @@ -29,13 +29,16 @@ jobs:
cask: false
test-bot: false

- name: Checkout repository
uses: actions/checkout@v4

- name: Install vale
run: brew install vale

- name: Lint docs
working-directory: ${{ steps.set-up-homebrew.outputs.repository-path }}
- name: Cleanup Homebrew/brew docs
if: github.repository == 'Homebrew/brew'
run: |
set -euo pipefail
set -xeuo pipefail
# Avoid failing on broken symlinks.
rm Library/Homebrew/os/mac/pkgconfig/fuse/fuse.pc
Expand All @@ -44,56 +47,29 @@ jobs:
# No ignore support (https://github.com/errata-ai/vale/issues/131).
rm -r Library/Homebrew/vendor
vale .
# Restore removed files.
git reset --hard
- name: Run Vale
run: vale docs/

- name: Install Ruby
uses: ruby/setup-ruby@943103cae7d3f1bb1e4951d5fcc7928b40e4b742 # v1.177.1
uses: ruby/setup-ruby@3783f195e29b74ae398d7caca108814bbafde90e # v1.180.1
with:
bundler-cache: true
working-directory: ${{ steps.set-up-homebrew.outputs.repository-path }}/docs
working-directory: docs

- name: Check Markdown syntax
working-directory: ${{ steps.set-up-homebrew.outputs.repository-path }}/docs
working-directory: docs
run: bundle exec rake lint

- name: Check code blocks conform to our Ruby style guide
working-directory: ${{ steps.set-up-homebrew.outputs.repository-path }}/docs
run: brew style .
run: brew style docs

- name: Build the site and check for broken links
working-directory: ${{ steps.set-up-homebrew.outputs.repository-path }}/docs
run: |
bundle exec rake test
- name: Generate formulae.brew.sh API samples
if: github.repository == 'Homebrew/formulae.brew.sh'
working-directory: docs
run: ../script/generate-api-samples.rb

rubydoc:
if: github.repository == 'Homebrew/brew'
runs-on: ubuntu-22.04
env:
BUNDLE_GEMFILE: ${{ github.workspace }}/rubydoc/Gemfile
steps:
- name: Set up Homebrew
id: set-up-homebrew
uses: Homebrew/actions/setup-homebrew@master
with:
core: false
cask: false
test-bot: false

- name: Checkout Homebrew/rubydoc.brew.sh
uses: actions/checkout@v4
with:
repository: Homebrew/rubydoc.brew.sh
path: rubydoc

- name: Install Ruby
uses: ruby/setup-ruby@943103cae7d3f1bb1e4951d5fcc7928b40e4b742 # v1.177.1
with:
bundler-cache: true
working-directory: rubydoc

- name: Process rubydoc comments
working-directory: ${{ steps.set-up-homebrew.outputs.repository-path }}/Library/Homebrew
run: bundle exec yard doc --no-output --fail-on-warning
- name: Build the site and check for broken links
working-directory: docs
run: bundle exec rake test
env:
JEKYLL_GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
48 changes: 48 additions & 0 deletions .github/workflows/rubydoc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
name: Ruby Documentation CI

on:
push:
branches:
- master
pull_request:

permissions:
contents: read

env:
HOMEBREW_DEVELOPER: 1
HOMEBREW_NO_AUTO_UPDATE: 1
HOMEBREW_NO_ENV_HINTS: 1
HOMEBREW_BOOTSNAP: 1
HOMEBREW_NO_INSTALL_CLEANUP: 1

jobs:
rubydoc:
if: github.repository == 'Homebrew/brew'
runs-on: ubuntu-22.04
env:
BUNDLE_GEMFILE: ${{ github.workspace }}/rubydoc/Gemfile
steps:
- name: Set up Homebrew
id: set-up-homebrew
uses: Homebrew/actions/setup-homebrew@master
with:
core: false
cask: false
test-bot: false

- name: Checkout Homebrew/rubydoc.brew.sh
uses: actions/checkout@v4
with:
repository: Homebrew/rubydoc.brew.sh
path: rubydoc

- name: Install Ruby
uses: ruby/setup-ruby@3783f195e29b74ae398d7caca108814bbafde90e # v1.180.1
with:
bundler-cache: true
working-directory: rubydoc

- name: Process rubydoc comments
working-directory: ${{ steps.set-up-homebrew.outputs.repository-path }}/Library/Homebrew
run: bundle exec yard doc --no-output --fail-on-warning
2 changes: 1 addition & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,7 @@ jobs:
HOMEBREW_BUILDPULSE_ACCOUNT_ID: 1503512
HOMEBREW_BUILDPULSE_REPOSITORY_ID: 53238813

- uses: codecov/codecov-action@125fc84a9a348dbcf27191600683ec096ec9021c # v4.4.1
- uses: codecov/codecov-action@e28ff129e5465c2c0dcc6f003fc735cb6ae0c673 # v4.5.0
with:
working-directory: ${{ steps.set-up-homebrew.outputs.repository-path }}
files: Library/Homebrew/test/coverage/coverage.xml
Expand Down
1 change: 0 additions & 1 deletion .ruby-version

This file was deleted.

11 changes: 2 additions & 9 deletions Library/.rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ Cask/Desc:
Description: "Ensure that the desc stanza conforms to various content and style checks."
Enabled: true

Cask/HomepageUrlTrailingSlash:
Description: "Ensure that the homepage url has a slash after the domain name."
Cask/HomepageUrlStyling:
Description: "Ensure that the homepage url has the correct format and styling."
Enabled: true

Cask/StanzaGrouping:
Expand Down Expand Up @@ -244,8 +244,6 @@ RSpec/MultipleMemoizedHelpers:

RSpec/DescribedClassModuleWrapping:
Enabled: true
RSpec/FilePath:
SpecSuffixOnly: true
# Annoying to have these autoremoved.
RSpec/Focus:
AutoCorrect: false
Expand Down Expand Up @@ -406,11 +404,6 @@ Style/RescueStandardError:
Style/ReturnNil:
Enabled: true

# Broken with rubocop-1.64.0, tries to autocorrect calls to e.g. :"1?"
# TODO: report to rubocop
Style/SendWithLiteralMethodName:
Enabled: false

# We have no use for using `warn` because we
# are calling Ruby with warnings disabled.
Style/StderrPuts:
Expand Down
1 change: 1 addition & 0 deletions Library/Homebrew/.ruby-version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
3.3.3
Loading

0 comments on commit 3e55b31

Please sign in to comment.