Skip to content

Instantly share code, notes, and snippets.

@nhudinhtuan
nhudinhtuan / cheat_sheet.md
Last active February 17, 2025 16:44
15 days cheat sheet for interviews
@IanColdwater
IanColdwater / twittermute.txt
Last active March 18, 2025 17:59
Here are some terms to mute on Twitter to clean your timeline up a bit.
Mute these words in your settings here: https://twitter.com/settings/muted_keywords
ActivityTweet
generic_activity_highlights
generic_activity_momentsbreaking
RankedOrganicTweet
suggest_activity
suggest_activity_feed
suggest_activity_highlights
suggest_activity_tweet
@bliotti
bliotti / mongodb.md
Created November 18, 2019 05:35 — forked from artieziff/mongodb.md
MongoDb & Python Essentials

##MONGODB & PYTHON

###Ubuntu Install

sudo apt-get install mongodb
pip install pymongo

Table - Collection
Column - Property
Row - Document

@bradtraversy
bradtraversy / vscode_shortcuts.md
Last active March 19, 2025 14:37
Helpful shortcuts for VSCode

VSCode Shortcuts

List of helpful shortcuts for faster coding

If you have any other helpful shortcuts, feel free to add in the comments of this gist :)

Official List of all commands

@basiszwo
basiszwo / google-cloud-memorystore-dump.md
Last active October 14, 2022 21:15
Dump Redis rdb file from Google Cloud MemoryStore

Dumping a redis rdb file from a Google Cloud MemoryStore is easier than expected using redis-cli

Command

redis-cli -h <IP of MemoryStore Instance> --rdb dump.rdb
@kensoh
kensoh / stars
Last active July 17, 2020 09:07
TagUI flow to print the list of your starred repos
// created this flow file to archive my starred repos
// it prints the list of starred repos by github user
// you can get TagUI here (macOS / Windows / Linux)
// https://github.com/kelaberetiv/TagUI#set-up
// usage #1 - copy or download this file, then run
// tagui stars github_userid quiet chrome
// usage #2 - if you want to run this gist directly
@mingrui
mingrui / gist:187f0e629007443268ce8c1414012ed5
Created April 29, 2018 14:42
docker-ce : Depends: libseccomp2 (>= 2.3.0) but 2.2.3-3ubuntu3 is to be installed
When installing latest docker-ec 18, I encountered libseccomp2 version problem
https://www.ubuntuupdates.org/ppa/ubuntu_sdk_release?dist=xenial
add this to update libseccomp2
then install docker-ce
@cecilemuller
cecilemuller / launch.json
Last active January 29, 2025 15:35
Run ts-node in VSCode Debugger
{
"version": "0.2.0",
"configurations": [
{
"name": "Example",
"type": "node",
"request": "launch",
"runtimeExecutable": "node",
"runtimeArgs": ["--nolazy", "-r", "ts-node/register/transpile-only"],
@soulmachine
soulmachine / jwt-expiration.md
Last active January 9, 2025 12:03
How to deal with JWT expiration?

First of all, please note that token expiration and revoking are two different things.

  1. Expiration only happens for web apps, not for native mobile apps, because native apps never expire.
  2. Revoking only happens when (1) uses click the logout button on the website or native Apps;(2) users reset their passwords; (3) users revoke their tokens explicitly in the administration panel.

1. How to hadle JWT expiration

A JWT token that never expires is dangerous if the token is stolen then someone can always access the user's data.

Quoted from JWT RFC:

@subfuzion
subfuzion / README.md
Created November 7, 2017 18:33 — forked from boneskull/README.md
example of how to debug mocha v4 if hanging

Here's an example of how to debug Mocha v4 if it hangs.

Ensure you're using a Node.js 8 or newer (or any version with async_hooks support).

If you run your test, you'll notice it hangs:

$ mocha test.js