Skip to content

Instantly share code, notes, and snippets.

View grafkendo's full-sized avatar
💭
I may be slow to respond.

Graf grafkendo

💭
I may be slow to respond.
View GitHub Profile
@grafkendo
grafkendo / git.migrate
Created January 31, 2020 04:29 — forked from niksumeiko/git.migrate
Moving git repository and all its branches, tags to a new remote repository keeping commits history
#!/bin/bash
# Sometimes you need to move your existing git repository
# to a new remote repository (/new remote origin).
# Here are a simple and quick steps that does exactly this.
#
# Let's assume we call "old repo" the repository you wish
# to move, and "new repo" the one you wish to move to.
#
### Step 1. Make sure you have a local copy of all "old repo"
### branches and tags.
// composer.json
{ "name" : "project",
"description": "projecto",
"autoload": {
"classmap": [
"src/"
]
},
"require": {
@grafkendo
grafkendo / test.md
Last active September 10, 2017 19:34
test mak down

Hello world

This is markdown

testing...

  • one
  • two
  • three

Keybase proof

I hereby claim:

  • I am grafkendo on github.
  • I am csmitch (https://keybase.io/csmitch) on keybase.
  • I have a public key ASDLiwevh7piLru376x-WY65xa4JgM6WxIgYoVJmUh2twgo

To claim this, I am signing this object:

@grafkendo
grafkendo / gist:8923d35fea9c544672d9594e8e27ee2b
Last active June 12, 2017 22:49
differential copy of two arrays
// returns values uniqe to each array
function diffArray(arr1, arr2) {
var newArr = [];
// Same, same; but different.
// itterate through arry for each element check if value exists in second array if so push to new array
var newArr1 = arr1.filter(function(value) {
// indexOf returns -1 if the value is not found
if (arr2.indexOf(value) == -1) {
newArr.push(value);
@grafkendo
grafkendo / 0_reuse_code.js
Last active September 10, 2015 19:53
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console