Skip to content

Instantly share code, notes, and snippets.

@jw-miaem
jw-miaem / docker-cheatsheet.sh
Created January 22, 2020 17:04 — forked from bigslycat/docker-cheatsheet.sh
Docker commands cheatsheet
# Stop all running containers
docker stop $(docker ps -q | paste -sd " " -)
# Stop and remove all containers
docker rm -f $(docker ps -aq | paste -sd " " -)
# Stop and remove all images
docker rmi -f $(docker images -aq | paste -sd " " -)
@jw-miaem
jw-miaem / nord_modular_osx.md
Created October 18, 2018 19:45 — forked from arirusso/nord_modular_osx.md
Use the original Nord Modular Editor with OSX

Use the original Nord Modular Editor with OSX

Required

  • Homebrew

Compatibility

Confirmed working with

Handlebars is a semantic web template system, started by Yehuda Katz in 2010.
Handlebars.js is a superset of Mustache, and can render Mustache templates in addition to Handlebars templates.
More: http://handlebarsjs.com/
1. Expressions.
1.1 Basic usage.
@jw-miaem
jw-miaem / bootstrap-4-sass-mixins-cheat-sheet.scss
Created July 29, 2018 10:29 — forked from anschaef/bootstrap-4-sass-mixins-cheat-sheet.scss
Bootstrap 4 Sass Mixins [Cheat sheet with examples]
/* -------------------------------------------------------------------------- */
// All Bootstrap 4 Sass Mixins [Cheat sheet]
// Updated to Bootstrap v4.1.x
// @author https://anschaef.de
// @see https://github.com/twbs/bootstrap/tree/v4-dev/scss/mixins
/* -------------------------------------------------------------------------- */
// Grid variables
$grid-columns: 12 !default;
$grid-gutter-width: 30px !default;
@jw-miaem
jw-miaem / readme.md
Created July 29, 2018 10:28 — forked from benstr/readme.md
Gist Markdown Cheatsheet

#Heading 1 ##Heading 2 ###Heading 3 ####Heading 4 #####Heading 5 ######Heading 6


Paragraph

@jw-miaem
jw-miaem / README.md
Created February 16, 2018 17:26 — forked from joyrexus/README.md
Vanilla JS equivalents of jQuery methods

Sans jQuery

Events

// jQuery
$(document).ready(function() {
  // code
})
@jw-miaem
jw-miaem / CDPATH.md
Created October 17, 2017 08:09 — forked from flackend/CDPATH.md
Instructions for setting up CDPATH completions on Mac.

CDPATH

Overview

This will allow you to include additional directories to what cd will look at for completions. From the bash man page:

The search path for the cd command. This is a colon-separated list of directories in which the shell looks for destination directories specified by the cd command.

Usage

@jw-miaem
jw-miaem / Shazam all songs to youtube and spotify.js
Created July 29, 2017 10:53 — forked from seungjulee/Shazam all songs to youtube and spotify.js
Shazam Crawler and Youtube Searcher in the console
// change this variable to change timeout for async scroll load
var TIMEOUT_IN_MS = 1000
// script from https://gist.github.com/xavhan/87717da0217b9b8299df
// start from www.shazam.com/myshazam
// print all shazam songs loaded on the page
// TODO: Change format to JSON
function printShazamSongs(){
$(".ti__details").each(function(i){
var artist = $(this).find(".ti__artist meta").attr("content");
@jw-miaem
jw-miaem / Shazam to youtube and spotify.js
Created July 29, 2017 10:52 — forked from xavhan/Shazam to youtube and spotify.js
Shazam Crawler and Youtube Searcher in the console
var data = [];
$(".ti__details").each(function(i){
var artist = $(this).find(".ti__artist meta").attr("content");
var title = $(this).find(".ti__title").attr("content");
var format = artist + " - " + title;
var yt = 'http://www.youtube.com/results?search_type=&search_query=' + encodeURI(artist + " " + title) + '&aq=f&oq=';
var spoti = 'https://play.spotify.com/search/'+ encodeURI(artist + " " + title);
var item = new Object;
console.groupCollapsed(format);
console.log(yt);
on searchReplace(theText, SearchString, ReplaceString)
set OldDelims to AppleScript's text item delimiters
set AppleScript's text item delimiters to SearchString
set newText to text items of theText
set AppleScript's text item delimiters to ReplaceString
set newText to newText as text
set AppleScript's text item delimiters to OldDelims
return newText
end searchReplace