##References
##Create Rails App
command to make new directory:
mkdir AppName
##References
##Create Rails App
command to make new directory:
mkdir AppName
initializer mail.rb
ActionMailer::Base.smtp_settings = {
:address => 'smtp.sendgrid.net',
:port => '587',
:authentication => :plain,
:user_name => ENV['SENDGRID_USERNAME'],
:password => ENV['SENDGRID_PASSWORD'],
:domain => 'heroku.com',
:enable_starttls_auto => true
Using grunt-contrib-stylus with yeoman
Make every compiled .styl
file goes to .tmp
directory as a single .css
file.
Reference that generated .css
file in your index.html
cssmin block, and left your others css as usual.
Add stylus
task into concurrent:server
and build
processes.
Watch changes within .styl
files, and add stylus
task to be executed.
Best way to install is using official docs from osx repo here. Remember to configure meld as difftool in the command line as well.
There are two ways of installing meld on osx, using brew
and .dmg
package (from @yousseb). Since I found https://yousseb.github.io/meld/, I've installed it with .dmg
package, but having macOS Ventura Version 13.4 (22F66)
in place, it's not even starting for me. So I tried brew
installation, and the application is working as expected, including symlink to start it from the terminal.
http://www.cyberciti.biz/faq/osx-installing-the-aws-command-line-interface-using-brew/
# aws section on .zshrc
source /usr/local/share/zsh/site-functions/_aws
# cmd
aws configure
create swap
You could have postgre installed on localhost with password (or without user or password seted after instalation) but if we are developing we really don't need password, so configuring postgre server without password for all your rails project is usefull.
Go to Postgre Download Site
/Gemfile
/** | |
* Setup Module with `highlight` filter | |
*/ | |
var JekyllApp = angular.module('JekyllApp', [], function ($routeProvider, $locationProvider) { | |
$locationProvider.html5Mode(false); | |
}); | |
JekyllApp.filter('highlight', function () { | |
return function (text, filter) { |
require 'date' | |
def is_valid_date? year, month, day | |
return false if year < 2000 || year > 2999 | |
Date::valid_date?(year, month, day) | |
end | |
class Date | |
def is_valid_date_for_millenium? millenium |
# ... after succesful login | |
def set_current_user_cookie( user ) | |
client_side_user_obj = { id: user.id, email: user.email } | |
cookies.signed[:_application_alt_session] = client_side_user_obj.to_json | |
end | |
# ... |