Skip to content

Commit d5563c1

Browse files
committed
Add sparse_checkout option for Bundler git sources
1 parent ae1f702 commit d5563c1

39 files changed

+243
-49
lines changed

bundler/lib/bundler/dependency.rb

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,12 @@ def glob
5858
@glob = @options["glob"]
5959
end
6060

61+
def sparse_checkout
62+
return @sparse_checkout if defined?(@sparse_checkout)
63+
64+
@sparse_checkout = @options["sparse_checkout"]
65+
end
66+
6167
def platforms
6268
@platforms ||= Array(@options["platforms"])
6369
end

bundler/lib/bundler/dsl.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ def self.evaluate(gemfile, lockfile, unlock)
1717
VALID_PLATFORMS = Bundler::CurrentRuby::PLATFORM_MAP.keys.freeze
1818

1919
VALID_KEYS = %w[group groups git path glob name branch ref tag require submodules
20-
platform platforms source install_if force_ruby_platform].freeze
20+
platform platforms source install_if force_ruby_platform sparse_checkout].freeze
2121

2222
GITHUB_PULL_REQUEST_URL = %r{\Ahttps://github\.com/([A-Za-z0-9_\-\.]+/[A-Za-z0-9_\-\.]+)/pull/(\d+)\z}
2323
GITLAB_MERGE_REQUEST_URL = %r{\Ahttps://gitlab\.com/([A-Za-z0-9_\-\./]+)/-/merge_requests/(\d+)\z}

bundler/lib/bundler/lockfile_parser.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ def to_s
4747
PATH = "PATH"
4848
PLUGIN = "PLUGIN SOURCE"
4949
SPECS = " specs:"
50-
OPTIONS = /^ ([a-z]+): (.*)$/i
50+
OPTIONS = /^ ([a-z_]+): (.*)$/i
5151
SOURCE = [GIT, GEM, PATH, PLUGIN].freeze
5252

5353
SECTIONS_BY_VERSION_INTRODUCED = {

bundler/lib/bundler/man/bundle-add.1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
.\" generated with Ronn-NG/v0.10.1
22
.\" http://github.com/apjanke/ronn-ng/tree/0.10.1
3-
.TH "BUNDLE\-ADD" "1" "September 2025" ""
3+
.TH "BUNDLE\-ADD" "1" "February 2026" ""
44
.SH "NAME"
55
\fBbundle\-add\fR \- Add gem to the Gemfile and run bundle install
66
.SH "SYNOPSIS"

bundler/lib/bundler/man/bundle-binstubs.1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
.\" generated with Ronn-NG/v0.10.1
22
.\" http://github.com/apjanke/ronn-ng/tree/0.10.1
3-
.TH "BUNDLE\-BINSTUBS" "1" "September 2025" ""
3+
.TH "BUNDLE\-BINSTUBS" "1" "February 2026" ""
44
.SH "NAME"
55
\fBbundle\-binstubs\fR \- Install the binstubs of the listed gems
66
.SH "SYNOPSIS"

bundler/lib/bundler/man/bundle-cache.1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
.\" generated with Ronn-NG/v0.10.1
22
.\" http://github.com/apjanke/ronn-ng/tree/0.10.1
3-
.TH "BUNDLE\-CACHE" "1" "September 2025" ""
3+
.TH "BUNDLE\-CACHE" "1" "February 2026" ""
44
.SH "NAME"
55
\fBbundle\-cache\fR \- Package your needed \fB\.gem\fR files into your application
66
.SH "SYNOPSIS"

bundler/lib/bundler/man/bundle-check.1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
.\" generated with Ronn-NG/v0.10.1
22
.\" http://github.com/apjanke/ronn-ng/tree/0.10.1
3-
.TH "BUNDLE\-CHECK" "1" "September 2025" ""
3+
.TH "BUNDLE\-CHECK" "1" "February 2026" ""
44
.SH "NAME"
55
\fBbundle\-check\fR \- Verifies if dependencies are satisfied by installed gems
66
.SH "SYNOPSIS"

bundler/lib/bundler/man/bundle-clean.1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
.\" generated with Ronn-NG/v0.10.1
22
.\" http://github.com/apjanke/ronn-ng/tree/0.10.1
3-
.TH "BUNDLE\-CLEAN" "1" "September 2025" ""
3+
.TH "BUNDLE\-CLEAN" "1" "February 2026" ""
44
.SH "NAME"
55
\fBbundle\-clean\fR \- Cleans up unused gems in your bundler directory
66
.SH "SYNOPSIS"

bundler/lib/bundler/man/bundle-config.1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
.\" generated with Ronn-NG/v0.10.1
22
.\" http://github.com/apjanke/ronn-ng/tree/0.10.1
3-
.TH "BUNDLE\-CONFIG" "1" "September 2025" ""
3+
.TH "BUNDLE\-CONFIG" "1" "February 2026" ""
44
.SH "NAME"
55
\fBbundle\-config\fR \- Set bundler configuration options
66
.SH "SYNOPSIS"

bundler/lib/bundler/man/bundle-console.1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
.\" generated with Ronn-NG/v0.10.1
22
.\" http://github.com/apjanke/ronn-ng/tree/0.10.1
3-
.TH "BUNDLE\-CONSOLE" "1" "September 2025" ""
3+
.TH "BUNDLE\-CONSOLE" "1" "February 2026" ""
44
.SH "NAME"
55
\fBbundle\-console\fR \- Open an IRB session with the bundle pre\-loaded
66
.SH "SYNOPSIS"

0 commit comments

Comments
 (0)