Forums
New posts
Search forums
Members
Current visitors
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Menu
Log in
Register
Install the app
Install
Forums
Archive
Archive
Ruby
Pasting strings into irb
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
[QUOTE="Ben, post: 4461246"] I would like to use ruby to do interesting manipulations of strings. Ideally, I'd be able to copy multiple lines of text from a text editor, paste those lines of text into irb (as a string), manipulate that string, copy the result, and then paste it back into the original editor. I know that sounds like a lot of work, but the manipulations I want to do aren't trivial enough to do with the standard find/replace features of most editors. For instance, (this is kind of contrived) but say I wanted to take any answers to this post, and make the first and last letter of each word uppercase or something and then save that text in an email. Is there a way to paste multiple lines of text into irb and save them as a single string value? I tried using 'here documents' but that didn't work. By the way, I'm using FXirb since I'm runnign windows and cmd.exe isn't great about copying/pasting in general. Thanks. Ben [/QUOTE]
Verification
Post reply
Forums
Archive
Archive
Ruby
Pasting strings into irb
Top