Submit
Browse
Anonymous
Login
RSS
SuperCollider Code
Fork Code: some missing string operations: split on regex; replace regex; between regex
name
code content
// note: first install quark https://github.com/shimpe/scstringext // using Quarks.install("https://github.com/shimpe/scstringext"); // then you should be be able to run the following examples ( "abcdefabcdef".splitRegex("bcd"); // yields [ "a", "efa", "ef" ] "12-05-1984".replaceRegex("\\d+", "x"); // yields "x-x-x" "12-05-1984".splitRegex("-"); // yields [ "12", "05", "1984" ] "appple".replaceRegex("p+", "pp"); // yields "apple" "<control> a=b <group> c=d <region> e=f <region> g=h <group> <region> i=j".betweenRegex("<group>", "<group>", 0, 1); // yields " c=d <region> e=f <region> g=h " )
code description
some useful string operations which appear to be absent in sclang
use markdown for formating
category tags
comma separated, i.g. "wild, siren" (do not enter default SC class names, please)
ancestor(s)
comma separated identificators, i.g. "1-C,1-1,1-4M,1-x"
Private?
the code will be accessible by direct url and not visible in public activity
signup to submit public code without captcha
comment of change