- seller generates secret A
- seller asks hodlhodl to generate a hold invoice with payment hash = hash(A), notice that hodlhodl doesn’t have the preimage A
- seller sends a lightning payment to settle the invoice
- once hodlhodl receives the payment, it remains on hold since it doesn’t have the preimage A to settle it
- hodlhodl lets the seller know it received the payment, so that it can proceed
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
rpm -Uvh http://ftp.jaist.ac.jp/pub/Linux/Fedora/epel/6/x86_64/epel-release-6-8.noarch.rpm | |
yum install mosh –enablerepo=epel |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE TABLE accounts( | |
id serial PRIMARY KEY, | |
name VARCHAR(256) NOT NULL, | |
parent_id INTEGER REFERENCES section, | |
parent_path LTREE | |
); | |
CREATE INDEX account_parent_path_idx ON accounts USING GIST (parent_path); | |
CREATE INDEX account_parent_id_idx ON accounts (parent_id); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Capture and send video | |
gst-launch-1.0 v4l2src device=/dev/video0 \ | |
! decodebin \ | |
! x264enc \ | |
! rtph264pay \ | |
! udpsink port=5000 | |
Show the video | |
gst-launch-1.0 \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "tb_client.hpp" | |
int main() { | |
tb::Client client("localhost", 8080); | |
tb::Account account({0, 0, {0}, 1, 1, TB_ACCOUNT_LINKED, 0, 0, 0, 0, 0}); | |
tb::create_account_result result = client.create_account(account); | |
if (result != TB_CREATE_ACCOUNT_OK) { | |
// Handle error | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import io | |
class StringIteratorIO(io.TextIOBase): | |
def __init__(self, iter): | |
self._iter = iter | |
self._left = '' | |
def readable(self): | |
return True |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
TABLES: MKPF, | |
MSEG. | |
DATA: BEGIN OF gs_ara, | |
mblnr type mkpf-mblnr, | |
mjahr TYPE mkpf-mjahr, | |
budat TYPE mkpf-budat, | |
tcode2 TYPE mkpf-tcode2, | |
usnam TYPE mkpf-usnam, | |
cpudt TYPE mkpf-cpudt, |
This is not intended to be comprehensive or authoritative, just free online resources I've found valuable while learning more about Erlang.
- 0xAX's list of Erlang bookmarks
- Federico Carrone, Erlang Spawned Shelter
- Ivan Uemlianin's list of resources on various BEAM languages
- David Robakowski's curated list of awesome Erlang libraries, resources and shiny things
- Julius Beckmann's curated list of amazingly awesome Elixir and Erlang libraries, resources and shiny things
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
param( [ScriptBlock] $scriptBlock ) | |
<# | |
.SYNOPSIS | |
Impersonates a user and executes a script block as that user. This is an interactive script | |
and a window will open in order to securely capture credentials. | |
.EXAMPLE | |
Use-Impersonation.ps1 {Get-ChildItem 'C:\' | Foreach { Write-Host $_.Name }} | |
This writes the contents of 'C:\' impersonating the user that is entered. | |
#> | |
Phoenix implements trusted swaps for users' convenience (to allow easy onboarding and offboarding). But it's not a satisfying solution for the following reasons:
- It uses two on-chain transactions for swap-in where one should be sufficient (one transaction from the user to Acinq followed by a channel open)
- Swap-out feerates are unpredictable (because we may fund the swap-out with unconfirmed previous outputs) which is frustrating for users
- It forces Acinq to use its own utxos, which doesn't scale well and is an operational burden
- If Acinq doesn't have any utxos available and the mempool is completely full, swaps are stuck which is also frustrating for users
OlderNewer