Skip to content

Commit d3ceb6c

Browse files
committed
Merge remote-tracking branch 'origin/7-1-sec' into 7-1-stable
2 parents f2fae6a + 5b5f0da commit d3ceb6c

File tree

83 files changed

+1418
-1481
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

83 files changed

+1418
-1481
lines changed

.devcontainer/Dockerfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ COPY activerecord/activerecord.gemspec /tmp/rails/activerecord/
4444
COPY activestorage/activestorage.gemspec /tmp/rails/activestorage/
4545
COPY activesupport/activesupport.gemspec /tmp/rails/activesupport/
4646
COPY railties/railties.gemspec /tmp/rails/railties/
47+
COPY tools/releaser/releaser.gemspec /tmp/rails/tools/releaser/
4748
RUN cd /tmp/rails \
4849
&& bundle install \
4950
&& yarn install \
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: Rails releaser tests
2+
3+
on:
4+
pull_request:
5+
paths:
6+
- "tools/releaser/**"
7+
push:
8+
paths:
9+
- "tools/releaser/**"
10+
11+
permissions:
12+
contents: read
13+
14+
jobs:
15+
releaser_tests:
16+
name: releaser tests
17+
runs-on: ubuntu-latest
18+
19+
steps:
20+
- uses: actions/checkout@v4
21+
- name: Set up Ruby
22+
uses: ruby/setup-ruby@v1
23+
with:
24+
ruby-version: ruby
25+
- name: Bundle install
26+
run: bundle install
27+
working-directory: tools/releaser
28+
- run: bundle exec rake
29+
working-directory: tools/releaser

