This file contains hidden or 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
# Heavily inspired from fsspec's GenericFileSystem implementation of rsync | |
import logging | |
from typing import Any, Callable | |
from fsspec.implementations.sftp import AbstractFileSystem | |
from gcsfs import GCSFileSystem | |
from rich.logging import RichHandler | |
from sshfs import SSHFileSystem | |
LOG_FORMAT = "%(message)s" |
This file contains hidden or 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
from typing import Optional | |
class Feed: | |
max = None | |
min = None | |
recent = -1 | |
data_map = {} | |
def ingest(self, timestamp: int, price: Optional[float] = None): | |
if price is None: |
This file contains hidden or 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
{ | |
lineGroupers: [ | |
{ | |
start: "^\\d{4}-\\d{2}-\\d+ \\d{2}:\\d{2}:\\d{2},\\d+", | |
haltBefore: "^\\d{4}-\\d{2}-\\d+ \\d{2}:\\d{2}:\\d{2},\\d+" | |
} | |
], | |
patterns: { | |
axTs: "\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}\\.\\d{9}", | |
axTz: "[\\-\\+]\\d{2}:\\d{2}", |
This file contains hidden or 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
cryptsetup open /dev/nvme0n1p3 lvm | |
mount /dev/mapper/PV-root /mnt | |
mount /dev/mapper/PV-home /mnt/home | |
swapon /dev/mapper/PV-swap | |
cryptsetup open /dev/nvme0n1p2 cryptboot | |
mount /dev/mapper/cryptboot /mnt/boot | |
mount /dev/nvme0n1p1 /mnt/boot/efi | |
curl -O -L https://tinyurl.com/123archusmirror | |
mv 123archusmirror /etc/pacman.d/mirrorlist | |
arch-chroot /mnt |
This file contains hidden or 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
<configuration> | |
<appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender"> | |
<encoder> | |
<pattern>%d{ISO8601,UTC} [%thread] %-5level %logger{36} %X{akkaTimestamp} %X{akkaSource} - %msg%n</pattern> | |
</encoder> | |
</appender> | |
<logger name="akka" level="INFO"/> | |
<logger name="com.vivint.smarthvac.actor.device.DeviceSupervisor" level="WARN"/> | |
<logger name="akka.actor.CoordinatedShutdown" level="DEBUG"/> |
This file contains hidden or 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
from kafka import KafkaProducer | |
from functools import partial | |
from vivint_generated.constants import Fields | |
utf8_encode = partial(str.encode, encoding="UTF-8") | |
config = { | |
'bootstrap_servers': 'localhost', | |
'key_serializer': utf8_encode, |
This file contains hidden or 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
{"title": "Basic Dashboard With Pointers", "services": {"query": {"idQueue": [1, 2, 3, 4], "list": {"0": {"query": "*", "alias": "", "color": "#7EB26D", "id": 0, "pin": false, "type": "lucene"}}, "ids": [0]}, "filter": {"idQueue": [1, 2], "list": {"0": {"from": "NOW/MINUTE-15MINUTE", "to": "NOW/MINUTE%2B1MINUTE", "field": "event_timestamp", "type": "time", "fromDateObj": "2016-06-03T18:59:05.650Z", "toDateObj": "2016-06-03T19:14:05.651Z", "mandate": "must", "active": true, "alias": "", "id": 0}}, "ids": [0]}}, "rows": [{"title": "Overview", "height": "50px", "editable": true, "collapse": true, "collapsable": true, "panels": []}, {"title": "Query and Time Window", "height": "50px", "editable": true, "collapse": false, "collapsable": true, "panels": [{"error": "", "span": 6, "editable": true, "type": "timepicker", "loadingEditor": false, "status": "Stable", "mode": "relative", "spyable": true, "time_options": ["5m", "15m", "1h", "6h", "12h", "24h", "2d", "7d", "30d", "90d", "1y", "5y"], "timespan": "15m", "time |
This file contains hidden or 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
{ | |
"serialization-bindings": { | |
"[B": "bytes", | |
"akka.actor.ActorSelectionMessage": "akka-containers", | |
"akka.cluster.ClusterMessage": "akka-cluster", | |
"akka.cluster.client.ClusterClientMessage": "akka-cluster-client", | |
"akka.cluster.ddata.ReplicatedDataSerialization": "akka-replicated-data", | |
"akka.cluster.ddata.Replicator$ReplicatorMessage": "akka-data-replication", | |
"akka.cluster.pubsub.DistributedPubSubMessage": "akka-pubsub", | |
"akka.cluster.sharding.ClusterShardingSerializable": "akka-sharding", |
This file contains hidden or 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
bindkey '^P' up-history | |
bindkey '^N' down-history | |
bindkey '^?' backward-delete-char | |
bindkey '^h' backward-delete-char | |
bindkey '^w' backward-kill-word | |
bindkey '^r' history-incremental-search-backward | |
function zle-line-init zle-keymap-select { | |
VIM_PROMPT="%{$fg_bold[yellow]%} [% NORMAL]% %{$reset_color%}" | |
RPS1="${${KEYMAP/vicmd/$VIM_PROMPT}/(main|viins)/}$(git_custom_status) $EPS1" |