# Paths and drive letters?

**URL:** <https://www.ruby-forum.com/t/paths-and-drive-letters/62852>\
**Category:** Ruby\
**Created:** [June 8, 2006, 7:36pm UTC](https://www.ruby-forum.com/t/paths-and-drive-letters/62852 "2006-06-08T19:36:32Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![cbergy](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/71e660/32.png) [@cbergy](https://www.ruby-forum.com/u/cbergy)\
**Post date:** [June 8, 2006, 7:36pm UTC](https://www.ruby-forum.com/t/paths-and-drive-letters/62852/1 "2006-06-08T19:36:32Z")

</div>

Hi,

I’m trying to make a ruby program which will search for and then  
manipulate list of files and the files themselves. I’m confused about  
the Dir class and/or Find module. How do I specify a windows drive  
letter to limit/refine my search to a specific disk drive?

---

<div class="post-metadata">

**Author:** ![cbergy](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/71e660/32.png) [@cbergy](https://www.ruby-forum.com/u/cbergy)\
**Post date:** [June 8, 2006, 8:33pm UTC](https://www.ruby-forum.com/t/paths-and-drive-letters/62852/2 "2006-06-08T20:33:16Z")

</div>

Hey

Dir.chdir(‘c:’) works on my Win2k box

And Find(‘c:’) seems to be OK too

Cheers

---

<div class="post-metadata">

**Author:** ![cbergy](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/71e660/32.png) [@cbergy](https://www.ruby-forum.com/u/cbergy)\
**Post date:** [June 8, 2006, 10:00pm UTC](https://www.ruby-forum.com/t/paths-and-drive-letters/62852/3 "2006-06-08T22:00:43Z")

</div>

Chris,

Doh! Thanks, that seems to do it. 🙂 Maybe it had something to do  
with using freeride. I’ve been playing with it for hours and just  
couldn’t seem to get it right ☹

so I’m a little slow on the uptake…,  
Chuck
