git config --global user.name "Usuario" # Nombre de usuario
git config --global user.email ejemplo@ejemplo.com # e-mail
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require 'pg' # gem install pg | |
| # Wraps pg library calls | |
| # Version: 1.2 | |
| # Use: | |
| # 1) Methods of the class | |
| # Example: postgres_connection.execute_query(sql_statement) | |
| # | |
| # 2) Use a pg library call with `interact` method and `connection` instance variable | |
| # Example: postgres_connection.interact { postgres_connection.connection.pg_method } |
-
$ rails new MySitethis command created a new Rails app named MySite. It generated a number of files and folders that we will use to build the app. -
$ bundle installThis command installed all the software packages needed by the new Rails app. These software packages are called gems and they are listed in the file Gemfile. -
$ rails servercommand started the Rails development server so that we could preview the app in the browser by visitinghttp://localhost:8000orhttp://localhost:3000. This development server is calledWEBrick.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Gem dependecies | |
| gem install rubocop | |
| gem install scss-lint | |
| gem install coffee-script | |
| npm install -g coffeelint | |
| rbenv rehash | |
| # Atom packages | |
| # General |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash -x | |
| # Script for install Ruby and Rails (rbenv). | |
| # Notes: | |
| # * Do not run with sudo because the rbenv directory will belong to root | |
| # * Change Ruby version and Rails if you wish. | |
| # * After the instalation, close and open again the terminal | |
| # Created: 16/3/16 | |
| # rbenv dependencies | |
| sudo apt-get install git-core curl zlib1g-dev build-essential libssl-dev libreadline-dev libyaml-dev libsqlite3-dev sqlite3 libxml2-dev libxslt1-dev libcurl4-openssl-dev python-software-properties libffi-dev -y |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Links: https://www.digitalocean.com/community/tutorials/initial-server-setup-with-ubuntu-14-04 | |
| # https://www.digitalocean.com/community/tutorials/additional-recommended-steps-for-new-ubuntu-14-04-servers | |
| # Autenticarse como root | |
| ssh root@SERVER_IP_ADDRESS | |
| # Añadir usuario | |
| adduser user | |
| # Agregar el usuario al grupo suders |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # Script that installs some packages for ubuntu-gnome | |
| # Tested in Ubuntu 16.04 | |
| # Arc theme | |
| sudo sh -c "echo 'deb http://download.opensuse.org/repositories/home:/Horst3180/xUbuntu_16.04/ /' >> /etc/apt/sources.list.d/arc-theme.list" | |
| wget http://download.opensuse.org/repositories/home:Horst3180/xUbuntu_16.04/Release.key | |
| sudo apt-key add - < Release.key | |
| rm Release.key | |
| sudo apt-get update |
OlderNewer