Skip to content

Instantly share code, notes, and snippets.

View sivakov512's full-sized avatar
๐Ÿ˜Ž

Nikita Sivakov sivakov512

๐Ÿ˜Ž
View GitHub Profile
@sivakov512
sivakov512 / .clang-format
Last active January 21, 2025 09:37
clang-tidy & clang-config Google styleguide
---
BasedOnStyle: Google
# We keep 2-space indentation, 80-column limit, attached braces, etc.
IndentWidth: 2
TabWidth: 2
UseTab: Never
ColumnLimit: 80
BreakBeforeBraces: Attach
@sivakov512
sivakov512 / uart.rs
Last active June 4, 2024 22:09
Not working serial
#![no_std]
#![no_main]
use core::{fmt::Write as _, str::from_utf8};
use embedded_hal_nb::serial::{Read, Write};
use esp_backtrace as _;
use esp_hal::{
clock::ClockControl,
gpio,
peripherals::Peripherals,
@pytest.fixture
def my_pretty_fixture():
def inner(url_part, param):
url = f"{url_part}/azaza/{param}"
response = requests.post(url)
return response.json()
return inner
def test_puk(my_pretty_fixture):
@sivakov512
sivakov512 / ltree-example.sql
Last active November 11, 2022 16:35
Usign PostgreSQL Ltree extenstion
CREATE EXTENSION ltree;
CREATE TABLE test(
id serial primary key,
path ltree
);
INSERT INTO test (path) VALUES
('1'),
('1.1'),
('1.1.1'),