You can use end_of_week (AFAIK is only available in Rails)
>> Date.new(2009, 11, 19).end_of_week - 2 => Fri, 20 Nov 2009
But that may not work, depending on what exactly you want. Another way -
>> d = Date.new(2009, 11, 19) >> (d..(d+7)).find{|d| d.cwday == 5} => Fri, 20 Nov 2009
suggests that you want to have the following Friday, if d is already on Friday:
>> d = Date.new(2009, 11, 20)
source share