mirror of
https://github.com/blondie7575/GSCats.git
synced 2024-11-25 10:30:49 +00:00
36 lines
458 B
Bash
Executable File
36 lines
458 B
Bash
Executable File
#!/usr/bin/env awk -f
|
|
BEGIN {
|
|
FS="\t";
|
|
print "; Autogenerated by Mr. Sprite. Do not modify\n\n"
|
|
}
|
|
{
|
|
if ($2 == "DA")
|
|
{
|
|
$2 = ".addr"
|
|
}
|
|
else if ($2 == "HEX")
|
|
{
|
|
$2 = ".dbyt"
|
|
$3 = "$" $3
|
|
gsub(/,/,",$",$3)
|
|
}
|
|
}
|
|
{
|
|
if ($1 != "")
|
|
{
|
|
first = substr($1,0,1);
|
|
if (first == "*")
|
|
{
|
|
print ";----------","\t",$2,"\t",$3,"\t",$4;
|
|
}
|
|
else
|
|
{
|
|
print $1,":\n","\t",$2,"\t",$3,"\t",$4;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
print "\t",$1,"\t",$2,"\t",$3,"\t",$4;
|
|
}
|
|
}
|