Skip to content
This repository has been archived by the owner on Feb 9, 2023. It is now read-only.

Commit

Permalink
Fix shebangs and permissions
Browse files Browse the repository at this point in the history
The scripts have a mix of no shebang, python and python3 (a relatively
harmless difference). They are also not all executable, which is worse,
as users appear to:

- run the script
- get permission denied
- run the script with sudo
- start superstitiously using sudo
- break the virtualenv by using sudo

cf:
#238 (comment)

Change-Id: I5d53b147f806d2318668d147bfd42f757692380d
  • Loading branch information
drigz committed Jan 25, 2018
1 parent c7c8164 commit ce8bb5f
Show file tree
Hide file tree
Showing 12 changed files with 10 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/examples/vision/annotator.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/usr/bin/env python
#!/usr/bin/env python3
# Copyright 2017 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand Down
2 changes: 1 addition & 1 deletion src/examples/vision/dish_classifier.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/usr/bin/env python
#!/usr/bin/env python3
# Copyright 2017 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand Down
1 change: 1 addition & 0 deletions src/examples/vision/gpiozero/button_example.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#!/usr/bin/env python3
"""Example code that demonstrates using a standard pin along with a hat pin.
The button uses a standard GPIO pin through the raspberry pi's memory mapped io,
Expand Down
1 change: 1 addition & 0 deletions src/examples/vision/gpiozero/hat_button.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#!/usr/bin/env python3
"""Example code that demonstrates using a button connected through the hat.
The button uses a hat pin through the sysfs driver illustrating the edge
Expand Down
1 change: 1 addition & 0 deletions src/examples/vision/gpiozero/led_example.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#!/usr/bin/env python3
"""Demonstrates on board LED support with correct polarity.
Demo will turn on, then off the first LED on the hat.
Expand Down
1 change: 1 addition & 0 deletions src/examples/vision/gpiozero/servo_example.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#!/usr/bin/env python3
"""Demonstrates simultaneous control of two servos on the hat.
One servo uses the simple default configuration, the other servo is tuned to
Expand Down
1 change: 1 addition & 0 deletions src/examples/vision/gpiozero/simple_button_example.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#!/usr/bin/env python3
"""Example code that demonstrates using a standard pin along with a hat pin.
The button uses a standard GPIO pin through the raspberry pi's memory mapped io,
Expand Down
Empty file modified src/examples/vision/image_classification.py
100644 → 100755
Empty file.
1 change: 1 addition & 0 deletions src/examples/vision/leds_example.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#!/usr/bin/env python3
# Copyright 2018 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand Down
2 changes: 1 addition & 1 deletion src/examples/vision/object_detection_camera.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/usr/bin/env python
#!/usr/bin/env python3
# Copyright 2017 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand Down
2 changes: 1 addition & 1 deletion src/examples/vision/object_meter/wordnet_grouping/category_mapper.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/usr/bin/env python
#!/usr/bin/env python3
# Copyright 2018 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#!/usr/bin/env python
# Copyright 2018 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand Down

0 comments on commit ce8bb5f

Please sign in to comment.