Skip to content

Instantly share code, notes, and snippets.

Aligning images

This is a guide for aligning images.

See the full Advanced Markdown doc for more tips and tricks

left alignment

@zeusdeux
zeusdeux / build_zdx.sh
Created June 16, 2024 01:25
Build static universal raylib as libraylib.a on macos (libraylib.a)
#! /bin/sh
set -e
function build_raylib_macos {
curr_dir="$(basename $(pwd))"
if [[ "$curr_dir" != "src" ]];
then
@cstroe
cstroe / OpenSourceCRM.rst
Last active May 12, 2025 18:35
A distilled list of open-source CRM software
@yasirkula
yasirkula / ScrollViewFocusFunctions.cs
Created October 23, 2021 10:09
Focus/center Scroll View to the specified point/item in Unity
using System.Collections;
using UnityEngine;
using UnityEngine.UI;
public static class ScrollViewFocusFunctions
{
public static Vector2 CalculateFocusedScrollPosition( this ScrollRect scrollView, Vector2 focusPoint )
{
Vector2 contentSize = scrollView.content.rect.size;
Vector2 viewportSize = ( (RectTransform) scrollView.content.parent ).rect.size;
@sems
sems / setuplinkaggregationunraid.md
Last active May 12, 2025 18:34
Setup guide link aggregation(802.3ad) Unraid with Ubiquiti

Setup guide link aggregation Unraid with Ubiquiti

Introduction

I am writing this guide becuase I coudn't find a proper one online which contained all the information I was searching for. I will try to guide you through the process of enabling link aggregation (802.3ad) with your Ubiquiti hardware and your Unraid server. Note: not all of Ubiquiti's hardware supports link aggregation (LAG). As of the time of writing Ubiquiti states the following.

Applicable to all UniFi Switch models excluding the USW-Flex and USW-Flex-Mini.

Source: Ubiquiti

@ChristopherA
ChristopherA / zsh_opinionated_best_practices.md
Last active May 12, 2025 18:34
Zsh - Opinionated Best Practices

Zsh Opinionated - A Guide to Best Practices

  • Abstract: This guide provides best practices for writing clear, maintainable, and robust Zsh scripts. Aimed at helping developers transition from Bash to Zsh, particularly on macOS, this guide offers practical advice and examples for creating standardized and efficient scripts.

  • Copyright This text of this guide is Copyright ©️2024 by Christopher Allen, and is shared under spdx:CC-BY-SA-4.0 open-source license. All the example code is relenquished to the public domain under spx:CC0-1.0.

  • Tags: #zsh #scripting #cli #opinionated

@tomasevich
tomasevich / remove-all-from-docker.md
Last active May 12, 2025 18:33 — forked from beeman/remove-all-from-docker.sh
Удалить/очистить все данные Докера (контейнеры, образы, тома и сети)

Удалить/очистить все данные Докера (контейнеры, образы, тома и сети)

Одной строкой

docker stop $(docker ps -qa) && docker rm $(docker ps -qa) && docker rmi -f $(docker images -qa) && docker volume rm $(docker volume ls -q) && docker network rm $(docker network ls -q)

Описание команд

@xiongtx
xiongtx / ini-sort.el
Last active May 12, 2025 18:33
Sort INI file
(require 'cl-lib)
(require 'subr-x)
(defun *-ini-sort ()
"Sort an INI buffer by sections and properties.
Combines repeated sections. E.g.
[b]
b1=1
b3=3
** Collection #1 passwords list **
Hello everyone,
Recently, a dark web monitoring firm 4iQ discovered a massive trove of 41GB data file containing 1.4 billion billion login credentials including emails and passwords in clear-text format.
This db was already found in the dark net during january and succefully removed from the internet but it has been newly uploaded.
magnet:?xt=urn:btih:7ffbcd8cee06aba2ce6561688cf68ce2addca0a3&dn=BreachCompilation&tr=udp%3A%2F%2Ftracker.openbittorrent.com%3A80&tr=udp%3A%2F%2Ftracker.leechers-paradise.org%3A6969&tr=udp%3A%2F%2Ftracker.coppersurfer.tk%3A6969&tr=udp%3A%2F%2Fglotorrents.pw%3A6969&tr=udp%3A%2F%2Ftracker.opentrackr.org%3A1337
- follow me on https://twitter.com/criptixo :)
@arthurk
arthurk / gist:ab9ced56ce78bb8309599ccc62fa2576
Created June 1, 2020 03:50
fetch list images from GCR via service account
#!/usr/bin/env bash
set -euo pipefail
######################
# Script that fetches a list of all images from GCR
# uses 3 different users in GCR
######################
keyfile="gcr-svc-acc-keyfile.json"
projectName="example-project"