I have a program that reads the data in a file, changes certain elements, and creates a new file. The code looks like this:
lines = IO.readlines('single_before_CAP.txt').map do |line|
a = line.split.each { |i| i.capitalize! }
a2 = a.join(" ")
File.open('single_after_CAP.txt', 'w') do |file|
file.puts lines
end
How can I use Xcode and MacRuby to get this program to run as a GUI app? If not Xcode and MacRuby, is there another simple task I can do to make this a standalone GUI app?
If you just want to run a headless ruby application, you can use Automator. Simply create a new workflow, add a line to execute your application, and save it as a ".app". I can give you more specific instructions if you like.
@jmitchell1009
Specific Instructions: If you don't need to input anything to your program (like files or arguments) the simplest way would be to:
If you have any issues, let me know.