Skip to content

Instantly share code, notes, and snippets.

View 5HT's full-sized avatar
🌐
I'm very skeptical that person without empathy can create beautiful mathematics.

Namdak Tonpa 5HT

🌐
I'm very skeptical that person without empathy can create beautiful mathematics.
View GitHub Profile
@kachayev
kachayev / channels.erl
Last active December 15, 2017 19:36
Process communication programming
-module(channels).
-compile(export_all).
make() ->
Ref = make_ref(),
Pid = spawn(?MODULE, channel, [Ref]),
{channel, Pid, Ref}.
channel(Ref) ->
receive
@5HT
5HT / WebFrameworks.md
Last active January 26, 2021 07:19
Overview of Web Frameworks (2013)
@5HT
5HT / char.erl
Last active December 17, 2015 01:49
Чат на нитрогене
body() -> wf:comet_global(fun() -> loop() end,chat),
[ #panel{id=history}, #textbox{id=message}, #button{postback=chat}].
event(chat) -> wf:send_global(chat, wf:q(message)),
loop() -> receive Message -> wf:insert_bottom(history, #span{text=Message}), wf:flush() end, loop().
# Builder file for sentry
#
FROM ubuntu
MAINTAINER Michael Crosby
RUN echo "deb http://archive.ubuntu.com/ubuntu precise main universe" > /etc/apt/sources.list
RUN apt-get update
RUN apt-get upgrade
@crosbymichael
crosbymichael / Dockerfile
Last active January 8, 2022 13:47
Docker with supervisor
FROM ubuntu
RUN echo "deb http://archive.ubuntu.com/ubuntu precise main universe" > /etc/apt/sources.list
RUN apt-get update
RUN apt-get upgrade
RUN apt-get install -y openssh-server supervisor
ADD sshd.conf /etc/supervisor/conf.d/sshd.conf
RUN mkdir -p /var/run/sshd
@copumpkin
copumpkin / Topology.agda
Last active May 20, 2020 08:00
Topology?
module Topology where
import Level
open import Function
open import Data.Empty
open import Data.Unit
open import Data.Nat hiding (_⊔_)
open import Data.Fin
open import Data.Product
open import Relation.Nullary
@bryanhunter
bryanhunter / build-erlang-r16b01.sh
Last active December 20, 2015 15:09
Build Erlang R16B01 on Ubuntu
#!/bin/bash
# Pull this file down, make it executable and run it with sudo
# wget https://raw.github.com/gist/6152521/build-erlang-r16b01.sh
# chmod u+x build-erlang-r16b01.sh
# sudo ./build-erlang-r16b01.sh
if [ $(id -u) != "0" ]; then
echo "You must be the superuser to run this script" >&2
exit 1
fi

Bugs:

  • Autologin checkbox is disabled
  • Preferences menu is disabled
  • Main window isn't font sensitive. I use a 10pt font and there is 2 pixel space below the menu
  • When selecting a contact in the roster, the view LowColor isn't set, leading to text antialias artifacts
  • Double clicking a contact should open message window. Having to right-click > message is boring
  • Chat window: pressing enter should send message instead of doing a newline.

Enhancements:

  • Selection highlight in roster doesn't go all the way to the left of the window, there is whitespace left
@soarez
soarez / ca.md
Last active June 7, 2025 02:29
How to setup your own CA with OpenSSL

How to setup your own CA with OpenSSL

For educational reasons I've decided to create my own CA. Here is what I learned.

First things first

Lets get some context first.

#!/bin/bash
# Henrik Austad ,2009
# UNINETT Sigma A/S
#
# make_cmc.sh
#
# Shell-wrapper for making CMC's to send to a dogtag system
# This script uses CMCEnroll to create CMCs, and it creates simple CMCs,
# i.e. no bundling of several CSRs together.
#