This works, but is not ideal
build.gradle.kts
buildscript {
dependencies {
#!/bin/bash | |
set -e | |
# Install OhYourDotfiles | |
cd $HOME | |
git clone https://github.com/DanielThomas/oh-your-dotfiles.git .oh-your-dotfiles | |
ln -s ~/.oh-your-dotfiles/oh-your.zshrc ~/.zshrc |
import groovy.json.JsonSlurper | |
import groovy.transform.Field | |
def json = new JsonSlurper().parse(System.in) | |
if (!(json instanceof Map)) { | |
System.err.println "Input was not json" | |
System.exit 1 | |
} |
# Created by .ignore support plugin (hsz.mobi) | |
### JetBrains template | |
# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio and Webstorm | |
# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839 | |
# User-specific stuff: | |
.idea/**/workspace.xml | |
.idea/**/tasks.xml | |
.idea/dictionaries |
.idea | |
out/ | |
.idea_modules/ | |
*.iml |
# All this comes from https://twitter.com/viktorklang/status/807629003385237504 | |
function restart_audio() { | |
command sudo killall coreaudiod && \ | |
sudo launchctl unload /System/Library/LaunchDaemons/com.apple.audio.coreaudiod.plist && \ | |
sudo launchctl load /System/Library/LaunchDaemons/com.apple.audio.coreaudiod.plist || \ | |
return | |
echo 'Audio daemon restarted' | |
} |
/* | |
This is my solution to https://www.youtube.com/watch?v=LYKn0yUTIU4 | |
Languages are hard. General assumptions: | |
1. What qualifies as a letter is hard to explain in some languages like most indic languages. | |
My definition of what comprises a letter is what takes up on character in UTF encoding. | |
2. Same applies to chinese. In Chinese there's symbols for the every letter that are unicode symbols. | |
That makes chinese almost similar to the decimal number system. | |
Q1. What's the smallest number to form an english sequence of 7? | |
7: [323 (three hundred twenty-three), 23 (twenty-three), 11 (eleven), 6 (six), 3 (three), 5 (five), 4 (four)] |
@Grab('ca.uhn.hapi:hapi-base:2.1') | |
@Grab('ca.uhn.hapi:hapi-structures-v26:2.1') | |
import ca.uhn.hl7v2.DefaultHapiContext | |
import ca.uhn.hl7v2.HapiContext | |
import ca.uhn.hl7v2.app.ConnectionData | |
import ca.uhn.hl7v2.llp.LowerLayerProtocol | |
import ca.uhn.hl7v2.llp.MinLowerLayerProtocol | |
import ca.uhn.hl7v2.validation.builder.support.NoValidationBuilder | |
def cli = new CliBuilder() |
body { | |
font-family: sans-serif; | |
background: #000000; | |
color: #fefefe; | |
font-size: 14px; | |
} | |
div.pipeline-loading-icon { | |
content: url("dark-load.gif"); | |
} |
/** | |
* TypeForm.groovy | |
* | |
* Generates asciidoctor output by analyzing a TypeForm survey | |
* | |
* 1. Setup an environment variable TYPEFORM_KEY from the account page on TypeForm. | |
* 2. Run this script with one arg - the code for your survey, e.g. `cC5Ur1` | |
* 3. Use Asciidoctor output in StdOut to do whatever you need to do. | |
*/ | |
import groovy.json.JsonSlurper |