Skip to content

Instantly share code, notes, and snippets.

View carlos-ssh's full-sized avatar
🎯
Focusing

Carlos Flores carlos-ssh

🎯
Focusing
View GitHub Profile
@hernamesbarbara
hernamesbarbara / seeds.rb
Created February 19, 2012 17:10
Create Admin User in Ruby on Rails Application using rake db:seed
#db/seeds.rb
# Run 'rake db:seed' from terminal to create an Admin User in your database
#Seed DB with at least 1 Admin User
admin=User.new({ name: "Admin User", email: '[email protected]',
password: 'password', password_confirmation: 'password'})
admin.toggle!(:admin)
@janily
janily / Breakpoints
Created January 16, 2014 11:36
Mobile-first CSS Media Queries Breakpoints
@media (min-width:320px) { /* smartphones, portrait iPhone, portrait 480x320 phones (Android) */ }
@media (min-width:480px) { /* smartphones, Android phones, landscape iPhone */ }
@media (min-width:600px) { /* portrait tablets, portrait iPad, e-readers (Nook/Kindle), landscape 800x480 phones (Android) */ }
@media (min-width:801px) { /* tablet, landscape iPad, lo-res laptops ands desktops */ }
@media (min-width:1025px) { /* big landscape tablets, laptops, and desktops */ }
@media (min-width:1281px) { /* hi-res laptops and desktops */ }
@mdang
mdang / RAILS_CHEATSHEET.md
Last active March 31, 2025 22:13
Ruby on Rails Cheatsheet

Ruby on Rails Cheatsheet

Architecture

Create a new application

Install the Rails gem if you haven't done so before

@PavloBezpalov
PavloBezpalov / 1 Gist conventions
Last active January 7, 2024 11:55
Deploy Rails 5.0.0.beta3 to VPS(Ubuntu 14.04.4 LTS). Nginx, Puma, Capistrano3, PostgreSQL, RVM.
<<APP>> change this variables
@cgonzalezdai
cgonzalezdai / como-subir-un-proyecto-local-a-github.md
Last active April 14, 2025 20:40
Como subir un proyecto local a github

Como subir un proyecto local a github.

desde la web de github

Creamos un nuevo repositorio en https://github.com. Le damos nombre, descripción, seleccionamos si va a ser un proyecto publico o privado si es el caso, y dejamos el check de crear README sin marcar. Le damos a crear repositorio y con esto ya tenemos el repositorio donde alojaremos nuestro proyecto.

desde la terminal del equipo donde esta el proyecto que queremos subir a github

Nos vamos a la carpeta del proyecto y ejecutamos estos comandos.

git init

git add .
@stevecondylios
stevecondylios / contact-form.md
Last active December 23, 2022 07:33
Tutorial: Create and Deploy a Contact Form to Production in Ruby on Rails 5

Create a Contact Form in Rails 5



2021 UPDATE: some parts of this tutorial are now out of date, please use Create a Contact Form in Rails 6 instead. The rails 5 / gmail version remains below for posterity.






This is a complete, step-by-step tutorial showing how to create a fully functional contact form in production in rails 5. Rather than reinvent things, the following borrows from the best available documentation and tutorials (most notably, this tutorial on making a contact form in development). The finished contact form can be viewed here.

@bradtraversy
bradtraversy / tailwind-webpack-setup.md
Last active April 14, 2025 19:43
Setup Webpack with Tailwind CSS

Webpack & Tailwind CSS Setup

Create your package.json

npm init -y

Create your src folder

Create a folder called src and add an empty index.js file. The code that webpack compiles goes in here including any Javascript modules and the main Tailwind file.

@carlos-ssh
carlos-ssh / 1 Gist conventions
Created March 31, 2023 16:24 — forked from PavloBezpalov/1 Gist conventions
Deploy Rails 5.0.0.beta3 to VPS(Ubuntu 14.04.4 LTS). Nginx, Puma, Capistrano3, PostgreSQL, RVM.
<<APP>> change this variables