Skip to content

Instantly share code, notes, and snippets.

View rafaelune's full-sized avatar

Rafael Kiyohiro Une rafaelune

  • São José dos Campos, Brazil
View GitHub Profile
@rafaelune
rafaelune / Docker-Cheat-Sheet.md
Last active December 17, 2019 19:05
Docker cheat sheet

Images

Lists images

$ docker images

Removes an image

$ docker rmi <image-id>
@rafaelune
rafaelune / unix_cmds.txt
Last active December 10, 2019 18:58
unix cmds
# searches files inside jars
find foo/ -name "*.jar" | xargs grep Hello.class
locate "*.jar" | xargs grep Hello.class
# displays memory usage
free -m
# change permissions
chmod u=rwx,g=rx,o=r myfile

Code First Migrations - Entity Framework

Package Manager Console

Enable migrations for your context.

  PM> Enable-Migrations

Creates scaffold for the next migration based on changes you have made to your model since the last migration was created.

NuGet Basic Commands

Package Manager Console

List all available packages of a source.

  PM> Get-Package -ListAvailable

Find the "jquery" on the list of available packages of a source.

RVM Basic Commands

Installing ruby

  $ rvm install 1.9.2
  $ rvm use 1.9.2
  $ ruby -v

To list all installed versions of ruby

@rafaelune
rafaelune / gist:3804162
Last active September 17, 2021 19:05
Git Cheat Sheet

Git Cheat Sheet

Initialize local git repository

  $ git init

Clone remote server git repository

@rafaelune
rafaelune / gist:3109819
Last active October 7, 2015 04:58
Creating .gitignore file through command line on Windows
#1 option
@echo off
(
echo *.log
echo local_settings.config
echo dir_name
) > .gitignore
#2 option