Skip to content

Instantly share code, notes, and snippets.

@explorador
explorador / spotifycache.zshrc
Last active May 3, 2020 00:01
Deletes Spotify Cache on MacOS
# Deletes Spotify Cache
# (Run this when app starts running slow)
spotifycache() {
# (zshell only) Do not query the user before executing ‘rm *’ or ‘rm path/*’.
setopt localoptions rmstarsilent
# Clear cache files
\rm -fr ~/Library/Caches/com.spotify.client/Browser/*
\rm -fr ~/Library/Caches/com.spotify.client/Data/*
\rm -fr ~/Library/Caches/com.spotify.client/fsCachedData/*
# -------------------------------------------------
# Protect your .git directory!
# (You don't want anyone to download a copy of your website)
# -------------------------------------------------
# Add to .htaccess
# For Apache 2.4
<DirectoryMatch "^/.*/\.git/">
/**
* Replace Layer Name
*
* Paste here:
* /Applications/Adobe Photoshop Version/Presets/Scripts/Replace Layer Name.jsx
*/
var docRef = app.activeDocument;
cTID = function(s) { return app.charIDToTypeID(s); };
include ShopifyAPI
# Reference: https://help.shopify.com/api/reference
objects = [ 'Blog', 'Article', 'Page', 'SmartCollection', 'Product', 'CustomCollection' ]
# Create directory if it doesn't exists
directory_name = "data"
Dir.mkdir(directory_name) unless File.exists?(directory_name)
# puts(variable); # Log
@explorador
explorador / 0_reuse_code.js
Created June 11, 2014 14:40
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