Skip to content

Instantly share code, notes, and snippets.

View osedoe's full-sized avatar
🇮🇨

Ose Diaz-Gonzalez osedoe

🇮🇨
View GitHub Profile
@osedoe
osedoe / mongo.md
Last active November 27, 2018 17:17
Docker mongo

MongoDB

-Lift a docker with mongo

docker run  -d
            -p 27017:27017
            -v ~/Desktop/mongo-data:/data/db
            mongo
@osedoe
osedoe / gist:2a2e899a0997a9c4b46429ca3f1690f0
Created December 4, 2018 19:57
Kill a wildfly process
pgrep -d" " -f "wildfly" | xargs kill -9;
@osedoe
osedoe / README-Template.md
Created December 20, 2018 10:34 — forked from PurpleBooth/README-Template.md
A template to make good README.md

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

@osedoe
osedoe / git-commands.md
Last active August 8, 2019 08:05
Git Handy Commands

Git handy commands

  • Fix/rename last commit: git commit —ammend
  • Rename current branch: git branch -m <newName>
  • Watch for branches to remove: git branch | grep <partOfBranchesName>
  • CAUTION Remove all branches that have the passed argument: git branch | grep <partOfBranchesName> | xargs git branch -d
  • Revert commits (faulty ones). Use with caution, if you're not sure, go for git reset
git log
git revert 
@osedoe
osedoe / utils.ts
Last active November 14, 2019 15:32
Useful typescript functions
const getRandomObjectProperty = (object: object) => Object.keys(object)[Math.floor(Math.random() * Object.keys(object).length)];
const generateRandomHexColor = () => '#'+Math.floor(Math.random()*16777215).toString(16);