Skip to content

Instantly share code, notes, and snippets.

@PurpleBooth
PurpleBooth / README-Template.md
Last active December 29, 2024 08:48
A template to make good README.md

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

@ar7eniyan
ar7eniyan / config
Last active December 29, 2024 08:48
Waybar module for controlling brightness of an external display
// insert into ~/.config/waybar/config
"custom/ddc_brightness": {
// I don't even want to know why this works.
// Change it to the following for your custom icons,
// current format is a hack for Material Symbols to display normally:
// "format": "{icon} {percentage}%",
"format": "<span rise='-2pt' size='12pt'>{icon}</span> <span rise='1pt' size='10pt'>{percentage}%</span>",
"format-icons": [
// Icons from Google Material Symbols.
@mondain
mondain / public-stun-list.txt
Last active December 29, 2024 08:46
Public STUN server list
23.21.150.121:3478
iphone-stun.strato-iphone.de:3478
numb.viagenie.ca:3478
s1.taraba.net:3478
s2.taraba.net:3478
stun.12connect.com:3478
stun.12voip.com:3478
stun.1und1.de:3478
stun.2talk.co.nz:3478
stun.2talk.com:3478
@NotAlexNoyle
NotAlexNoyle / fucktheskullofsystemd.sh
Last active December 29, 2024 08:46 — forked from artixnous/fucktheskullofsystemd.sh
Fast convert systemd Arch to OpenRC Artix (Fixed 2023)
#!/bin/bash
# nous,2019-2022
# How to use
# wget https://tiny.cc/fucksystemd
# chmod +x fucksystemd
# sudo ./fucksystemd
# Test Arch ISO installation:
# cfdisk /dev/sda

Cygwin, MSYS, MSYS2, MinGW, mingw-w64, WSL, WSL2 の違い

名称 役割 説明
MinGW コンパイラ Windows 用の GNU ツールチェーン。
とにかく Windows 用の gcc や GNU ld。
"Windows 用" とは、Windows 上で動作したり、Windows 用のアプリが作れたりすること。
要するに Visual C++ や Clang/LLVM みたいなもの。
mingw-w64 コンパイラ MinGW のフォーク。Win64 向けの改良が加わっており、2021 年現在の主流。
Cygwin POSIX 環境 Windows 用の POSIX 環境。cygwin1.
@kvnxiao
kvnxiao / awesome-selfhosted-sorted-by-stars.md
Last active December 29, 2024 08:38
awesome-selfhosted-sorted-by-stars.md

Awesome-Selfhosted

Awesome

Selfhosting is the process of locally hosting and managing applications instead of renting from SaaS providers.

This is a list of Free Software network services and web applications which can be hosted locally. Non-Free software is listed on the Non-Free page.

See Contributing.

@spalladino
spalladino / mysql-docker.sh
Created December 22, 2015 13:47
Backup and restore a mysql database from a running Docker mysql container
# Backup
docker exec CONTAINER /usr/bin/mysqldump -u root --password=root DATABASE > backup.sql
# Restore
cat backup.sql | docker exec -i CONTAINER /usr/bin/mysql -u root --password=root DATABASE
@WillianTomaz
WillianTomaz / wsl2-with-1password-info.md
Last active December 29, 2024 08:29
Instructions for using 1Password SSH Agent with WSL2 (on Windows 11)

LinkedIn

Saturday, April 22, 2023

How to Use 1Password SSH Agent with WSL2 (on Windows 11)

  • Note:

    • Always look for the official documentation, this tutorial may not suit you as there are new updates to the installation process.
    • References are at the end of the document.
  • Was used:

KFZUS-F3JGV-T95Y7-BXGAS-5NHHP
T3ZWQ-P2738-3FJWS-YE7HT-6NA3K
KFZUS-F3JGV-T95Y7-BXGAS-5NHHP
65Z2L-P36BY-YWJYC-TMJZL-YDZ2S
SFZHH-2Y246-Z483L-EU92B-LNYUA
GSZVS-5W4WA-T9F2E-L3XUX-68473
FTZ8A-R3CP8-AVHYW-KKRMQ-SYDLS
Q3ZWN-QWLZG-32G22-SCJXZ-9B5S4
DAZPH-G39D3-R4QY7-9PVAY-VQ6BU
KLZ5G-X37YY-65ZYN-EUSV7-WPPBS
@odan
odan / mocking-interface-phpunit.md
Last active December 29, 2024 08:24
Mocking Interfaces with PHPUnit

Mocking Interfaces with PHPUnit

Using the MockBuilder

To mock an interface with PHPUnit we have to pass all methods of the given Interface.

 $reflection = new \ReflectionClass(UserRepositoryInterface::class);

$methods = [];