.github/workflows/release.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: Release
2+
3+
on:
4+
release:
5+
types: [published]
6+
7+
jobs:
8+
release:
9+
permissions:
10+
contents: write
11+
id-token: write
12+
13+
environment: release
14+
15+
runs-on: ubuntu-latest
16+
17+
steps:
18+
- uses: actions/checkout@v4
19+
- name: Set up Ruby
20+
uses: ruby/setup-ruby@v1
21+
with:
22+
ruby-version: ruby
23+
- uses: actions/setup-node@v4
24+
with:
25+
node-version: lts/*
26+
registry-url: 'https://registry.npmjs.org'
27+
- name: Configure trusted publishing credentials
28+
uses: rubygems/configure-rubygems-credentials@v1.0.0
29+
- name: Bundle install
30+
run: bundle install
31+
working-directory: tools/releaser
32+
- name: Run release rake task
33+
run: bundle exec rake push
34+
shell: bash
35+
working-directory: tools/releaser
36+
env:
37+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
38+
- name: Wait for release to propagate
39+
run: gem exec rubygems-await pkg/*.gem
40+
shell: bash

Gemfile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ end
1212
# We need a newish Rake since Active Job sets its test tasks' descriptions.
1313
gem "rake", ">= 13"
1414

15+
gem "releaser", path: "tools/releaser"
16+
1517
gem "sprockets-rails", ">= 2.0.0"
1618
gem "propshaft", ">= 0.1.7"
1719
gem "capybara", ">= 3.39"

Gemfile.lock

Lines changed: 64 additions & 56 deletions
Original file line numberDiff line numberDiff line change
@@ -10,71 +10,71 @@ GIT
1010
PATH
1111
remote: .
1212
specs:
13-
actioncable (7.1.4)
14-
actionpack (= 7.1.4)
15-
activesupport (= 7.1.4)
13+
actioncable (7.1.4.1)
14+
actionpack (= 7.1.4.1)
15+
activesupport (= 7.1.4.1)
1616
nio4r (~> 2.0)
1717
websocket-driver (>= 0.6.1)
1818
zeitwerk (~> 2.6)
19-
actionmailbox (7.1.4)
20-
actionpack (= 7.1.4)
21-
activejob (= 7.1.4)
22-
activerecord (= 7.1.4)
23-
activestorage (= 7.1.4)
24-
activesupport (= 7.1.4)
19+
actionmailbox (7.1.4.1)
20+
actionpack (= 7.1.4.1)
21+
activejob (= 7.1.4.1)
22+
activerecord (= 7.1.4.1)
23+
activestorage (= 7.1.4.1)
24+
activesupport (= 7.1.4.1)
2525
mail (>= 2.7.1)
2626
net-imap
2727
net-pop
2828
net-smtp
29-
actionmailer (7.1.4)
30-
actionpack (= 7.1.4)
31-
actionview (= 7.1.4)
32-
activejob (= 7.1.4)
33-
activesupport (= 7.1.4)
29+
actionmailer (7.1.4.1)
30+
actionpack (= 7.1.4.1)
31+
actionview (= 7.1.4.1)
32+
activejob (= 7.1.4.1)
33+
activesupport (= 7.1.4.1)
3434
mail (~> 2.5, >= 2.5.4)
3535
net-imap
3636
net-pop
3737
net-smtp
3838
rails-dom-testing (~> 2.2)
39-
actionpack (7.1.4)
40-
actionview (= 7.1.4)
41-
activesupport (= 7.1.4)
39+
actionpack (7.1.4.1)
40+
actionview (= 7.1.4.1)
41+
activesupport (= 7.1.4.1)
4242
nokogiri (>= 1.8.5)
4343
racc
4444
rack (>= 2.2.4)
4545
rack-session (>= 1.0.1)
4646
rack-test (>= 0.6.3)
4747
rails-dom-testing (~> 2.2)
4848
rails-html-sanitizer (~> 1.6)
49-
actiontext (7.1.4)
50-
actionpack (= 7.1.4)
51-
activerecord (= 7.1.4)
52-
activestorage (= 7.1.4)
53-
activesupport (= 7.1.4)
49+
actiontext (7.1.4.1)
50+
actionpack (= 7.1.4.1)
51+
activerecord (= 7.1.4.1)
52+
activestorage (= 7.1.4.1)
53+
activesupport (= 7.1.4.1)
5454
globalid (>= 0.6.0)
5555
nokogiri (>= 1.8.5)
56-
actionview (7.1.4)
57-
activesupport (= 7.1.4)
56+
actionview (7.1.4.1)
57+
activesupport (= 7.1.4.1)
5858
builder (~> 3.1)
5959
erubi (~> 1.11)
6060
rails-dom-testing (~> 2.2)
6161
rails-html-sanitizer (~> 1.6)
62-
activejob (7.1.4)
63-
activesupport (= 7.1.4)
62+
activejob (7.1.4.1)
63+
activesupport (= 7.1.4.1)
6464
globalid (>= 0.3.6)
65-
activemodel (7.1.4)
66-
activesupport (= 7.1.4)
67-
activerecord (7.1.4)
68-
activemodel (= 7.1.4)
69-
activesupport (= 7.1.4)
65+
activemodel (7.1.4.1)
66+
activesupport (= 7.1.4.1)
67+
activerecord (7.1.4.1)
68+
activemodel (= 7.1.4.1)
69+
activesupport (= 7.1.4.1)
7070
timeout (>= 0.4.0)
71-
activestorage (7.1.4)
72-
actionpack (= 7.1.4)
73-
activejob (= 7.1.4)
74-
activerecord (= 7.1.4)
75-
activesupport (= 7.1.4)
71+
activestorage (7.1.4.1)
72+
actionpack (= 7.1.4.1)
73+
activejob (= 7.1.4.1)
74+
activerecord (= 7.1.4.1)
75+
activesupport (= 7.1.4.1)
7676
marcel (~> 1.0)
77-
activesupport (7.1.4)
77+
activesupport (7.1.4.1)
7878
base64
7979
benchmark (>= 0.3)
8080
bigdecimal
@@ -87,29 +87,36 @@ PATH
8787
mutex_m
8888
securerandom (>= 0.3)
8989
tzinfo (~> 2.0)
90-
rails (7.1.4)
91-
actioncable (= 7.1.4)
92-
actionmailbox (= 7.1.4)
93-
actionmailer (= 7.1.4)
94-
actionpack (= 7.1.4)
95-
actiontext (= 7.1.4)
96-
actionview (= 7.1.4)
97-
activejob (= 7.1.4)
98-
activemodel (= 7.1.4)
99-
activerecord (= 7.1.4)
100-
activestorage (= 7.1.4)
101-
activesupport (= 7.1.4)
90+
rails (7.1.4.1)
91+
actioncable (= 7.1.4.1)
92+
actionmailbox (= 7.1.4.1)
93+
actionmailer (= 7.1.4.1)
94+
actionpack (= 7.1.4.1)
95+
actiontext (= 7.1.4.1)
96+
actionview (= 7.1.4.1)
97+
activejob (= 7.1.4.1)
98+
activemodel (= 7.1.4.1)
99+
activerecord (= 7.1.4.1)
100+
activestorage (= 7.1.4.1)
101+
activesupport (= 7.1.4.1)
102102
bundler (>= 1.15.0)
103-
railties (= 7.1.4)
104-
railties (7.1.4)
105-
actionpack (= 7.1.4)
106-
activesupport (= 7.1.4)
103+
railties (= 7.1.4.1)
104+
railties (7.1.4.1)
105+
actionpack (= 7.1.4.1)
106+
activesupport (= 7.1.4.1)
107107
irb
108108
rackup (>= 1.0.0)
109109
rake (>= 12.2)
110110
thor (~> 1.0, >= 1.2.2)
111111
zeitwerk (~> 2.6)
112112

113+
PATH
114+
remote: tools/releaser
115+
specs:
116+
releaser (1.0.0)
117+
minitest
118+
rake (~> 13.0)
119+
113120
GEM
114121
remote: https://rubygems.org/
115122
specs:
@@ -269,7 +276,7 @@ GEM
269276
signet (>= 0.16, < 2.a)
270277
hashdiff (1.0.1)
271278
httpclient (2.8.3)
272-
i18n (1.14.5)
279+
i18n (1.14.6)
273280
concurrent-ruby (~> 1.0)
274281
image_processing (1.12.2)
275282
mini_magick (>= 4.9.5, < 5)
@@ -343,7 +350,7 @@ GEM
343350
mysql2 (0.5.6)
344351
net-http-persistent (4.0.1)
345352
connection_pool (~> 2.2)
346-
net-imap (0.4.14)
353+
net-imap (0.4.17)
347354
date
348355
net-protocol
349356
net-pop (0.1.2)
@@ -554,7 +561,7 @@ GEM
554561
websocket-extensions (0.1.5)
555562
xpath (3.2.0)
556563
nokogiri (~> 1.8)
557-
zeitwerk (2.6.17)
564+
zeitwerk (2.7.0)
558565

559566
PLATFORMS
560567
ruby
@@ -610,6 +617,7 @@ DEPENDENCIES
610617
redcarpet (~> 3.2.3)
611618
redis (>= 4.0.1)
612619
redis-namespace
620+
releaser!
613621
resque
614622
resque-scheduler
615623
rexml

RAILS_VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
7.1.4
1+
7.1.4.1

RELEASING_RAILS.md

Lines changed: 18 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ Obviously Rails cannot be released when it depends on unreleased code.
2424
Contact the authors of those particular gems and work out a release date that
2525
suits them.
2626

27-
### Announce your plans to the rest of the team on Campfire
27+
### Announce your plans to the rest of the team on Basecamp
2828

2929
Let them know of your plans to release.
3030

@@ -56,58 +56,38 @@ Include an RC number if appropriate, e.g. `6.0.0.rc1`.
5656

5757
### Build and test the gem.
5858

59-
Run `rake verify` to generate the gems and install them locally. `verify` also
60-
generates a Rails app with a migration and boots it to smoke test with in your
61-
browser.
59+
Run `rake install` to generate the gems and install them locally. You can now
60+
use the version installed locally to generate a new app and check if everything
61+
is working as expected.
6262

6363
This will stop you from looking silly when you push an RC to rubygems.org and
6464
then realize it is broken.
6565

66-
### Check credentials for RubyGems, npm, and GitHub
67-
68-
For npm run `npm whoami` to check that you are logged in (`npm login` if not).
69-
70-
For RubyGems run `gem login`. If there's no output you are logged in.
66+
### Check credentials for GitHub
7167

7268
For GitHub run `gh auth status` to check that you are logged in (run `gh login` if not).
7369

74-
npm and RubyGems require MFA. The release task will attempt to use a yubikey if
75-
available, which as we have release several packages at once is strongly
76-
recommended. Check that `ykman oath accounts list` has an entry for both
77-
`npmjs.com` and `rubygems.org`, if not refer to
78-
https://tenderlovemaking.com/2021/10/26/publishing-gems-with-your-yubikey.html
79-
for setup instructions.
80-
81-
### Release to RubyGems and npm.
82-
83-
IMPORTANT: Several gems have JavaScript components that are released as npm
84-
packages, so you must have Node.js installed, have an npm account (npmjs.com),
85-
and be a package owner for `@rails/actioncable`, `@rails/actiontext`,
86-
`@rails/activestorage`, and `@rails/ujs`. You can check this by making sure your
87-
npm user (`npm whoami`) is listed as an owner (`npm owner ls <pkg>`) of each
88-
package. Do not release until you're set up with npm!
89-
9070
The release task will sign the release tag. If you haven't got commit signing
9171
set up, use https://git-scm.com/book/en/v2/Git-Tools-Signing-Your-Work as a
9272
guide. You can generate keys with the GPG suite from here: https://gpgtools.org.
9373

94-
Run `rake changelog:header` to put a header with the new version in every
95-
CHANGELOG. Don't commit this, the release task handles it.
74+
Run `rake prep_release` to prepare the release. This will populate the gemspecs and
75+
npm package.json with the current RAILS_VERSION, add the header to the CHANGELOGs,
76+
build the gems, and check if bundler can resolve the dependencies.
9677

97-
Run `rake release`. This will populate the gemspecs and npm package.json with
98-
the current RAILS_VERSION, commit the changes, tag it, and push the gems to
99-
rubygems.org.
78+
You can now inspect the results in the diff and see if you are happy with the
79+
changes.
10080

101-
### Make GitHub Releases from pushed tags
81+
To release, Run `rake release`. This will commit the changes, tag it, and create a GitHub
82+
release with the proper release notes in draft mode.
10283

103-
We use GitHub Releases to publish the combined release summary for all gems. We
104-
can use a rake task and [GitHub cli](https://cli.github.com/) to do this
105-
(releases can also be created or edited on the web).
84+
Open the corresponding GitHub release draft and check that the release notes
85+
are correct. If everything is fine, publish the release.
10686

107-
```
108-
bundle exec rake changelog:release_summary > ../6-1-7-release-summary.md
109-
gh release create v6.1.7 -R rails/rails -F ../6-1-7-release-summary.md
110-
```
87+
### Publish the gems
88+
89+
To publish the gems approve the [Release workflow in GitHub Actions](https://github.com/rails/rails/actions/workflows/release.yml),
90+
that was created after the release was published.
11191

11292
### Send Rails release announcements
11393

@@ -117,7 +97,6 @@ lists where you should announce:
11797

11898
* [rubyonrails-core](https://discuss.rubyonrails.org/c/rubyonrails-core)
11999
* [rubyonrails-talk](https://discuss.rubyonrails.org/c/rubyonrails-talk)
120-
* ruby-talk@ruby-lang.org
121100

122101
Use Markdown format for your announcement. Remember to ask people to report
123102
issues with the release candidate to the rails-core mailing list.

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy