From: "tommorris (Tom Morris)" Date: 2013-07-31T01:24:05+09:00 Subject: [ruby-core:56274] [ruby-trunk - Bug #8709][Open] Dir.glob should return sorted file list Issue #8709 has been reported by tommorris (Tom Morris). ---------------------------------------- Bug #8709: Dir.glob should return sorted file list https://bugs.ruby-lang.org/issues/8709 Author: tommorris (Tom Morris) Status: Open Priority: Normal Assignee: Category: Target version: ruby -v: ruby 1.9.3p429 (2013-05-15) [x86_64-linux] Brightbox Backport: 1.9.3: UNKNOWN, 2.0.0: UNKNOWN On OS X, Dir.glob and Dir[] return an ordered list of files. On Ubuntu Linux, they do not and one must manually sort them. Returning a list of files that isn't in order fails the Principle of Least Astonishment. I attach a unit test to demonstrate ideal behaviour. -- http://bugs.ruby-lang.org/