Skip to content

Instantly share code, notes, and snippets.

View glubo's full-sized avatar

Petr Sýkora glubo

  • Praha, Czech Republic
View GitHub Profile
data class Vertex(
val id: String,
)
data class Edge(
val vertexA: Vertex,
val vertexB: Vertex
) {
val vertices: List<Vertex> = listOf(vertexA, vertexB)
@glubo
glubo / naznak
Created February 18, 2015 12:22
for file in *.jpg; do
if grep $file /tmp/a.txt;then
echo "not moving $file"
else
echo "moving $file"
mv $file to_delete/$file
fi
done
@glubo
glubo / gist:2358361
Created April 11, 2012 10:05 — forked from Majkl578/gist:2304479
Tiny php script to generate simple directory index.
#!/usr/local/bin/php
<?php
/**
* @author Michael Moravec
*/
$targetDir = $argc > 1 ? $argv[1] : getcwd();
if (!is_dir($targetDir)) throw new \InvalidArgumentException("Invalid dir '$targetDir'.");