This file contains 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
on run {input, parameters} | |
(* A když se jako další akce přidá provedení tohoto AppleScriptu | |
vyskočí nám zROT13ovaný vstup jako upozornění. *) | |
display dialog input as text buttons {"OK"} | |
return input | |
end run |
This file contains 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
cs: | |
number: | |
format: | |
separator: ',' | |
delimiter: ' ' | |
precision: 2 | |
date: | |
input: | |
formats: | |
- :default |
This file contains 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
// Vyskloňuje slovo hezky česky buď podle staršího, | |
// méně benevoletního a méně prasáckého paradigmatu: | |
// 1 položka, 2 položky, 5 položek, 10 položek, | |
// 15 položek, 20 položek, 21 položka, 22 položky | |
// 25 položek, 100 položek, 101 položka… | |
// nebo podle nového, čuňáckého: | |
// 1 položka, 2 položky, 5 položek, 10 položek, | |
// 15 položek, 20 položek, 21 položek, 22 položek | |
// 25 položek, 100 položek, 101 položek… | |
// |
This file contains 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/ruby | |
=begin | |
Easy quiz/trivia mystery-cache solver. Takes possible | |
answers to questions and instructions how to transform | |
the indices into coordinates. Brute-force is used to | |
check all possible combinations that produce meaningful | |
coordinates. Returns a set of waypoins in KML format. | |
The values here are real for a specific Geocache. |
This file contains 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/php | |
<?php | |
# Demo script of a bug #66137 (https://bugs.php.net/bug.php?id=66173) | |
# Converting an object with properties that have numeric names results | |
# in having an array with inaccessible keys. | |
$ary = []; | |
$ary["0"] = 'string'; | |
var_dump($ary); |
This file contains 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/sh | |
# Checkouts the repository into the webserver application folder. | |
# Inspired by http://www.sitepoint.com/one-click-app-deployment-server-side-git-hooks/ by Matthew Setter. | |
# The script assumes that the bare repository directory name (somename.git) is same as the deployment | |
# directory name, just without the .git extension (somename). The destination path (htdocs) needs to be | |
# changed according to your environment (line 14, DEPLOYPATH variable). | |
read OLDREV NEWREV REFNAME | |
CURRENTDIR=`pwd | grep -o [^/]\\\\+$` |
This file contains 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
(* | |
The zero_pad function taken from: | |
http://www.nineboxes.net/2009/10/an-applescript-function-to-zero-pad-integers/ | |
*) | |
on zero_pad(value, string_length) | |
set string_zeroes to "" | |
set digits_to_pad to string_length - (length of (value as string)) | |
if digits_to_pad > 0 then | |
repeat digits_to_pad times | |
set string_zeroes to string_zeroes & "0" as string |
This file contains 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/sh | |
# Won’t work if a branch called _squash_patch_tmp already exists. | |
# And probably many other caveats? | |
REFS_NAMED_HEAD=`git show-ref --heads --tags | grep "^[0-9a-f]\{40\} refs/\(heads\|tags\)/HEAD$"`; | |
if [ "$REFS_NAMED_HEAD" ]; then | |
echo "HEAD is ambiguous."; | |
exit 2 | |
fi |
This file contains 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/sh | |
# Takes changes done in a branch that was already merged into another and | |
# incorporates them into the already existing merge commit. Leaves in a | |
# detached HEAD state, the current HEAD being the patched original commit. | |
# If the patch cannot be applied cleanly, it is saved into ./patch. | |
if [ -z $1 -o -z $2 ] | |
then |
This file contains 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/sh | |
if [ $1 = "-f" ] | |
then | |
FORCE="$1" | |
TRAILING_PATTERN="$2" | |
else | |
FORCE="" | |
TRAILING_PATTERN="$1" | |
fi |
OlderNewer