Skip to content

Instantly share code, notes, and snippets.

View mrpandat's full-sized avatar
🍜
NomNomNom

KagXaef mrpandat

🍜
NomNomNom
View GitHub Profile
[alias]
co = checkout
br = branch
cm = commit -m
st = status
rsh = reset --soft HEAD^1
rhh = reset --hard HEAD
pushf = push --force-with-lease
lg = log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit
rcm = "!f() { \
@maximevalette
maximevalette / OVH_Keystone_v3.md
Last active June 28, 2022 11:56
Sample PHP script to use Keystone v3 with OVH credentials (username + password)

OVH + PHP + Keystone v3

Install PHP OpenCloud

composer require php-opencloud/openstack ^3.0

Sample token authentication with OVH credentials

<?php
@naesheim
naesheim / buildWhenAffected.sh
Last active November 28, 2022 20:20
CircleCi - only build features that has changed
##################
### config.yml ###
##################
version: 2
jobs:
build:
docker:
- image: circleci/python:3.6
steps:
@pokisin
pokisin / Uninstall.md
Last active June 8, 2024 07:53
Uninstall git, ubuntu

Uninstall git

To remove just git package itself from Ubuntu 14.04 execute on terminal:

$ sudo apt-get remove git

Uninstall git and it's dependent packages

To remove the git package and any other dependant package which are no longer needed from Ubuntu Trusty.

$ sudo apt-get remove --auto-remove git
@mihow
mihow / load_dotenv.sh
Last active June 14, 2024 02:15
Load environment variables from dotenv / .env file in Bash
if [ ! -f .env ]
then
export $(cat .env | xargs)
fi
@mdang
mdang / ES6_PRACTICE.md
Last active February 12, 2021 18:23
ES6 Practice

ES6 Practice

Convert the following ES5 code to ES6.

Template Literals

// Template literals
var li = '<li>' +
  '<div class="row">' +
@ravibhure
ravibhure / git_rebase.md
Last active June 4, 2024 15:02
Git rebase from remote fork repo

In your local clone of your forked repository, you can add the original GitHub repository as a "remote". ("Remotes" are like nicknames for the URLs of repositories - origin is one, for example.) Then you can fetch all the branches from that upstream repository, and rebase your work to continue working on the upstream version. In terms of commands that might look like:

Add the remote, call it "upstream":

git remote add upstream https://github.com/whoever/whatever.git

Fetch all the branches of that remote into remote-tracking branches, such as upstream/master:

git fetch upstream

@DianaEromosele
DianaEromosele / Change "origin" of your GIT repository
Created August 7, 2016 00:31
Change "origin" of your GIT repository
$ git remote rm origin
$ git remote add origin git@github.com:aplikacjainfo/proj1.git
$ git config master.remote origin
$ git config master.merge refs/heads/master
@cbednarski
cbednarski / factorio.md
Last active April 3, 2024 01:14
Host a factorio server
@BaptisteDixneuf
BaptisteDixneuf / OVH_Public_Cloud_Storage_API_OpenStack_Swift.md
Created June 25, 2015 21:23
OVH Public Cloud Object Storage et API OpenStack Swift