Skip to content

Instantly share code, notes, and snippets.

View untodesu's full-sized avatar
💣
skibigit sigma merge

Kirill Dmitrievich untodesu

💣
skibigit sigma merge
View GitHub Profile
#!/bin/bash
set -e
# --- Определяем архитектуру ---
ARCH=$(uname -m)
case "$ARCH" in
x86_64) ARCH="amd64" ;;
aarch64) ARCH="arm64" ;;
armv7l) ARCH="arm" ;;
*)
@untodesu
untodesu / .clang-format
Created June 25, 2025 11:47
RUS-DMIS clang-format
---
AccessModifierOffset: -4
AlignAfterOpenBracket: DontAlign
AlignConsecutiveAssignments: None
AlignConsecutiveBitFields: None
AlignConsecutiveDeclarations: None
AlignConsecutiveMacros: Consecutive
AlignEscapedNewlines: Left
AlignOperands: Align
AlignTrailingComments:
#!/usr/bin/env python3
import datetime
import os, re
import uuid
import sys
log_file = open("server.log", "a", encoding="utf-8")
response_headers = []
response_body = []
/* SPDX-License-Identifier: BSD-2-Clause */
/* Copyright (c), 2023, Kirill GPRB */
/**
* Implements a Telegram Bot.
* @see https://core.telegram.org/bots/api
*/
export class BotClient {
token: string;
secret?: string;
/* SPDX-License-Identifier: BSD-2-Clause */
/* Copyright (c), 2023, KanOS Contributors */
#include <kan/utf8.h>
#include <stdlib.h>
size_t mbtowc(wchar_t *restrict wc, const char *restrict s, size_t n)
{
size_t i, j;
size_t nchar;
wchar_t twc;
@untodesu
untodesu / 1.c
Created November 29, 2022 11:12
#include <stdio.h>
typedef float matrix4x4_t[4][4];
static float matrix_det(const matrix4x4_t m)
{
return
m[0][3] * m[1][2] * m[2][1] * m[3][0] - m[0][2] * m[1][3] * m[2][1] * m[3][0] - m[0][3] * m[1][1] * m[2][2] * m[3][0]+m[0][1] * m[1][3] * m[2][2] * m[3][0] +
m[0][2] * m[1][1] * m[2][3] * m[3][0] - m[0][1] * m[1][2] * m[2][3] * m[3][0] - m[0][3] * m[1][2] * m[2][0] * m[3][1]+m[0][2] * m[1][3] * m[2][0] * m[3][1] +
m[0][3] * m[1][0] * m[2][2] * m[3][1] - m[0][0] * m[1][3] * m[2][2] * m[3][1] - m[0][2] * m[1][0] * m[2][3] * m[3][1]+m[0][0] * m[1][2] * m[2][3] * m[3][1] +
@untodesu
untodesu / lar4.c
Created November 21, 2022 17:22
I sold this for 1500 RUB :)
/* note: most of unix editors such as
* vi/vim put a CR (newline character)
* at the very end of files, so the resulting
* amount of characters is increased by one. */
#include <stdio.h>
#include <stddef.h> /* size_t */
/* gets a specific bit of an integer */
#define bitval(c, bit) ((int)(((c) & (1 << (bit))) >> (bit)))
@untodesu
untodesu / packages.txt
Created November 16, 2022 16:38
A Gentleman's Clean-ArchLinux-Install Package Bundle
amd-ucode
base
base-devel
dhcpcd
git
grml-zsh-config
grub
linux
linux-firmware
linux-firmware-qlogic
@untodesu
untodesu / lw.c
Created September 21, 2022 13:52
#include <stdio.h>
#include <string.h>
int main(int argc, char **argv)
{
FILE *ifp = NULL;
FILE *ofp = NULL;
char wrd[40] = { 0 };
char line[256] = { 0 };
@untodesu
untodesu / nig.c
Created September 15, 2022 15:58
#include <ctype.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
struct book_s {
char author[128];
char name[128];
unsigned int year;
unsigned int value;