Skip to content

Instantly share code, notes, and snippets.

View jadsongmatos's full-sized avatar
🏠
Working from home

Jadson G. Matos jadsongmatos

🏠
Working from home
View GitHub Profile
// pages/api/webdav/[[...file]].ts
import type { NextApiRequest, NextApiResponse } from 'next';
import { v2 as webdav } from 'webdav-server';
export const config = {
api: {
// Desabilita o bodyParser para preservar o corpo "cru" da requisição, essencial para WebDAV.
bodyParser: false,
},
};
-- accounts_tags definição
CREATE TABLE "accounts_tags" ("account_id" bigint NOT NULL, "tag_id" bigint NOT NULL, PRIMARY KEY ("tag_id", "account_id"));
CREATE INDEX "index_accounts_tags_on_account_id_and_tag_id" ON "accounts_tags" ("account_id", "tag_id");
-- account_warning_presets definição
CREATE TABLE "account_warning_presets" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "text" text DEFAULT '' NOT NULL, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL, "title" varchar DEFAULT '' NOT NULL);
import copy
import json
from pathlib import Path
from typing import Any, Dict, Optional
def openapi_to_json_schema(
openapi_path: str,
output_path: str,
root_schema_name: Optional[str] = None
) -> None:
version: '3'
services:
stream-recorder:
image: linuxserver/ffmpeg
container_name: icecast_recorder
volumes:
- ./recordings:/config
entrypoint: /bin/sh -c "ionice -c 3 nice -n 19 ffmpeg \
-reconnect 1 -reconnect_at_eof 1 -reconnect_streamed 1 -reconnect_delay_max 5 \
-i https://stm01.virtualcast.com.br:8332/ararangua \
import os
import re
import base64
import hashlib
from bs4 import BeautifulSoup
def salvar_com_hash(conteudo_bytes, pasta_destino, extensao):
"""
Dado o conteúdo em bytes, calcula o hash e salva em `pasta_destino` com
nome <hash>.<extensao>.
#version 300 es
precision highp float;
out vec4 out_color;
in vec2 uv;
uniform float u_time;
uniform vec2 u_resolution;
/* Hash e ruído avançado */
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

SYSTEM DIRECTIVE: AI AGENT HARNESS & LOGICAL DISCIPLINE

CRITICAL INSTRUCTION: This file is intended strictly for the AI coding agent reading this repository. You must read, internalize, and obey these rules for every interaction, task, and code generation within this project. You are operating under a strict logical and technical harness.

1. Simple Apprehension (Capturing the Quiddity)

  • Discover the Essence: Before writing any code or proposing solutions, you must apprehend the "quiddity" (the true essence) of the project's architecture. Use your search tools (rg, read_file, etc.) to capture the eidetic structure of the codebase.
  • Concepts over Names: Distinguish the "name" (the string or identifier) from the "concept" (the mental object and its behavior). Do not assume a function or module does what its name implies without reading its implementation.
  • No Guessing: If a local API or domain rule is unknown to you, you must discover it before proceeding. Your pre-trained knowled