Skip to content

Instantly share code, notes, and snippets.

# frozen_string_literal: true
require "sevgi/sundries/printer"
module Sevgi
module Graphics
module Mixtures
module Print
EXT = ".svg"
#!/usr/bin/env bash
declare -gr ROOT=~/Dropbox/src/strokes
alef() {
local P
echo >&2 "alef"
for P in g i; do
@roktas
roktas / base.sevgi
Last active February 14, 2026 15:13
Old Strokes base
# frozen_string_literal: true
module Base
module Header
def call(page)
n = 3
width = page.grid.width / n.to_f
rect id: "Header-Cell-Left", x: 0, y: 0, width:, height: 9, class: %w[ header ]
rect id: "Header-Cell-Center", x: width, y: 0, width:, height: 9, class: %w[ header ]

Sözdizimi

  • Sorular bir soru bir dosya olabileceği gibi, bir dosyada birden fazla soru olabilir

  • Dosyada sorular === ile ayrılır

  • Grup sorularında alt sorular --- ile ayrılır

  • Şıklar A) şeklinde

@roktas
roktas / bisac.csv
Created August 25, 2025 07:58 — forked from pgaskin/bisac.csv
Code Description Comment
Complete BISAC Subject Headings List, 2021 Edition Generated on 2022-02-03T17:00:35.308Z from https://bisg.org/page/BISACEdition
ANT000000 Antiques & Collectibles / General
ANT056000 Antiques & Collectibles / Advertising
ANT001000 Antiques & Collectibles / Americana
ANT002000 Antiques & Collectibles / Art
ANT003000 Antiques & Collectibles / Autographs
ANT005000 Antiques & Collectibles / Books
ANT006000 Antiques & Collectibles / Bottles
ANT007000 Antiques & Collectibles / Buttons & Pins
#!/usr/bin/env -S ruby -S sevgi
SVG :inkscape, Sevgi::Graphics::Canvas.new(width: 150, height: 30) do
rect x: 0, y: 0, width: 150, height: 30, stroke: "none", fill: "maroon"
text "TEXT", x: "50%", y: "50%", "dominant-baseline": "middle", "text-anchor": "middle", fill: "white"
end.Out
@roktas
roktas / gotcha.sh
Created January 27, 2025 06:38
Shell gothcas
#!/bin/bash
set -eu
foo() {
false
echo Expected to not reach here
}
fooer=foo
@roktas
roktas / topla.txt
Created October 8, 2024 07:07
Topla
başla get klavyeden bir sayı al
ifzero duyur eğer sayı sıfır ise "göster"e git
add toplam aküdeki yeni sayıyı mevcut toplama ekle
store toplam sonucu yin toplam hücresine kaydet
goto başla yeni sayıyı almak için "başla"ya git
duyur load toplam toplamı aküye yükle
print sonucu duyur
stop işlem tamam
toplam 0 "toplam" hücresinin ilk değeri 0 (program başlamadan önce)