#!/bin/bash

# file containing field definition:
init='xshells_init.cpp'

echo "Definition of these fields can be found in file '$init'"

### list available fields

cat $init |grep -e "^BEGIN_FIELD" -e "int init_" | sed -e "s/int init_U0.*/\nVelocity fields (use from xshells.par with 'u = field_name'):/g" -e "s/int init_B0.*/\nMagnetic fields (use from xshells.par with 'b = field_name'):/g" -e "s/int init_T0.*/\nTemperature fields (use from xshells.par with 'tp0 = field_name' or 'tp = field_name'):/g" -e "s/int init_Phi0.*/\nGravity fields (use from xshells.par with 'phi0 = field_name'):/g" -e "s/BEGIN_FIELD(//g" -e "s/\", \"/ : \t /g" -e "s/\"//g" -e "s/)$//g"

