# HG changeset patch # User deba # Date 1196777307 0 # Node ID 426a4e35e167874377851904cff3f4a108bebe31 # Parent f86f7e4eb2baa221e5062aae61fdbf85d6e474d5 rename graphs script diff -r f86f7e4eb2ba -r 426a4e35e167 scripts/rename-graphs --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/scripts/rename-graphs Tue Dec 04 14:08:27 2007 +0000 @@ -0,0 +1,49 @@ +#!/bin/bash + +ID=$RANDOM + +cat $1 | \ +sed -e "s/bipartite undirected graph/_bigr_aph_label_/g"\ + -e "s/bipartite graph/_bigr_aph_label_/g"\ + -e "s/undirected graph/_gr_aph_label_/g"\ + -e "s/UGraph/_Gr_aph_label_/g"\ + -e "s/ugraph/_gr_aph_label/g"\ + -e "s/BpUgraph/_Bigr_aph_label_/g"\ + -e "s/bpugraph/_bigr_aph_label_/g"\ + -e "s/graph/_digr_aph_label_/g"\ + -e "s/Graph/_Digr_aph_label_/g"\ + -e "s/BpUGraph/_Bigr_aph_label_/g"\ + -e "s/UGraph/_Gr_aph_label_/g"\ + -e "s/_Digr_aph_label_/Digraph/g"\ + -e "s/_digr_aph_label_/digraph/g"\ + -e "s/UEdge/_Ed_ge_label_/g"\ + -e "s/uedge/_ed_ge_label_/g"\ + -e "s/uEdge/_ed_ge_label_/g"\ + -e "s/undirected edge/_ed_ge_label_/g"\ + -e "s/Edge/_Ar_c_label_/g"\ + -e "s/edge/_ar_c_label_/g"\ + -e "s/ANode/_Re_d_label_/g"\ + -e "s/BNode/_Blu_e_label_/g"\ + -e "s/A-Node/_Re_d_label_/g"\ + -e "s/B-Node/_Re_d_label_/g"\ + -e "s/anode/_re_d_label_/g"\ + -e "s/bnode/_blu_e_label_/g"\ + -e "s/aNode/_re_d_label_/g"\ + -e "s/bNode/_blu_e_label_/g"\ + -e "s/_Bigr_aph_label_/Bigraph/g"\ + -e "s/_bigr_aph_label_/bigraph/g"\ + -e "s/_gr_aph_label_/graph/g"\ + -e "s/_Gr_aph_label_/Graph/g"\ + -e "s/_Bigr_aph_label_/Bigraph/g"\ + -e "s/_Gr_aph_label_/Graph/g"\ + -e "s/_Ar_c_label_/Arc/g"\ + -e "s/_ar_c_label_/arc/g"\ + -e "s/_Ed_ge_label_/Edge/g"\ + -e "s/_ed_ge_label_/edge/g"\ + -e "s/_Re_d_label_/Red/g"\ + -e "s/_Blu_e_label_/Blue/g"\ + -e "s/_re_d_label_/red/g"\ + -e "s/_blu_e_label_/blue/g"\ +> rename_graphs_temp_file_$ID.tmp + +mv rename_graphs_temp_file_$ID.tmp $1 \ No newline at end of file