Skip to content

Instantly share code, notes, and snippets.

@defbyte
Created March 3, 2016 20:51
Show Gist options
  • Save defbyte/fed0a0707170d24e8136 to your computer and use it in GitHub Desktop.
Save defbyte/fed0a0707170d24e8136 to your computer and use it in GitHub Desktop.
Atom Rails Model snippet
'.source.ruby':
'Rails Model Scaffold':
'prefix': 'rmodel'
'body': """
class $1 < ActiveRecord::Base
# ---------------------------------------------------------------------------
# Scopes
# ---------------------------------------------------------------------------
# ---------------------------------------------------------------------------
# Search
# ---------------------------------------------------------------------------
# ---------------------------------------------------------------------------
# Callbacks
# ---------------------------------------------------------------------------
# ---------------------------------------------------------------------------
# Associations
# ---------------------------------------------------------------------------
# ---------------------------------------------------------------------------
# Validations
# ---------------------------------------------------------------------------
# ---------------------------------------------------------------------------
# Instance Methods
# ---------------------------------------------------------------------------
# ---------------------------------------------------------------------------
# Tolaria Invocation
# ---------------------------------------------------------------------------
manage_with_tolaria using: {
icon: "$2",
category: "$3",
priority: $4,
permit_params: [
$5
]
}
# ---------------------------------------------------------------------------
# Private Methods
# ---------------------------------------------------------------------------
end
"""
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment