Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PVD collection: Consider full path to vtk instead of just the filename #52

Merged
merged 2 commits into from
Jul 17, 2019

Conversation

sebastianpech
Copy link
Contributor

Implements #51

@@ -20,7 +20,7 @@ function collection_add_timestep(pvd::CollectionFile, datfile::VTKFile,
xroot = root(pvd.xdoc)
xMBDS = find_element(xroot, "Collection")
xDataSet = new_child(xMBDS, "DataSet")
fname = splitdir(datfile.path)[2]
fname = relpath(datfile.path |> abspath ,pvd.path |> abspath |> splitdir |> first)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe

Suggested change
fname = relpath(datfile.path |> abspath ,pvd.path |> abspath |> splitdir |> first)
fname = relpath(abspath(datfile.path), first(splitdir(abspath(pvd.path))))

to follow the style of the rest of the code? :)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perfect, thanks!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also fine. I just like the clean look you get when using |>

Copy link
Contributor

@fredrikekre fredrikekre Jul 17, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just like the clean look you get when using |>

Well, I like the clean look you get when you don't use it :)

@jipolanco jipolanco merged commit f7bfaa4 into JuliaVTK:master Jul 17, 2019
@jipolanco
Copy link
Member

Thanks for the PR!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants