git clone [email protected]:rr-debugger/rr.git
cd rr
find . -type f -exec dos2unix {} +
mkdir -p build
cd build
CC=clang CXX=clang++ cmake -G Ninja -Ddisable32bit=ON -DCMAKE_EXE_LINKER_FLAGS="-fuse-ld=lld -L/home/apetenchea/scripts" -DCMAKE_BUILD_TYPE=Release ..
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
import json | |
import pandas as pd | |
import pydantic | |
import pydantic_core | |
from typing import Sequence, cast | |
from arangoasync.collection import StandardCollection | |
from arangoasync.database import StandardDatabase | |
from arangoasync.exceptions import DeserializationError, SerializationError | |
from arangoasync.serialization import Serializer, Deserializer | |
from arangoasync.typings import Json, Jsons |
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
import requests | |
ARANGODB_ERRORS_FILE = "https://raw.githubusercontent.com/arangodb/arangodb/refs/heads/devel/lib/Basics/errors.dat" # noqa: E501 | |
def generate_section(line, output): | |
text = line[3:].strip() | |
print("#" * (len(text) + 4), file=output) | |
print(f"# {text} #", file=output) | |
print("#" * (len(text) + 4) + "\n", file=output) |
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
# Check inputs | |
if (-not $setup) { $setup = "cluster" } | |
if (-not $license) { $license = "enterprise" } | |
if (-not $version) { $version = "3.12" } | |
# Determine image name | |
if ($license -eq "community") { | |
$image_name = "arangodb" | |
} elseif ($license -eq "enterprise") { | |
$image_name = "enterprise" |
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
# This script gathers all the pages of a manual and merges them into a PDF. | |
# You'll need to play a bit with inspect-element in order to figure out the format the correct url, | |
# but it should be easy to adapt it to any manual. | |
# This script is specifically for https://www.manua.ls/audi/q3-2018/manual. | |
# Their url format is https://www.manua.ls/viewer/{manual-id}/{page-number}/bg{page-number-hex}.png | |
# Example: https://www.manua.ls/viewer/668006/100/bg64.png | |
# Enjoy! | |
import requests | |
from tqdm import tqdm | |
from PIL import Image |
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
export ARANGODB_PATH="$HOME/arangodb" | |
# Continue process listening on port | |
function portcont() { | |
kill -SIGCONT $(portpid "$1") | |
} | |
# Kill process listening on port | |
function portkill() { | |
kill -9 $(portpid "$1") |
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
# importing libraries | |
import pathlib | |
import sys | |
import speech_recognition as sr | |
import os | |
from pydub import AudioSegment | |
from pydub.silence import split_on_silence | |
# create a speech recognition object | |
r = sr.Recognizer() |
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
import arango | |
import time | |
url = f"http://localhost:8530" | |
client = arango.ArangoClient(hosts=url) | |
db = client.db(name="_system") | |
print(db.version()) | |
if not db.has_collection('x'): | |
db.create_collection('x') |
This is in response to issue #18900.
It shows how to set up an arangodb cluster with 3 agents, 2 coordinators and 3 db severs, using docker-compose. This
is not the way I would set up a cluster in production, but it is ok for testing the cluster functionality. I recommend
checking out the official documentation,
especially Using the ArangoDB Starter.
docker-compose.yml
version: '3.7'
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
# Script for parsing mealplans and generating a shopping list | |
# python mealplan.py mealplan.txt > list.txt | |
import sys | |
import re | |
def get_lines(file): | |
names = ['Alex', 'Lucia'] |
NewerOlder