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
Utils.extend(feed, { | |
title: 'google++', | |
author: { | |
name: 'satyr', email: 'murky.satyr\x40gmail.com', | |
homepage: 'http://satyr.github.com', | |
}, | |
license: 'X', | |
}) | |
const | |
Google = 'https://www.google.com/', |
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
alert("test2"); |
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
const Name = 'yats', | |
Yats = 'http://pcod.no-ip.org/yats/', | |
Base = ''+ <div class={Name}><base href={Yats}/><style><![CDATA[ | |
h2 {margin:0; padding:0} | |
img {width:16px; height:16px; border:none} | |
ol {margin:2px 0; padding:0} | |
li {float:left; clear:left; width:100%; padding:0 0 4px 0} | |
li div {float:left; padding-right:2px} | |
h2, p {clear:left; font-size:84%} | |
kbd {text-decoration:underline; vertical-align:top} |
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
String fun(String fpath, List mods, Closure sorter){ | |
def r = new File(fpath).text.trim().split(/\r?\n/)*.tokenize('\t') | |
mods.each{ r.(it.maximumNumberOfParameters==2?'eachWithIndex':'each') it } | |
[r.head(), *r.tail().sort(sorter)]*.join('\t').join('\n') | |
} | |
print fun('data.csv', [ | |
{ it[0..3] = it[0, 2, 1, 3] }, | |
{ a, i -> if(i){ [0, 3].each{ a[it] = a[it].toInteger() }; ++a[3] } }, | |
]){ it[0] } |
NewerOlder