mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: simplify use of case-relative paths
- provide relativePath() for argList and for Time.
These are relative to the case globalPath().
Eg,
Info<< "output: " << runTime.relativePath(outputFile) << nl;
This commit is contained in:
@ -94,7 +94,7 @@ if (doLagrangian)
|
||||
);
|
||||
|
||||
Info<< " Lagrangian: "
|
||||
<< writer.output().relative(runTime.globalPath()) << nl;
|
||||
<< runTime.relativePath(writer.output()) << nl;
|
||||
|
||||
writer.writeTimeValue(mesh.time().value());
|
||||
writer.writeGeometry();
|
||||
|
||||
@ -107,7 +107,7 @@ Description
|
||||
);
|
||||
|
||||
Info<< " Surface : "
|
||||
<< writer.output().relative(runTime.globalPath()) << nl;
|
||||
<< runTime.relativePath(writer.output()) << nl;
|
||||
|
||||
|
||||
writer.writeTimeValue(timeValue);
|
||||
@ -211,7 +211,7 @@ Description
|
||||
);
|
||||
|
||||
Info<< " FaceZone : "
|
||||
<< writer.output().relative(runTime.globalPath()) << nl;
|
||||
<< runTime.relativePath(writer.output()) << nl;
|
||||
|
||||
|
||||
writer.beginFile(fz.name());
|
||||
|
||||
@ -42,7 +42,7 @@ if (faceSetName.size())
|
||||
);
|
||||
|
||||
Info<< " faceSet : "
|
||||
<< outputName.relative(runTime.globalPath()) << nl;
|
||||
<< runTime.relativePath(outputName) << nl;
|
||||
|
||||
vtk::writeFaceSet
|
||||
(
|
||||
@ -70,7 +70,7 @@ if (pointSetName.size())
|
||||
);
|
||||
|
||||
Info<< " pointSet : "
|
||||
<< outputName.relative(runTime.globalPath()) << nl;
|
||||
<< runTime.relativePath(outputName) << nl;
|
||||
|
||||
vtk::writePointSet
|
||||
(
|
||||
|
||||
@ -113,7 +113,7 @@ Description
|
||||
);
|
||||
|
||||
Info<< " Internal : "
|
||||
<< internalWriter->output().relative(runTime.globalPath()) << nl;
|
||||
<< runTime.relativePath(internalWriter->output()) << nl;
|
||||
|
||||
internalWriter->writeTimeValue(mesh.time().value());
|
||||
internalWriter->writeGeometry();
|
||||
@ -163,7 +163,7 @@ Description
|
||||
);
|
||||
|
||||
Info<< " Boundaries: "
|
||||
<< writer->output().relative(runTime.globalPath()) << nl;
|
||||
<< runTime.relativePath(writer->output()) << nl;
|
||||
|
||||
writer->writeTimeValue(timeValue);
|
||||
writer->writeGeometry();
|
||||
@ -229,7 +229,7 @@ Description
|
||||
);
|
||||
|
||||
Info<< " Boundary : "
|
||||
<< writer->output().relative(runTime.globalPath()) << nl;
|
||||
<< runTime.relativePath(writer->output()) << nl;
|
||||
|
||||
writer->writeTimeValue(timeValue);
|
||||
writer->writeGeometry();
|
||||
|
||||
@ -650,7 +650,7 @@ int main(int argc, char *argv[])
|
||||
if (args.found("overwrite") && isDir(regionDir))
|
||||
{
|
||||
Info<< "Removing old directory "
|
||||
<< regionDir.relative(runTime.globalPath())
|
||||
<< runTime.relativePath(regionDir)
|
||||
<< nl << endl;
|
||||
rmDir(regionDir);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user