Skip to content

Instantly share code, notes, and snippets.

Avatar
🌋

surfer190 surfer190

🌋
  • Johannesburg
View GitHub Profile
@surfer190
surfer190 / check_available_sapce_macbook_cli.md
Created Sep 12, 2019
Check available disk space quickly with Mac CLI
View check_available_sapce_macbook_cli.md

How to check available disk space quickly with Mac CLI

diskutil info / | grep "Available Space"
View pilot.js
$( document ).ready(function() {
var typedPassword = "";
var typedPasswordOverlay = "";
var pastedPassword = false;
var ctrlPressed = false;
$.ajax({
type: 'GET',
url: '../web-plt/Exhursfl',
dataType: 'json',
success: function (data) {
@surfer190
surfer190 / api-wrapper-concerns.md
Last active Jul 24, 2019
API wrapper Concerns
View api-wrapper-concerns.md
  • It must make using the API easier...it shouldn't be an abstraction for abstraction sake

  • when you get a session token - can you store it for future sessions? - what mechanism is used to retrieve a new one if the old one fails within the request/response cycle.

  • automatically close session tokens

  • should you hide error codes - or just raise them from the original api? - for example authentication fails on the client api login - I should raise an exception but what kind?

  • Should you catch API access codes and raise your own errors

View donations.md

People to donate to

2019

  • buy presidents keepers and gangster state
  • dailymaverick
  • eff (Done $100)
  • adblock (Done $100)
  • python foundation
  • django foundation
View books.md
View quotes.md

If you are born poor, that is not a mistake. If you don't die poor, that probably is. - me

Whenever you atr asked whether you can do a job answer: "Certainly I can!" Then get busy and find out how to do it - Teddy Roosevelt

A ship in a harbour is safe. But that is not what ships are built for - William Shedd

"External things are not the problem. It's your assessment of them. Which you can erase right now." Marcus Aurelius

@surfer190
surfer190 / magento_2_make_all_categories_anchor.md
Last active Mar 29, 2017
Make all magento 2 categories an anchor category
View magento_2_make_all_categories_anchor.md
UPDATE catalog_category_entity_int SET value = 1'
WHERE (entity_id = 2) AND (attribute_id = '51') AND (store_id = '0')
@surfer190
surfer190 / top-100-movies.md
Last active Dec 1, 2017
Top 100 Movies of all time by Surfer190
View top-100-movies.md
  1. Die Hard 1
  2. True Grit (2011)
  3. The Matrix (1999)
  4. Crank (2006)
  5. The Good the bad and the ugly (1966)
  6. Fight Club
  7. Escape from alcatrax (1979)
  8. V for Vendetta (2005)
  9. Equilibrium
  10. Crank: High Voltage (2009)