Unification of checks

 - [x] Replace some bash function by their python brother 
 - [x] Unification of some checks between Linux en Mac

As much as possible !