← Back to team overview

yade-users team mailing list archive

Re: [Question #688690]: pack.SpherePack.save() function saved particles data format

 

Question #688690 on Yade changed:
https://answers.launchpad.net/yade/+question/688690

Jan Stránský proposed the following answer:
> on Windows 10

^M, carriage return, \n\r... is a "windows newline character" (big
quotation marks). Usually it is OK, but sometimes you might meet a
problem.

> what does the '/\r//' mean in your command?

's/\r//'
= replace string between first slashes with string between second slashes
= replace \r with nothing = remove \r (carriage return)

> Which editor can show the carriage return symbols, such as '^M'?

e.g. vim. Open a file and run
:e ++ff=unix
I am sure emacs can do it, too.

> but there is no format error.

it is not an error, just the newline symbols are different. Text editors should have no problem.
But, obviously, SpherePack.load does not count with it.

cheers
Jan

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.