# Strange diff in 2.1 boot.rb -- exist? vs exists?

**URL:** <https://www.ruby-forum.com/t/strange-diff-in-2-1-boot-rb-exist-vs-exists/139702>\
**Category:** Rails\
**Created:** [June 6, 2008, 6:18am UTC](https://www.ruby-forum.com/t/strange-diff-in-2-1-boot-rb-exist-vs-exists/139702 "2008-06-06T06:18:33Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![rubyfreak](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/e9c0ed/32.png) [@rubyfreak](https://www.ruby-forum.com/u/rubyfreak)\
**Post date:** [June 6, 2008, 6:18am UTC](https://www.ruby-forum.com/t/strange-diff-in-2-1-boot-rb-exist-vs-exists/139702/1 "2008-06-06T06:18:33Z")

</div>

I have a project that built in 2.0.2. I want to update to 2.1 so I  
built a 2.1 empty project and ran meld against the two files to diff  
and merge them. (by the way, I just fell in love with meld, finally a  
merge tool that works in my left brained head)

anyway the 2.1 file has a line that says the following.

load(preinitializer\_path) if File.exist?(preinitializer\_path)

the 2.0.2 file is identical except is uses File.exists? with an “s” on  
the end of exist

load(preinitializer\_path) if File.exists?(preinitializer\_path)

As Cecil the sea sick, sea serpent would say “What the heck?”

---

<div class="post-metadata">

**Author:** ![rubyfreak](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/e9c0ed/32.png) [@rubyfreak](https://www.ruby-forum.com/u/rubyfreak)\
**Post date:** [June 6, 2008, 8:51am UTC](https://www.ruby-forum.com/t/strange-diff-in-2-1-boot-rb-exist-vs-exists/139702/2 "2008-06-06T08:51:55Z")

</div>

On Jun 6, 5:17 am, Ruby F. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> anyway the 2.1 file has a line that says the following.
> 
> load(preinitializer\_path) if File.exist?(preinitializer\_path)
> 
> the 2.0.2 file is identical except is uses File.exists? with an “s” on  
> the end of exist
> 
> load(preinitializer\_path) if File.exists?(preinitializer\_path)
> 
> As Cecil the sea sick, sea serpent would say “What the heck?”

File.exist? and File.exists? are identical in 1.8. File.exists? is  
deprecated in 1.9

Fred
