Ripped from http://www.openscad.org/cheatsheet/index.html
var = value;
module name(…) { … }
name();
function name(…) = …
name();
;; depends on [org.imgscalr/imgscalr-lib "4.2"] | |
(ns XXX.image | |
(:refer-clojure :exclude [read]) | |
(:require [clojure.java.io :as io]) | |
(:import [org.imgscalr Scalr Scalr$Method Scalr$Mode] | |
[java.awt Image] | |
[java.awt.image RenderedImage BufferedImageOp] | |
[javax.imageio ImageIO ImageWriter ImageWriteParam IIOImage] |
#!/bin/bash | |
FILE_PATH=somefile.txt | |
function appendToFile { | |
echo $@ >> $FILE_PATH | |
} | |
function checkBeforeAppend { | |
(cat $FILE_PATH | grep "$@" && echo "$@ already set") || appendToFile "$@" | |
} |
<!DOCTYPE html> | |
<html prefix="og: http://ogp.me/ns# "> | |
<head><script data-cfasync='false' data-pagespeed-no-defer>var __ez=__ez||{};__ez.evt={};__ez.ck={};__ez.dot={};__ez.template={};__ez.template.isOrig=false;__ez.evt.add=function(e,t,n){e.addEventListener?e.addEventListener(t,n,!1):e.attachEvent?e.attachEvent("on"+t,n):e["on"+t]=n()},__ez.evt.remove=function(e,t,n){e.removeEventListener?e.removeEventListener(t,n,!1):e.detachEvent?e.detachEvent("on"+t,n):delete e["on"+t]};__ez.ck.get=function(e,n){null!==n&&(e=e+"_"+n);for(var o=e+"=",t=decodeURIComponent(document.cookie).split(";"),i=0;i<t.length;i++){for(var c=t[i];" "===c.charAt(0);)c=c.substring(1);if(0===c.indexOf(o))return c.substring(o.length,c.length)}return""},__ez.ck.setByCat=function(e,n){if("undefined"!=typeof cmpIsOn){if(null!=n){var o=__ez.ck.get("ezCMPCookieConsent",null);-1!==(o=o.substring(1,o.length)).indexOf(n+"=1")?document.cookie=e:""===o&&"undefined"!=typeof cmpCookies&&(void 0===cmpCookies[n]&&(cmpCookies[n]=[]),cmpCookies[n].push(e)) |
#!/bin/bash | |
# Use "xev" to find the correct keycodes | |
# For unusual items, you may need to look in /usr/include/X11/keysymdef.h (then remove the leading "XK_" when editing your script | |
# xkbset and xev are probably not installed by default but should be in your distro's repositories | |
# Pointer_Button1 = left click, Pointer_Button2 = middle click; Pointer_Button3 = right click | |
sudo apt install -y xkbset | |
xkbset m | |
#xmodmap -e "keysym Super_L = Mode_switch" | |
#xmodmap -e "keycode 31 = Up Up" |
Ripped from http://www.openscad.org/cheatsheet/index.html
var = value;
module name(…) { … }
name();
function name(…) = …
name();
This is the correct string. |
<?php | |
$fileName = "fun.xml"; | |
$keystorepath = "this/is/a/path.jks"; | |
$keystorepassword = "keystorepassword"; | |
$fileContents = file_get_contents($fileName); | |
$xml = simplexml_load_string($fileContents); |
/*! normalize.css v5.0.0 | MIT License | github.com/necolas/normalize.css */ | |
/** | |
* 1. Change the default font family in all browsers (opinionated). | |
* 2. Correct the line height in all browsers. | |
* 3. Prevent adjustments of font size after orientation changes in | |
* IE on Windows Phone and in iOS. | |
*/ | |
/* Document |
programname=$0 | |
function usage { | |
echo "usage: $programname [-abch] [-f infile] [-o outfile]" | |
echo " -a turn on feature a" | |
echo " -b turn on feature b" | |
echo " -c turn on feature c" | |
echo " -h display help" | |
echo " -f infile specify input file infile" | |
echo " -o outfile specify output file outfile" | |
exit 1 |
variable=`echo $LOWER | awk '{print toupper($0)}'` |