[rubygems/rubygems] Consistently use "lockfile" over "lock file"
https://github.com/rubygems/rubygems/commit/e891be9197
This commit is contained in:
parent
33201adf68
commit
bb1b5877a7
Notes:
git
2025-03-24 04:25:33 +00:00
@ -813,9 +813,9 @@ module Bundler
|
||||
[@new_platforms.any?, "you are adding a new platform to your lockfile"],
|
||||
[@path_changes, "the gemspecs for path gems changed"],
|
||||
[@local_changes, "the gemspecs for git local gems changed"],
|
||||
[@missing_lockfile_dep, "your lock file is missing \"#{@missing_lockfile_dep}\""],
|
||||
[@missing_lockfile_dep, "your lockfile is missing \"#{@missing_lockfile_dep}\""],
|
||||
[@unlocking_bundler, "an update to the version of Bundler itself was requested"],
|
||||
[@locked_spec_with_missing_deps, "your lock file includes \"#{@locked_spec_with_missing_deps}\" but not some of its dependencies"],
|
||||
[@locked_spec_with_missing_deps, "your lockfile includes \"#{@locked_spec_with_missing_deps}\" but not some of its dependencies"],
|
||||
[@locked_spec_with_invalid_deps, "your lockfile does not satisfy dependencies of \"#{@locked_spec_with_invalid_deps}\""],
|
||||
].select(&:first).map(&:last).join(", ")
|
||||
end
|
||||
|
@ -196,7 +196,7 @@ module Bundler
|
||||
|
||||
# If in frozen mode, we fallback to a non-installable candidate because by
|
||||
# doing this we avoid re-resolving and potentially end up changing the
|
||||
# lock file, which is not allowed. In that case, we will give a proper error
|
||||
# lockfile, which is not allowed. In that case, we will give a proper error
|
||||
# about the mismatch higher up the stack, right before trying to install the
|
||||
# bad gem.
|
||||
def choose_compatible(candidates, fallback_to_non_installable: Bundler.frozen_bundle?)
|
||||
|
@ -195,7 +195,7 @@ module Bundler
|
||||
@sources[name]
|
||||
end
|
||||
|
||||
# @param [Hash] The options that are present in the lock file
|
||||
# @param [Hash] The options that are present in the lockfile
|
||||
# @return [API::Source] the instance of the class that handles the source
|
||||
# type passed in locked_opts
|
||||
def from_lock(locked_opts)
|
||||
|
@ -67,7 +67,7 @@ module Bundler
|
||||
# to check out same version of gem later.
|
||||
#
|
||||
# There options are passed when the source plugin is created from the
|
||||
# lock file.
|
||||
# lockfile.
|
||||
#
|
||||
# @return [Hash]
|
||||
def options_to_lock
|
||||
|
@ -17,7 +17,7 @@ module Bundler
|
||||
# Some candidates may also keep some information explicitly about the
|
||||
# package they refer to. These candidates are referred to as "canonical" and
|
||||
# are used when materializing resolution results back into RubyGems
|
||||
# specifications that can be installed, written to lock files, and so on.
|
||||
# specifications that can be installed, written to lockfiles, and so on.
|
||||
#
|
||||
class Candidate
|
||||
include Comparable
|
||||
|
@ -33,7 +33,7 @@ RSpec.describe Bundler::Definition do
|
||||
before { Bundler::Definition.no_lock = true }
|
||||
after { Bundler::Definition.no_lock = false }
|
||||
|
||||
it "does not create a lock file" do
|
||||
it "does not create a lockfile" do
|
||||
subject.lock
|
||||
expect(bundled_app_lock).not_to be_file
|
||||
end
|
||||
|
@ -59,7 +59,7 @@ RSpec.describe Bundler::SharedHelpers do
|
||||
|
||||
before { allow(subject).to receive(:default_gemfile).and_return(gemfile_path) }
|
||||
|
||||
it "returns the lock file path" do
|
||||
it "returns the lockfile path" do
|
||||
expect(subject.default_lockfile).to eq(expected_lockfile_path)
|
||||
end
|
||||
end
|
||||
|
@ -258,7 +258,7 @@ RSpec.describe "bundle check" do
|
||||
expect(err).not_to include("Unfortunately, a fatal error has occurred. ")
|
||||
end
|
||||
|
||||
it "fails when there's no lock file and frozen is set" do
|
||||
it "fails when there's no lockfile and frozen is set" do
|
||||
install_gemfile <<-G
|
||||
source "https://gem.repo1"
|
||||
gem "foo"
|
||||
|
@ -49,7 +49,7 @@ RSpec.describe "bundle install with gem sources" do
|
||||
expect(bundled_app(".bundle")).not_to exist
|
||||
end
|
||||
|
||||
it "creates lock files based on the Gemfile name" do
|
||||
it "creates lockfiles based on the Gemfile name" do
|
||||
gemfile bundled_app("OmgFile"), <<-G
|
||||
source "https://gem.repo1"
|
||||
gem "myrack", "1.0"
|
||||
|
@ -80,7 +80,7 @@ RSpec.describe "bundle update" do
|
||||
end
|
||||
|
||||
describe "with --gemfile" do
|
||||
it "creates lock files based on the Gemfile name" do
|
||||
it "creates lockfiles based on the Gemfile name" do
|
||||
gemfile bundled_app("OmgFile"), <<-G
|
||||
source "https://gem.repo1"
|
||||
gem "myrack", "1.0"
|
||||
|
@ -321,7 +321,7 @@ RSpec.describe "install in deployment or frozen mode" do
|
||||
L
|
||||
|
||||
bundle :install, env: { "BUNDLE_FROZEN" => "true" }, raise_on_error: false, artifice: "compact_index"
|
||||
expect(err).to include("Your lock file is missing \"bar\", but the lockfile can't be updated because frozen mode is set")
|
||||
expect(err).to include("Your lockfile is missing \"bar\", but the lockfile can't be updated because frozen mode is set")
|
||||
end
|
||||
|
||||
it "explodes if a path gem is missing" do
|
||||
|
@ -273,7 +273,7 @@ RSpec.describe "bundle install with gems on multiple sources" do
|
||||
expect(the_bundle).to include_gems("depends_on_myrack 1.0.1", "myrack 1.0.0", source: "remote3")
|
||||
|
||||
# In https://github.com/bundler/bundler/issues/3585 this failed
|
||||
# when there is already a lock file, and the gems are missing, so try again
|
||||
# when there is already a lockfile, and the gems are missing, so try again
|
||||
system_gems []
|
||||
bundle :install, artifice: "compact_index"
|
||||
|
||||
@ -482,7 +482,7 @@ RSpec.describe "bundle install with gems on multiple sources" do
|
||||
expect(the_bundle).to include_gems("depends_on_myrack 1.0.1", "myrack 1.0.0")
|
||||
|
||||
# In https://github.com/rubygems/bundler/issues/3585 this failed
|
||||
# when there is already a lock file, and the gems are missing, so try again
|
||||
# when there is already a lockfile, and the gems are missing, so try again
|
||||
system_gems []
|
||||
bundle :install, artifice: "compact_index"
|
||||
|
||||
|
@ -91,7 +91,7 @@ RSpec.describe "bundle install with specific platforms" do
|
||||
#{Bundler::VERSION}
|
||||
L
|
||||
|
||||
# force strict usage of the lock file by setting frozen mode
|
||||
# force strict usage of the lockfile by setting frozen mode
|
||||
bundle "config set --local frozen true"
|
||||
|
||||
# make sure the platform that got actually installed with the old bundler is used
|
||||
|
@ -394,7 +394,7 @@ RSpec.describe "bundle install with install-time dependencies" do
|
||||
end
|
||||
end
|
||||
|
||||
context "with a Gemfile and lock file that don't resolve under the current platform" do
|
||||
context "with a Gemfile and lockfile that don't resolve under the current platform" do
|
||||
before do
|
||||
build_repo4 do
|
||||
build_gem "sorbet", "0.5.10554" do |s|
|
||||
|
@ -24,7 +24,7 @@ RSpec.describe "process lock spec" do
|
||||
context "when creating a lock raises Errno::ENOTSUP" do
|
||||
before { allow(File).to receive(:open).and_raise(Errno::ENOTSUP) }
|
||||
|
||||
it "skips creating the lock file and yields" do
|
||||
it "skips creating the lockfile and yields" do
|
||||
processed = false
|
||||
Bundler::ProcessLock.lock(default_bundle_path) { processed = true }
|
||||
|
||||
@ -35,7 +35,7 @@ RSpec.describe "process lock spec" do
|
||||
context "when creating a lock raises Errno::EPERM" do
|
||||
before { allow(File).to receive(:open).and_raise(Errno::EPERM) }
|
||||
|
||||
it "skips creating the lock file and yields" do
|
||||
it "skips creating the lockfile and yields" do
|
||||
processed = false
|
||||
Bundler::ProcessLock.lock(default_bundle_path) { processed = true }
|
||||
|
||||
@ -46,7 +46,7 @@ RSpec.describe "process lock spec" do
|
||||
context "when creating a lock raises Errno::EROFS" do
|
||||
before { allow(File).to receive(:open).and_raise(Errno::EROFS) }
|
||||
|
||||
it "skips creating the lock file and yields" do
|
||||
it "skips creating the lockfile and yields" do
|
||||
processed = false
|
||||
Bundler::ProcessLock.lock(default_bundle_path) { processed = true }
|
||||
|
||||
|
@ -2030,7 +2030,7 @@ RSpec.describe "the lockfile format" do
|
||||
L
|
||||
|
||||
bundle "install --verbose"
|
||||
expect(out).to include("re-resolving dependencies because your lock file includes \"minitest-bisect\" but not some of its dependencies")
|
||||
expect(out).to include("re-resolving dependencies because your lockfile includes \"minitest-bisect\" but not some of its dependencies")
|
||||
|
||||
expect(lockfile).to eq <<~L
|
||||
GEM
|
||||
|
@ -67,7 +67,7 @@ RSpec.describe "real source plugins" do
|
||||
expect(the_bundle).to include_gems("a-path-gem 1.0")
|
||||
end
|
||||
|
||||
it "writes to lock file" do
|
||||
it "writes to lockfile" do
|
||||
bundle "install"
|
||||
|
||||
checksums = checksums_section_when_enabled do |c|
|
||||
@ -336,7 +336,7 @@ RSpec.describe "real source plugins" do
|
||||
expect(the_bundle).to include_gems("ma-gitp-gem 1.0")
|
||||
end
|
||||
|
||||
it "writes to lock file" do
|
||||
it "writes to lockfile" do
|
||||
revision = revision_for(lib_path("ma-gitp-gem-1.0"))
|
||||
bundle "install"
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user