mirror of
https://github.com/elephantrobotics/mycobot_ros.git
synced 2026-07-14 09:00:53 +00:00
Gracefully handle cases when uname ends with a carriage return.
This commit is contained in:
parent
0ff71e7d2e
commit
4d958721ab
1 changed files with 1 additions and 1 deletions
2
test.py
2
test.py
|
|
@ -12,7 +12,7 @@ from pymycobot.genre import Angle, Coord
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
sys_ = subprocess.check_output(["uname"], shell=True).decode()
|
sys_ = subprocess.check_output(["uname"], shell=True).decode()
|
||||||
if not sys_ == "Linux":
|
if not sys_.startswith("Linux"):
|
||||||
print("This script just can run on Linux.")
|
print("This script just can run on Linux.")
|
||||||
exit(0)
|
exit(0)
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue