This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package remote | |
import cats.effect.* | |
import cats.syntax.all.* | |
import fs2.dom.* | |
import calico.* | |
import calico.html.io.{*, given} | |
import fs2.concurrent.* | |
import fs2.* |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env stack | |
{- stack script --resolver lts-10.1 --install-ghc | |
--package <package dependency 1> | |
--package <package dependency 2> | |
-} | |
main :: IO () | |
main = do | |
putStrLn "Hello" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE FUNCTION fixUtf8Chars(str TEXT) RETURNS TEXT | |
BEGIN | |
SET str = REPLACE(str, CHAR(0xC383C2A9), CHAR(0xC3A9)); -- é | |
SET str = REPLACE(str, CHAR(0xC383C289), CHAR(0xC389)); -- É | |
SET str = REPLACE(str, CHAR(0xC383C2A8), CHAR(0xC3A8)); -- è | |
SET str = REPLACE(str, CHAR(0xC383C288), CHAR(0xC388)); -- È | |
SET str = REPLACE(str, CHAR(0xC383C2AA), CHAR(0xC3AA)); -- ê | |
SET str = REPLACE(str, CHAR(0xC383C28A), CHAR(0xC38A)); -- Ê | |
SET str = REPLACE(str, CHAR(0xC384C296), CHAR(0xC496)); -- Ė | |
SET str = REPLACE(str, CHAR(0xC384C297), CHAR(0xC497)); -- ė |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/usr/python | |
# This script converts images to lower resolutions for android and ios. | |
# It assumes the image is in 4x/xxxhdpi | |
# Requires imagemagick. | |
import subprocess | |
import sys | |
import os |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function base64url_encode($data) { | |
if (!mb_check_encoding($data, "ASCII")) | |
throw new InvalidArgumentException("Arguments can only contain ASCII characters."); | |
return rtrim(strtr(base64_encode($data), '+/', '-_'), '='); | |
} |