-
Notifications
You must be signed in to change notification settings - Fork 125
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
Mac compatibility: Avoid PCRE grep in recon-surf, stat formatting and mapfile #672
base: dev
Are you sure you want to change the base?
Conversation
Avoid using grep -P, instead use grep -E and some bash instructions.
49dd51c
to
595f3c9
Compare
This works on my Mac. I am getting a print out Also I wonder if we should use this PR to fix the other Mac issues:
|
Let's use this issue for that. The grep issue I was fixing here is a mac-only issue. I will fix the |
Still working on stat |
I tested mapfile changes and it works (also tested --threads 4 for parallel). One other thing, I get the run time only in full hours : Probably due to first output line: |
18a20a7
to
20b009d
Compare
20b009d
to
2db6160
Compare
I still get |
What do you get, if you run |
inside the scripts it uses the system bash, which is this:
in my terminal I have a newer one (5.something) via home-brew, but system bash is still old, and that is the one that gets used via the bash shebang. |
So the difference is that when we call |
it can be different depending on what other bash is installed on the system and in the path. On normal systems, it should be the same. |
…activate the part if it is optional.
…les) into a function in functions. This check uses `stat`, which works in different ways for macOS and linux. Make the function (stat) work for both linux (GNU coreutils) and macOS (unclear version).
use bc -l flag to use fractions as well
2db6160
to
103fef9
Compare
Avoid using grep -P, instead use grep -E and some bash instructions.
This PR addresses #668 and was introduced by #652.
Needs testing to see if grep 2.6 / mac versions of grep on mac support the extended grep syntax.
This PR also addresses 2 more Mac compatibility issues:
mapfile
in run_fastsurfer and brun_fastsurfer (the latter will just not be compatible for some specific flags/arguments)stat
which uses-c
on Linux (GNU coreutils version) and-f
for similar things on macOS (BSD version)