forked from mirrors/nixpkgs
* A function for dot animation.
svn path=/nixpkgs/trunk/; revision=3255
This commit is contained in:
parent
9301297f83
commit
6ea37d567f
9
pkgs/misc/tex/nix/animatedot.sh
Normal file
9
pkgs/misc/tex/nix/animatedot.sh
Normal file
|
@ -0,0 +1,9 @@
|
|||
. $stdenv/setup
|
||||
|
||||
ensureDir $out
|
||||
|
||||
for i in $(seq 1 $nrFrames); do
|
||||
echo "producing frame $i...";
|
||||
targetName=$out/$(basename $(stripHash $dotGraph; echo $strippedName) .dot)-f-$i.dot
|
||||
cpp -DFRAME=$i < $dotGraph > $targetName
|
||||
done
|
|
@ -53,5 +53,11 @@ rec {
|
|||
];
|
||||
};
|
||||
|
||||
|
||||
|
||||
animateDot = dotGraph: nrFrames: pkgs.stdenv.mkDerivation {
|
||||
name = "dot-frames";
|
||||
builder = ./animatedot.sh;
|
||||
inherit dotGraph nrFrames;
|
||||
};
|
||||
|
||||
}
|
Loading…
Reference in a new issue