Skip to content

Instantly share code, notes, and snippets.

DaniSancas /
Created Jun 14, 2016
Neo4j's Cypher queries cheatsheet

Neo4j Tutorial


Store any kind of data using the following graph concepts:

  • Node: Graph data records
  • Relationship: Connect nodes (has direction and a type)
  • Property: Stores data in key-value pair in nodes and relationships
  • Label: Groups nodes and relationships (optional)
subfuzion /
Last active Dec 6, 2022
curl POST examples

Common Options

-#, --progress-bar Make curl display a simple progress bar instead of the more informational standard meter.

-b, --cookie <name=data> Supply cookie with request. If no =, then specifies the cookie file to use (see -c).

-c, --cookie-jar <file name> File to save response cookies to.

jbenet /
Last active Dec 3, 2022
a simple git branching model

a simple git branching model (written in 2013)

This is a very simple git workflow. It (and variants) is in use by many people. I settled on it after using it very effectively at Athena. GitHub does something similar; Zach Holman mentioned it in this talk.

Update: Woah, thanks for all the attention. Didn't expect this simple rant to get popular.

DanHerbert /
Last active Oct 19, 2022
Instructions on how to fix npm if you've installed Node through Homebrew on Mac OS X or Linuxbrew

READ THIS Very Important Update

This entire guide is based on an old version of Homebrew/Node and no longer applies. It was only ever intended to fix a specific error message which has since been fixed. I've kept it here for historical purposes, but it should no longer be used. Homebrew maintainers have fixed things and the options mentioned don't exist and won't work.

I still believe it is better to manually install npm separately since having a generic package manager maintain another package manager is a bad idea, but the instructions below don't explain how to do that.

Fixing npm On Mac OS X for Homebrew Users

Installing node through Homebrew can cause problems with npm for globally installed packages. To fix it quickly, use the solution below. An explanation is also included at the end of this document.

karimnaaji / GoogleFonts.txt
Created Jan 9, 2017
Google fonts list (TTF)
View GoogleFonts.txt
"kind": "webfonts#webfontList",
"items": [
"kind": "webfonts#webfont",
"family": "ABeeZee",
"category": "sans-serif",
"variants": [
megasmack /
Last active May 24, 2022
LWC Focus-Trapping Modal

LWC Focus-Trapping Modal

Using SLDS classes, build a modal Lightning Web Component that has focus-trapping for accessiblity.

Notes: The shadowdom presents some challenges with creating focus-trapping within modals. Making creating a reusable component tricky. So instead we can create a modal utility file with all our methods to keep things as DRY as possible.

krusynth /
Last active Jun 15, 2021
A list of useful books to improve your skills

Recommended Books

A list of useful books to improve your skills

Recommendations from others are noted in (parentheses). The rest are my personal recommendations.


Building your core

  • The Pragmatic Programmer - Hunt & Thomas
wpscholar / functions.php
Last active Mar 1, 2021
Enqueueing IE conditional stylesheets in WordPress the right way
View functions.php
add_action( 'wp_enqueue_scripts', 'enqueue_my_styles' );
* Example callback function that demonstrates how to properly enqueue conditional stylesheets in WordPress for IE.
* IE10 and up does not support conditional comments in standards mode.
* @uses wp_style_add_data() WordPress function to add the conditional data.
* @link
esthezia / php-sanitize-multidimensional-array.php
Created Jun 18, 2013
PHP - Sanitize a multidimensional array
View php-sanitize-multidimensional-array.php
* Sanitize a multidimensional array
* @uses htmlspecialchars
* @param (array)
* @return (array) the sanitized array
View Lab: Git

Now that you have Git on your system, you’ll want to do a few things to customize your Git environment. You should have to do these things only once on any given computer; they’ll stick around between upgrades. You can also change them at any time by running through the commands again.

Git comes with a tool called git config that lets you get and set configuration variables that control all aspects of how Git looks and operates.

Let's take a look at some common configurations that you might want to do:


git config --global "John Doe"