sudo apt-get install python-pip libcairo2 python-cairo
pip install carbon
pip install whisper
pip install django
pip install django-tagging
pip install graphite-web
val a = Stream(1) | |
//a: scala.collection.immutable.Stream[Int] = Stream(1, ?) | |
def b: Stream[Int] = Stream(b.head) | |
//b: Stream[Int] | |
a #::: b | |
//res0: scala.collection.immutable.Stream[Int] = Stream(1, ?) | |
a append b |
# Python http.server that sets Access-Control-Allow-Origin header. | |
# https://gist.github.com/razor-x/9542707 | |
import os | |
import sys | |
import http.server | |
import socketserver | |
PORT = 8000 |
val kafkaProps = new Properties() | |
kafkaProps.put("bootstrap.servers", endpoint) | |
kafkaProps.put("key.serializer", classOf[ByteArraySerializer]) | |
kafkaProps.put("key.deserializer", classOf[ByteArrayDeserializer]) | |
kafkaProps.put("value.serializer", classOf[ByteArraySerializer]) | |
kafkaProps.put("value.deserializer", classOf[ByteArrayDeserializer]) | |
kafkaProps.put("group.id", "CrawlerTasksStorage") | |
kafkaProps.put("max.poll.records", "1000") | |
kafkaProps.put("enable.auto.commit","false") |
use std::path::Path; | |
use std::process::Stdio; | |
use tokio::io::BufReader; | |
use tokio::io::AsyncBufReadExt; | |
use tokio::process::Command; | |
use tokio::sync::mpsc; | |
/// Execute a process, gather its mixed outputs into stdout | |
/// |
use ropey::{Rope, RopeSlice}; | |
use serde::{Deserialize, Serialize}; | |
use std::fmt; | |
use thiserror::Error; | |
use tower_lsp::lsp_types::{Position, TextDocumentContentChangeEvent}; | |
use tree_sitter::{InputEdit, Parser, Point, Tree}; | |
pub struct TextDocument { | |
pub rope: Rope, | |
pub tree: Option<Tree>, |
version: '3.8' | |
networks: | |
my_network: | |
driver: bridge | |
volumes: | |
kafka-data: | |
kafka-ui-data: | |
services: |