Skip to content

Instantly share code, notes, and snippets.

@zachdaniel
zachdaniel / stream_distribute.ex
Last active May 3, 2024 23:02
A small demo to show how you might, given a stream, do a "fan out", processing different elements in separate streams. Powered by simple primitives like `Stream.resource` and `spawn_link`. Open in Livebook: https://livebook.dev/run?url=https%3A%2F%2Fgist.github.com%2Fzachdaniel%2Fd5ab06a9d2362fceeb6d27c37b206e28
<!-- livebook:{"persist_outputs":true} -->
# Distribute
## Section
A small toy to show how you might, given a stream, do a "fan out", processing different elements in separate streams. Powered by simple primitives like `Stream.resource` and `spawn_link`.
```elixir
defmodule Distribute do
@ricealexander
ricealexander / emoji-list.md
Last active May 3, 2024 22:59 — forked from rxaviers/gist:7360908
Comprehensive list of GitHub-supported emojis
@youngguncollins
youngguncollins / README.md
Created May 3, 2024 22:58 — forked from careyi3/README.md
Arduino PID Implementation

Arduino PID

This is a basic implementation of a PID controller on an Arduino.

system_diagram

To replicate this, wire up the system as shown below:

system_diagram

@LinuxDevOpsGirl
LinuxDevOpsGirl / anydeskuninstall.sh
Created October 27, 2018 11:57
Uninstall AnyDesk & Install New AnyDesk Ubuntu 16 64 bit Machine
sudo apt-get purge anydesk
sudo apt-get autoclean
sudo apt-get autoremove
sudo apt update
sudo apt list --upgradable
sudo apt upgrade -y
https://download.anydesk.com/linux/anydesk_4.0.0-1_amd64.deb
sudo dpkg -i anydesk_4.0.0-1_amd64.deb
sudo apt install -f
sudo apt update
@careyi3
careyi3 / README.md
Last active May 3, 2024 22:58
Arduino PID Implementation

Arduino PID

This is a basic implementation of a PID controller on an Arduino.

system_diagram

To replicate this, wire up the system as shown below:

system_diagram

@mohanpedala
mohanpedala / bash_strict_mode.md
Last active May 3, 2024 22:55
set -e, -u, -o, -x pipefail explanation
@Lego2012
Lego2012 / Hugo: German Date.html
Last active May 3, 2024 22:52
Hugo: German Date
<div class="bg-white mb3 pa2 gray overflow-hidden" datetime="{{ .Date.Format "2006-01-02T15:04:05Z07:00" | safeHTML }}">
<h1 class="f3 near-black">
<a href="{{ .RelPermalink }}" class="link black dim">
{{ .Title }} <small class="f6 ml2">vom {{ .Date.Day }}. {{ index $.Site.Data.monate (printf "%d" .Date.Month) }} {{ .Date.Year }}</small>
</a>
</h1>
<div class="nested-links f5 lh-copy nested-copy-line-height">
{{ .Summary }}
</div>
</div>
@martijnvermaat
martijnvermaat / ssh-agent-forwarding-screen.md
Created December 21, 2013 15:06
SSH agent forwarding and screen

SSH agent forwarding and screen

When connecting to a remote server via SSH it is often convenient to use SSH agent forwarding so that you don't need a separate keypair on that server for connecting to further servers.

This is enabled by adding the

ForwardAgent yes

option to any of your Host entries in ~/.ssh/config (or alternatively with the -A option). Don't set this option in a wildcard Host * section since any user on the remote server that can bypass file permissions can now als use keys loaded in your SSH agent. So only use this with hosts you trust.

@EricEzaM
EricEzaM / godot_ticker_smooth.gd
Last active May 3, 2024 22:48
Godot Label Scrolling/Ticker Text
# On the parent, e.g. ColorRect
# This gives this CanvasItem a "clipping mask" that only allows children to display within it's rect.
func _draw():
VisualServer.canvas_item_set_clip(get_canvas_item(), true)
# On the child (Label)
export (float) var scroll_speed = 60
func _process(delta):
rect_position.x -= scroll_speed * delta
@colorfield
colorfield / drupal8-links.php
Last active May 3, 2024 22:47
Drupal 8 links, or where is my l() function