# How to point the ParaView state file to the local directory

Automating the visualization in ParaView can be done by saving ParaView “state” files, but they will include absolute paths to the data.

### Step-by-step guide

1. Save the bash code snippet into a script.
2. Call the script with the paraview state file as an argument.
#!/usr/bin/bash

sed -i "s/${PWD//\//\\\/}/\.\//g"$


The changed state file (\$1 argument) of the script, will now have “./” wherever the full path to the working directory was originally placed by ParaView.