Skip to content

Instantly share code, notes, and snippets.

View dechowdev's full-sized avatar
🚴‍♂️
Office working!

Lucas Dechow dechowdev

🚴‍♂️
Office working!
View GitHub Profile
@jed
jed / LICENSE.txt
Created May 20, 2011 13:27 — forked from 140bytes/LICENSE.txt
generate random UUIDs
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 Jed Schmidt <http://jed.is>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@MohamedAlaa
MohamedAlaa / tmux-cheatsheet.markdown
Last active July 4, 2024 17:58
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@cowboy
cowboy / bocoup-training-more-efficient-event-handlers.js
Created February 12, 2013 21:38
Bocoup training: More Efficient jQuery Event Handlers
// Straightforward + simple.
$("button").on("click", function(event) {
event.preventDefault();
var button = $(this);
var numberElem = button.find(".number");
var number = Number(numberElem.text()) - 1;
numberElem.text(number);
if (number === 0) {
button.prop("disabled", true);
button.off("click");
if ( !class_exists('JMO_Custom_Nav')) {
class JMO_Custom_Nav {
public function add_nav_menu_meta_boxes() {
add_meta_box(
'wl_login_nav_link',
__('WishList Login'),
array( $this, 'nav_menu_link'),
'nav-menus',
'side',
'low'
@simenbrekken
simenbrekken / global-browserify.js
Created May 20, 2014 10:54
Global browserify require
var path = require('path')
var browserify = require('browserify')
var glob = require('glob')
var bundler = browserify({
entries: ['./src/Application'],
extensions: ['.jsx'],
paths: glob.sync('src/**/').map(function(directory) {
return path.join(__dirname, directory)
})
@JamesMGreene
JamesMGreene / gitflow-breakdown.md
Last active July 3, 2024 20:30
`git flow` vs. `git`: A comparison of using `git flow` commands versus raw `git` commands.

Initialize

gitflow git
git flow init git init
  git commit --allow-empty -m "Initial commit"
  git checkout -b develop master

Connect to the remote repository

@ppalludan
ppalludan / Singleton-run-once
Last active August 29, 2015 14:15
Implemention of a "run once" function, so that I can invoke a given method like crazy, and the method is only invoked once
var Singleton = {
_threads : [],
process: function (name, callback) {
var evt = this._threads[name];
if (evt == null) {
evt = this._threads[name] = { name : name };
}
if (evt.running) {
evt.que = true;
return;
@geraldfullam
geraldfullam / A-jQuery-plugin-deepest().markdown
Last active September 24, 2019 14:21
jQuery plugin: .deepest()

jQuery plugin: .deepest()

Get the deepest descendants matching an optional selector of each element in the set of matched elements.

A Pen by Gerald on CodePen.

License.

Installation

@tejacques
tejacques / HOCBaseRender.tsx
Last active May 2, 2022 13:05
React Higher Order Components in TypeScript
import * as React from 'react';
import { Component } from 'react';
export default function HOCBaseRender<Props, State, ComponentState>(
Comp: new() => Component<Props & State, ComponentState>) {
return class HOCBase extends Component<Props, State> {
render() {
return <Comp {...this.props} {...this.state}/>;
}
}
using UnityEngine;
using System.Collections;
using System.Collections.Generic;
using UnityEditor;
public static class PivotUtilities
{
[MenuItem("GameObject/Pivot/Create Pivot", false, 0)]
static void CreatePivotObject()
{