Ruby QuickRef
Table of Contents Language General Tips These are tips I’ve given over and over and over and over… Use 2 space indent, no tabs. See for more. General Syntax Rules Comments start with a pound/sharp (#) character and go to EOL. Reserved Words alias and BEGIN begin break case class def defined? Types Basic types are numbers, strings, ranges, regexen, symbols, arrays, and hashes. Numbers 1231_234123.451.2e-30xffff 0b01011 0377 ? Strings In all of the %() cases below, you may use any matching characters or any single character for delimiters. %[], %!! 'no interpolation'"#{interpolation}, and backslashes\n"%q(no interpolation)%Q(interpolation and backslashes)%(interpolation and backslashes)`echo command interpretation with interpolation and backslashes`%x(echo command interpretation with interpolation and backslashes) Backslashes: Here Docs: Encodings: Waaaay too much to cover here. Symbols Internalized String. Ranges 1..101...10'a'..' Regexen "r"
Relevance
Ajax Scaffold Generator
Most web applications have many more model objects exposed on the backend, or admin side, than they do on the front. Coding interfaces for all those models is redundant and a waste of resources when all you need is CRUD functionality that’s smart enough to handle all your ActiveRecord associations. Enter the ActiveScaffold plugin. The successor to the popular AjaxScaffold project that amassed over 36,000 downloads , ActiveScaffold provides you with a wealth of dynamically created goodness: An AJAXified table interface for creating, updating, and deleting objects Automatic handling of ActiveRecord associations Sorting, Search and Pagination Graceful JavaScript degradation RESTful API support (XML/YAML/JSON) baked in Sexy CSS styling and theming support More extension points than you can shake a stick at Guaranteed to work on Firefox 1+, IE 6 + and Safari 2+ Released under the MIT License, the same one as Rails itself, so you can use it freely in your commercial applications. That’s it!
CodeRay
Vivot Ut Vivas In Aeternum<br/>Live as You Live in Eternity
Ruby and Rails Snippets
JEdit Ruby/Rails Snippets or superabbrevs
Posted by Jim Morris on Fri Nov 24 19:05:52 -0800 2006 I imported the rest of the Textmate ruby and rails snippets I had to combine them into the one ruby file though. I have added about 80 new ones to the existing ones by Scott Becker that I found here The list of snippets I now have is at the end of this post, note I did change the abbreviation for some of the assertions they all now start with as so I can search for them faster with my select_superabbrevs macro described in the previous post. download the new snippets from here unzip and replace the ruby file in the .jedit/SuperAbbrevs directory with the one in this zip archive. You need the Beta version of SuperAbbrevs to use this from here
Snippets Tagged 'Rails'
Change style: advanced code snippet search login / Register Login with Facebook Share Snipplr Tools More tools ... Popular Tags Bash CSS3 DOM Development Shell String Strukture actionscript ajax android apache api array as3 browser c class cocoa convert css custom data database date design drupal email facebook file files find flash form format forms function get google groovy htaccess html html5 ie image images input iphone java javascript jquery js json link linux list loop mac magento menu mobile mysql number object osx page php plugin post python query rails random redirect regex remove replace reset ruby script search select server sql starter svn table template terminal text time twitter unix url validation web wordpress xhtml xml Everyone's Recent Snippets Tagged 'rails' « Prev [Page 1 of 7] Next » Choose a language for easy browsing:
Composite Primary Keys for Ruby on Rails/ActiveRecords
RDT - Ruby Development Tools: Welcome
Related:
Related: