Skip to content

Instantly share code, notes, and snippets.

@aamiaa
aamiaa / CompleteDiscordQuest.md
Last active May 2, 2024 06:49
Complete Recent Discord Quest

Complete Recent Discord Quest

Note

This no longer works in browser!

Note

This no longer works if you're alone in vc! Somebody else has to join you!

How to use this script:

  1. Accept the quest under User Settings -> Gift Inventory
@memphys
memphys / shortcuts.md
Created March 28, 2012 12:22
Bash Shortcuts For Maximum Productivity

source: http://www.skorks.com/2009/09/bash-shortcuts-for-maximum-productivity/

Command Editing Shortcuts

  • Ctrl + a – go to the start of the command line
  • Ctrl + e – go to the end of the command line
  • Ctrl + k – delete from cursor to the end of the command line
  • Ctrl + u – delete from cursor to the start of the command line
  • Ctrl + w – delete from cursor to start of word (i.e. delete backwards one word)
  • Ctrl + y – paste word or text that was cut using one of the deletion shortcuts (such as the one above) after the cursor
@chranderson
chranderson / nvmCommands.js
Last active May 2, 2024 06:48
Useful NVM commands
// check version
node -v || node --version
// list locally installed versions of node
nvm ls
// list remove available versions of node
nvm ls-remote
// install specific version of node
@y0ngb1n
y0ngb1n / docker-registry-mirrors.md
Last active May 2, 2024 06:46
国内的 Docker Hub 镜像加速器,由国内教育机构与各大云服务商提供的镜像加速服务 | Dockerized 实践 https://github.com/y0ngb1n/dockerized

Docker Hub 镜像加速器

国内从 Docker Hub 拉取镜像有时会遇到困难,此时可以配置镜像加速器。Docker 官方和国内很多云服务商都提供了国内加速器服务。

Dockerized 实践 https://github.com/y0ngb1n/dockerized

配置加速地址

Ubuntu 16.04+、Debian 8+、CentOS 7+

@ATRescue
ATRescue / AutoWB.js
Created May 26, 2019 02:08
UserScript to automatically save visited pages into the Wayback Machine.
/* This Userscript helps you preserving websites by automatically saving pages you visit, including their linked subpages and other linked URLs, into Internet Archive's Wayback Machine.
Run this UserScript using the following tools:
Desktop browsers:
* GreaseMonkey for Mozilla Firefox: https://addons.mozilla.org/en-US/firefox/addon/greasemonkey/
* TamperMonkey for Google Chrome: https://chrome.google.com/webstore/detail/tampermonkey/dhdgffkkebhmkfjojejmpbldmpobfkfo
* TamperMonkey for Chromium-Opera Browser: https://addons.opera.com/en/extensions/details/tampermonkey-beta/
@MarkRBest
MarkRBest / risk_manager.py
Created April 6, 2024 18:42
Risk manager using array indexing
from enum import IntEnum
class Exchange(IntEnum):
Binance = 0
Bybit = 1
Okx = 2
class Currency(IntEnum):
BTC = 0
ETH = 0
# Backup and restore UBI partitions and volumes
# Tested on Arris RAC2V1A router
BusyBox v1.22.1 (2018-03-01 14:46:14 CST) built-in shell (ash)
Enter 'help' for a list of built-in commands.
MM NM MMMMMMM M M
$MMMMM MMMMM MMMMMMMMMMM MMM MMM
MMMMMMMM MM MMMMM. MMMMM:MMMMMM: MMMM MMMMM
@rbreaves
rbreaves / Firefox-global-menu-fix.sh
Last active May 2, 2024 06:35
Firefox AUR global menu fix for any distro
#!/bin/bash
curl -s https://raw.githubusercontent.com/89luca89/distrobox/main/install | sudo sh
sudo apt install podman
distrobox-create --name arch --image docker.io/library/archlinux:latest
distrobox-enter arch
# Pre-compiled
@ohownew
ohownew / 知识星球视频增强.js
Last active May 2, 2024 06:35
知识星球原生视频组件,无法通过键盘操作前进、后退、暂停、播放,于是写了一个简单的脚本,要先安装好篡改猴Tampermonkey等插件管理器。然后新建脚本,并复制如下代码
// ==UserScript==
// @name 知识星球视频增强
// @namespace http://tampermonkey.net/
// @version 2024-04-21
// @description 知识星球视频,通过键盘控制: 前进 后退 暂停 开始 全屏
// @author ohownew
// @match https://wx.zsxq.com/*
// @icon https://www.google.com/s2/favicons?sz=64&domain=zsxq.com
// @grant none
// ==/UserScript==
@BrutalSimplicity
BrutalSimplicity / Dockerfile
Created September 1, 2022 20:20
Dockerfile with asdf + docker install bits
FROM debian:latest
# Install basic dev packages
RUN apt-get clean && apt-get update && apt-get -y install --no-install-recommends \
apt-utils \
openssh-client \
git \
gnupg2 \
dirmngr \
iproute2 \