Skip to content

Instantly share code, notes, and snippets.

@flaki
flaki / docker-to-proxmox.md
Created February 7, 2023 21:36
Importing a Docker container image into Proxmox Linux Containers (LXC)

Importing a Docker container into Proxmox/LXC

Importing the container

For this we are going to be using lxc-create, which comes pre-installed on Proxmox but needs further dependencies to fetch the OCI images from Docker:

apt update && apt -y install skopeo umoci jq
@ben-mohrbacher
ben-mohrbacher / .gitmessage
Created May 20, 2024 14:47
A git commit message template
<your-ticket-prefix>
# Subject Line
# ======================================================================
#
# One line less than 72 characters in length. Generally focused on the
# "What" rather than the "Why".
#
# Format <tag>: <message>
#
# `tag`: can be either a defined list of tags like "Add", "Remove",
@rebane2001
rebane2001 / plot_discord_predictions.py
Last active May 21, 2024 01:21
Simple script to plot your Discord machine-learning predicted age and gender from the data dump.
"""
Simple script to plot your Discord machine-learning predicted age and gender from the data dump.
To use, simply put this script in your activity/analytics/ folder of your Discord data dump and run it.
You may need to install matplotlib first:
pip install -U matplotlib
thrown together by rebane2001
@aamiaa
aamiaa / CompleteDiscordQuest.md
Last active May 21, 2024 01:20
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
@hurricane-voronin
hurricane-voronin / README.md
Last active May 21, 2024 01:19
Naming Classes Without a 'Manager'
@bsdayo
bsdayo / make-shortcut.ps1
Last active May 21, 2024 01:23
Super "Windows shortcut" maker with embedded icon
param(
[Parameter(Mandatory)] [string] $Command,
[Parameter(Mandatory)] [string] $IconFile,
[string] $Output,
[switch] $Keep
)
(Get-Content -Encoding UTF8 template.c) -replace "COMMAND_PLACEHOLDER", ($Command -replace '\\', '\\') | Out-File -Encoding UTF8 temp.c
"icon ICON `"$($IconFile -replace '\\', '\\')`"" | Out-File -Encoding UTF8 temp.rc
@enesien
enesien / shadcn-multi-tag-input.md
Last active May 21, 2024 01:16
shadcn multiple tag input

shadcn/ui multi tag input component

A react tag input field component using shadcn, like one you see when adding keywords to a video on YouTube. Usable with Form or standalone.

Preview

image

Standalone Usage

@squarism
squarism / iterm2.md
Last active May 21, 2024 01:14
An iTerm2 Cheatsheet

Tabs and Windows

Function Shortcut
New Tab + T
Close Tab or Window + W (same as many mac apps)
Go to Tab + Number Key (ie: ⌘2 is 2nd tab)
Go to Split Pane by Direction + Option + Arrow Key
Cycle iTerm Windows + backtick (true of all mac apps and works with desktops/mission control)
@morvanabonin
morvanabonin / comandos-docker
Last active May 21, 2024 01:13
Comandos do Docker
Segue a lista de comandos docker e sua utilidade:
docker attach – Acessar dentro do container e trabalhar a partir dele.
docker build – A partir de instruções de um arquivo Dockerfile eu possa criar uma imagem.
docker commit – Cria uma imagem a partir de um container.
docker cp – Copia arquivos ou diretórios do container para o host.
docker create – Cria um novo container.
docker diff – Exibe as alterações feitas no filesystem do container.
docker events – Exibe os eventos do container em tempo real.
docker exec – Executa uma instrução dentro do container que está rodando sem precisar atachar nele.
@y0ngb1n
y0ngb1n / docker-registry-mirrors.md
Last active May 21, 2024 01:11
国内的 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+