Skip to content

Instantly share code, notes, and snippets.

View mormegil-cz's full-sized avatar

Petr Kadlec mormegil-cz

View GitHub Profile
@AreYouLoco
AreYouLoco / dns_forpsi.sh
Last active February 15, 2025 16:15
Posix script to use acme.sh with forpsi.com - DNS API
#!/usr/bin/env sh
# FORPSI DNS API for acme.sh
# Based on https://gist.githubusercontent.com/patrikbeno/29b5e2746367acf0e1b587e02b8b3a50/raw/1e39790e1bc3e5455eb0e7d08abaa412de07d3b7/dns_forpsi.sh
# And modified by (me) Orest Worhacz with the help of ChatGPT
# Works! It could be easily adapted to forpsi.sk/.cz/.pl
# Usage: ./acme.sh --issue --dns dns_forpsi -d site.example.com
username="username"
password="password&1"
domain_id="12345"
@dicej
dicej / type-systems.txt
Last active December 17, 2024 08:24
Type system learning notes
Classes
* Keith Devlin - Introduction to Mathematical Thinking - https://www.coursera.org/learn/mathematical-thinking
* Michael Genesereth - Introduction to Logic - https://www.coursera.org/learn/logic-introduction
* Robert Harper - Homotopy Type Theory - http://www.cs.cmu.edu/~rwh/courses/hott/
Books and Articles
* Benjamin C. Pierce - Types and Programming Languages - https://www.cis.upenn.edu/~bcpierce/tapl/
* x775 - Introduction to Datalog - https://x775.net/2019/03/18/Introduction-to-Datalog.html
* Bartosz Milewski - Category Theory For Programmers - https://bartoszmilewski.com/2014/10/28/category-theory-for-programmers-the-preface/
* Benjamin C. Pierce et al. - Software Foundations - https://softwarefoundations.cis.upenn.edu/
import os
import pickle
import warnings
import numpy as np
import pandas as pd
from sklearn.model_selection import train_test_split
from tensorflow.keras.callbacks import EarlyStopping
from tensorflow.keras.layers import Dense
from tensorflow.keras.layers import Dropout

The Freenode resignation FAQ, or: "what the fuck is going on?"

IMPORTANT NOTE:

It's come to my attention that some people have been spamming issue trackers with a link to this gist. While it's a good idea to inform people of the situation in principle, please do not do this. By all means spread the word in the communities that you are a part of, after verifying that they are not aware yet, but unsolicited spam is not helpful. It will just frustrate people.

Update 3 (May 24, 2021)

A number of things have happened since the last update.

@Greelan
Greelan / letsencrypt_notes.sh
Last active April 14, 2025 19:14 — forked from lachesis/letsencrypt_notes.sh
Set up Let’s Encrypt certificate using acme.sh as non-root user
# How to use acme.sh to set up Let's Encrypt, with the script being run
# mostly without root permissions
# See https://github.com/Neilpang/acme.sh for more
# These instructions use the domain "EXAMPLE.COM" as an example
# These instructions:
# - work on Ubuntu 18.04 and 20.04 with nginx
# - use CloudFlare DNS validation
@insin
insin / updatePasswords.js
Last active June 21, 2024 18:43
Mass update Firefox passwords (run in Tools → Web Developer → Browser Console) - https://developer.mozilla.org/en-US/docs/Tools/Browser_Toolbox#Enabling_the_Browser_Toolbox
function updatePasswords() {
let oldPassword = prompt('Old password:')
if (!oldPassword) return
let loginManager = Components.classes['@mozilla.org/login-manager;1']
.getService(Components.interfaces.nsILoginManager)
let matchingLogins = loginManager.getAllLogins().filter(l => l.password === oldPassword)
let matchCount = matchingLogins.length
if (matchCount === 0) return alert('No matching logins found')
@kontez
kontez / freeotp_backup.md
Created January 4, 2018 14:27 — forked from jleclanche/freeotp_backup.md
A guide to back up and recover 2FA tokens from FreeOTP (Android)

Backing up and recovering 2FA tokens from FreeOTP

Backing up FreeOTP

Using adb, create a backup of the app using the following command:

adb backup -f freeotp-backup.ab -apk org.fedorahosted.freeotp
@abatkin
abatkin / CITRIX.md
Created May 26, 2017 03:53
Make Citrix Receiver and Storefront usable on Linux

In order to make Citrix Receiver on Linux function nicely, I have modified the following settings in ~/.ICAClient/All_Regions.ini:

  • In [Virtual Channels\Seamless Windows]:
    • Set TWIMode=FALSE
    • This forces the window into true Fullscreen mode (as opposed to Seamless mode where the window happens to be fullscreen - there is a big difference!)
  • In [Virtual Channels\Mouse]:
    • Set MouseSendsControlV=False
    • This makes the middle mouse button function as a middle mouse button (as opposed to sending Ctrl+V, which I can't imagine anyone on Earth would actually want)
  • In [Virtual Channels\Keyboard]:
  • Set TransparentKeyPassthrough=FullScreenOnly
@parmentf
parmentf / GitCommitEmoji.md
Last active April 30, 2025 21:43
Git Commit message Emoji
@FunTimeCoding
FunTimeCoding / phd
Created June 21, 2014 17:46
phabricator daemons init script
#! /bin/sh
### BEGIN INIT INFO
# Provides: phd
# Required-Start: $remote_fs $syslog
# Required-Stop: $remote_fs $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: phabricator
# Description: manages phd
### END INIT INFO