Skip to content

Instantly share code, notes, and snippets.

@hrishipoola
hrishipoola / peloton-s-implied-volatility-delta-hedge.ipynb
Created February 22, 2021 15:42
Peloton's Implied Volatility & Delta Hedge.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@LeviSnoot
LeviSnoot / discord-timestamps.md
Last active May 4, 2024 22:45
Discord Timestamp Syntax

Discord Timestamps

Discord timestamps can be useful for specifying a date/time across multiple users time zones. They work with the Unix Timestamp format and can be posted by regular users as well as bots and applications.

The Epoch Unix Time Stamp Converter is a good way to quickly generate a timestamp. For the examples below I will be using the Time Stamp of 1543392060, which represents November 28th, 2018 at 09:01:00 hours for my local time zone (GMT+0100 Central European Standard Time).

Formatting

Style Input Output (12-hour clock) Output (24-hour clock)
Default <t:1543392060> November 28, 2018 9:01 AM 28 November 2018 09:01
import wx
class CustomFrame(wx.Frame):
def __init__(self, parent, title, image_dimensions):
super(CustomFrame, self).__init__(parent, title=title, style=wx.NO_BORDER)
self.SetBackgroundColour(wx.Colour(255, 255, 255)) # Set background color
# Load custom window images
self.SetIcon(wx.Icon("window_icon.ico", wx.BITMAP_TYPE_ICO))
self.frame_images = {
@runiq
runiq / .bash_profile
Created January 20, 2021 00:04
How I handle envvars
[[ -f "$HOME/.profile" ]] && source "$HOME/.profile"
[[ $- == *i* && -f "$HOME/.bashrc" ]] && source "$HOME/.bashrc"
import wx
class CustomFrame(wx.Frame):
def __init__(self, parent, title):
super(CustomFrame, self).__init__(parent, title=title, style=wx.DEFAULT_FRAME_STYLE)
# Load custom window images
self.SetIcon(wx.Icon("window_icon.ico", wx.BITMAP_TYPE_ICO))
self.SetBackgroundColour(wx.Colour(255, 255, 255)) # Set background color
@sts10
sts10 / rust-command-line-utilities.markdown
Last active May 4, 2024 22:40
A curated list of command-line utilities written in Rust

A curated list of command-line utilities written in Rust

Note: I have moved this list to a proper repository. I'll leave this gist up, but it won't be updated. To submit an idea, open a PR on the repo.

Note that I have not tried all of these personally, and cannot and do not vouch for all of the tools listed here. In most cases, the descriptions here are copied directly from their code repos. Some may have been abandoned. Investigate before installing/using.

The ones I use regularly include: bat, dust, fd, fend, hyperfine, miniserve, ripgrep, just, cargo-audit and cargo-wipe.

  • atuin: "Magical shell history"
  • bandwhich: Terminal bandwidth utilization tool
import wx
class CustomFrame(wx.Frame):
def __init__(self, parent, title):
super(CustomFrame, self).__init__(parent, title=title, style=wx.NO_BORDER)
self.SetBackgroundColour(wx.Colour(255, 255, 255)) # Set background color
# Load custom window images
self.SetIcon(wx.Icon("window_icon.ico", wx.BITMAP_TYPE_ICO))
self.frame_images = {
@jeerovan
jeerovan / view_db.dart
Created April 25, 2024 12:01
SQLite DB browser in Flutter
import 'package:flutter/material.dart';
import 'package:sqflite/sqflite.dart';
import 'package:path/path.dart';
class DatabasePage extends StatefulWidget {
@override
State<DatabasePage> createState() => _DatabasePageState();
}
class _DatabasePageState extends State<DatabasePage> {
@kaaquist
kaaquist / podman_macos.md
Last active May 4, 2024 22:37
Podman with docker-compose on MacOS.

Podman with docker-compose on MacOS.

Podman an alternative to Docker Desktop on MacOS

Getting podman installed and started is super easy.
Just use brew to install it.

> brew install podman

Now since podman uses a VM just like the Docker Client on MacOS we need to initialize that and start it.