Skip to content

Instantly share code, notes, and snippets.

@jimbojsb
jimbojsb / gist:1630790
Created January 18, 2012 03:52
Code highlighting for Keynote presentations

Step 0:

Get Homebrew installed on your mac if you don't already have it

Step 1:

Install highlight. "brew install highlight". (This brings down Lua and Boost as well)

Step 2:

@conorbranagan
conorbranagan / gist:4513828
Last active May 8, 2024 12:20
Linux System Metrics

Linux System Metrics

CPU

  • system.cpu.idle: % Idle CPU
  • system.cpu.system: % System CPU
  • system.cpu.user: % User CPU

Disk

@hackinf0
hackinf0 / Connecting Multiple Database in NodeJs with MongoDB and Mongoose
Last active May 8, 2024 12:19
Connecting Multiple Database in NodeJs with MongoDB and Mongoose
Explanation file: db.js
This code imports the mongoose library which allows to connect to a MongoDB database.
There are two URIs defined to connect to two different databases: MONGO_URI and MOBILE_URI.
Each URI contains connection information to a remote MongoDB database, including user credentials.
The connectDBs function uses the mongoose.createConnection method to create connections to these two
databases using the respective URIs. The useUnifiedTopology and useNewUrlParser options are set to enable the new
unified topology policy and use MongoDB's new URL parser, respectively.
The function returns an object that contains the connections to these two databases as qrCodeDb and userDB properties.
@adamawolf
adamawolf / Apple_mobile_device_types.txt
Last active May 8, 2024 12:18
List of Apple's mobile device codes types a.k.a. machine ids (e.g. `iPhone1,1`, `Watch1,1`, etc.) and their matching product names
i386 : iPhone Simulator
x86_64 : iPhone Simulator
arm64 : iPhone Simulator
iPhone1,1 : iPhone
iPhone1,2 : iPhone 3G
iPhone2,1 : iPhone 3GS
iPhone3,1 : iPhone 4
iPhone3,2 : iPhone 4 GSM Rev A
iPhone3,3 : iPhone 4 CDMA
iPhone4,1 : iPhone 4S
@athiyadeviyani
athiyadeviyani / tkinterlist.py
Created July 19, 2018 08:27
Python GUI cheatsheet
# BASIC TKINTER CHEATSHEET
# Build basic GUIs with Python
from tkinter import *
from tkinter import scrolledtext
from tkinter import messagebox
from tkinter.ttk import Progressbar
from tkinter import filedialog
from tkinter import Menu
@jeez
jeez / Scheduled Tx Tools
Last active May 8, 2024 12:15
[TSN] Scheduled Tx Tools - Examples and Helpers for testing SO_TXTIME, and the etf and taprio qdiscs
We couldn’t find that file to show.
--paletteColor1 -----> --theme-palette-color-1
--paletteColor2 -----> --theme-palette-color-2
--paletteColor3 -----> --theme-palette-color-3
--paletteColor4 -----> --theme-palette-color-4
--paletteColor5 -----> --theme-palette-color-5
--paletteColor6 -----> --theme-palette-color-6
--paletteColor7 -----> --theme-palette-color-7
--paletteColor8 -----> --theme-palette-color-8
--fontFamily -----> --theme-font-family
@gabe565
gabe565 / change-arc-icon.md
Last active May 8, 2024 12:09
Change Arc Browser Icon

Change Arc Browser Icon

arc

A collection of commands that change the Arc Browser icon.

Commands

Theme Command
Candy Arc defaults write company.thebrowser.Browser currentAppIconName candy

Risk Parity & Budgeting

With Python

Dr. Yves J. Hilpisch | The Python Quants & The AI Machine

Python for Quant Finance Meetup, London, 16. November 2022

(short link to this Gist: http://bit.ly/pqf_risk)