CLICK ME
yes, even hidden code blocks!
print("hello world!")| { | |
| inputs = { | |
| nixpkgs.url = "github:NixOS/nixpkgs/release-23.05"; | |
| }; | |
| outputs = { self, nixpkgs }: | |
| with nixpkgs.legacyPackages.x86_64-linux; | |
| let | |
| system = "x86_64-linux"; |
| import scala.collection.{immutable, mutable, GenTraversableOnce} | |
| import scala.collection.generic.CanBuildFrom | |
| object GroupableOps { | |
| implicit class ToGroupable[A, Coll[X] <: GenTraversableOnce[X]](coll: Coll[A]) { | |
| // https://github.com/scala/scala/blob/v2.13.0-M5/src/library/scala/collection/Iterable.scala#L578 | |
| def groupMap[K, B, To](key: A => K)(f: A => B) | |
| (implicit bf: CanBuildFrom[Coll[A], B, To]): immutable.Map[K, To] = { |
| let g:ctrlp_map = '' | |
| function! CtrlP() | |
| if (getcwd() == $HOME) | |
| echo "Won't run in ~" | |
| return | |
| endif | |
| if (getcwd() == '/') | |
| echo "Won't run in /" | |
| return |
| { stdenv, fetchurl }: | |
| let | |
| fetchfont = name: num: sha: | |
| fetchurl { | |
| url = "https://fontsup.com/download/${builtins.toString num}.html"; | |
| sha256 = sha; | |
| name = "${name}"; | |
| }; | |
| in stdenv.mkDerivation rec { |
| #include <stdio.h> | |
| #include <stdint.h> | |
| #define MAX 100 | |
| int | |
| main(int argc, char **argv) | |
| { | |
| intptr_t op[MAX + 2]; | |
| int ip; |
| // return array of [r,g,b,a] from any valid color. if failed returns undefined | |
| function colorValues(color) | |
| { | |
| if (!color) | |
| return; | |
| if (color.toLowerCase() === 'transparent') | |
| return [0, 0, 0, 0]; | |
| if (color[0] === '#') | |
| { | |
| if (color.length < 7) |
| #!/usr/bin/env stack | |
| -- stack -v runghc --package connection --package http-client --package http-client-tls --package tls --package data-default | |
| {-# LANGUAGE OverloadedStrings #-} | |
| {-# LANGUAGE ViewPatterns #-} | |
| {-# OPTIONS_GHC -fno-warn-deprecations #-} | |
| import qualified Network.Connection as NC | |
| import qualified Network.HTTP.Client as Http | |
| import qualified Network.HTTP.Client.TLS as Http | |
| import qualified Network.TLS as TLS |
| package clusterserver | |
| import akka.actor._ | |
| class Logger extends Actor with ActorLogging { | |
| log.info("Logger started!") | |
| def receive = { | |
| case msg => log.info("Got msg: {}", msg) | |
| } |