Tutti Nuovi

user:thomas utente che ha creato il gist

title:mygist titolo del gist

filename:myfile.txt nome di file nel gist

extension:yml estensione del file nel gist

language:go linguaggio del file nel gist

topic:homelab gists with given topic

Registrati

Entra


Tutti Nuovi Registrati Entra
's Avatar

capitalex

Unito 2 years ago

Più recente creazione
Meno recente creazione
Più recente aggiornamento
Meno recente aggiornamento
Tutti i gists 147 Forkati 1
capitalex's Avatar

capitalex / ribbons.ml

0 mi piace
0 forks
1 files
Ultima volta attivo 2 months ago
1 type open_ribbon = [`Open of int]
2 type looped_ribbon = [`Looped]
3 type ribbon =
4 [
5 | `Open of int
6 | `Looped
7 ]
8
9 let tie a b : ribbon =
10 match a, b with
capitalex's Avatar

capitalex / snarl.factor

0 mi piace
0 forks
1 files
Ultima volta attivo 2 months ago
1 ! Copyright (C) 2023 and Null
2 ! This mine and only mine all rights reserved >:3c
3 USING: accessors assocs assocs.extras combinators
4 combinators.short-circuit command-line continuations debugger
5 html.elements io io.directories io.encodings.utf8 io.files
6 io.files.info io.pathnames io.streams.string kernel literals
7 namespaces sbufs sequences sequences.deep sets sorting splitting
8 strings unicode xml xml.data xml.state xml.traversal xml.writer
9 ;
10 FROM: namespaces => set ;
capitalex's Avatar

capitalex / joyful.ml

0 mi piace
0 forks
1 files
Ultima volta attivo 2 months ago
1 (*
2 1 2 + print-int
3 *)
4
5 let rec skip_whitespace chars =
6 let open Seq in
7 match chars () with
8 | Cons (' ', rest) | Cons ('\t', rest) | Cons ('\n', rest) ->
9 skip_whitespace rest
10 | _ ->
capitalex's Avatar

capitalex / properties.ml

0 mi piace
0 forks
1 files
Ultima volta attivo 2 months ago
1 module Univ = struct
2 type t = ..
3 let id =
4 let id = ref 0 in
5 fun () ->
6 incr id ;
7 !id
8
9 module Embed (M : sig type t end) = struct
10 type t += E of M.t
capitalex's Avatar

capitalex / simple-object.lua

0 mi piace
0 forks
1 files
Ultima volta attivo 2 months ago
1 return function(animation, x, y)
2 local object = {
3 x = x
4 , y = y
5 , frame = 0
6 , animation = animation
7 , grabbed = false
8 }
9 function object:draw()
10 if mouseIsPressed and not taken and self:contains(mouseX, mouseY) and not self.grabbed then
capitalex's Avatar

capitalex / andpile

0 mi piace
0 forks
1 files
Ultima volta attivo 2 months ago
1 #!/usr/bin/env bash
2
3 if [[ ! -d "$HOME/.andpile" ]]; then
4 mkdir "$HOME/.andpile" ;
5 mkdir "$HOME/.andpile/data" ;
6 touch "$HOME/.andpile/feeds.txt" ;
7 fi
8
9 remove_feed() {
10 sed -i.back "$(($1 + 1))d" "$HOME/.andpile/feeds.txt" ;
capitalex's Avatar

capitalex / cat.cr

0 mi piace
0 forks
1 files
Ultima volta attivo 2 months ago
1 macro concat(*values)
2 {% top = -1 %}
3 {% for value, i in values %}
4 {% if value.is_a? ProcLiteral %}
5 {% new_top = top - value.args.size + 1 %}
6 %var{new_top} = {{value}}.call({% for arg, j in value.args %}
7 %var{top - (value.args.size - j - 1)},
8 {% end %})
9 {% top = new_top %}
10 {% elsif value.is_a? Call %}
capitalex's Avatar

capitalex / Calculator

0 mi piace
0 forks
1 files
Ultima volta attivo 2 months ago
Calculator implementing Bogue
1 open Bogue
2
3 module W = Widget
4 module L = Layout
5
6
7 let calculator () =
8 let stack = Stack.create () in
9 Stack.push "0" stack ;
capitalex's Avatar

capitalex / gol.ocaml

0 mi piace
0 forks
1 files
Ultima volta attivo 2 months ago
1 Random.self_init ()
2
3 type cell = Dead | Alive
4 let cell_to_string = function
5 | Alive -> "#"
6 | Dead -> "_"
7
8 let cell_to_int = function
9 | Alive -> 1
10 | Dead -> 0
capitalex's Avatar

capitalex / scheming.squirm

0 mi piace
0 forks
1 files
Ultima volta attivo 2 months ago
1 <quick ~color ~animalA jumps over the lazy ~animalB> {
2 How rude says !animalB to the quick !color !animalA
3 }
4
5 ~animalB {
6 lazy ~ {
7 $stash the ~ {
8 $stash over ~ {
9 $stash jump ~ {
10 $stash ~animalA {
Più nuovi Più vecchi

Creato da Opengist ⋅ Load: 189ms⋅

Italiano
Čeština Deutsch English Español Français Magyar Italiano 日本語 Polski Português Русский Türkçe Українська 中文 繁體中文