File.open(file, 'a+') won't work when the file is not readable.

However, in a shell I can append a string using
  echo string >> file

Am I forced to use exec + echo to append content, or is there a way to
append a string to a file using ruby code.. without opening the file?