Skip to content

Commit f54d81e

Browse files
author
Richard Siomporas
committed
Updated scripts and docker file, going to test build
1 parent 1a182cf commit f54d81e

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ COPY utilities/runcommand-onstart.sh /opt/retropie/configs/all/runcommand-onstar
5454
RUN chmod +x /opt/retropie/configs/all/runcommand-onstart.sh
5555

5656
# Edit this file in your persistent storage to use all or part of the name provided from "lsusb" to reset the controller on each start
57-
RUN touch /opt/retropie/configs/all/controller_names && chown pi:pi /opt/retropie/configs/all/controller_names
57+
RUN touch /opt/retropie/configs/all/controller_usb_ids && chown pi:pi /opt/retropie/configs/all/controller_usb_ids
5858

5959
# and Installs RetroPie + optional modules declared in install.sh
6060
COPY --chown=pi install_retropie_addons.sh /tmp/install_retropie_addons.sh

utilities/copy_scripts.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
#!/bin/bash
2-
cp ~/Projects/retropie-container/runcommand-onstart.sh ~/.config/retropie-container/configs/all/runcommand-onstart.sh && chmod +x ~/.config/retropie-container/configs/all/runcommand-onstart.sh
3-
cp ~/Projects/retropie-container/reset_controller.py ~/.config/retropie-container/configs/all/reset_controller.py && chmod +x ~/.config/retropie-container/configs/all/reset_controller.py
4-
cp ~/Projects/retropie-container/reset_controller.sh ~/.config/retropie-container/configs/all/reset_controller.sh && chmod +x ~/.config/retropie-container/configs/all/reset_controller.sh
2+
cp runcommand-onstart.sh ~/.config/retropie-container/configs/all/runcommand-onstart.sh && chmod +x ~/.config/retropie-container/configs/all/runcommand-onstart.sh
3+
cp reset_controller.py ~/.config/retropie-container/configs/all/reset_controller.py && chmod +x ~/.config/retropie-container/configs/all/reset_controller.py
4+
cp reset_controller.sh ~/.config/retropie-container/configs/all/reset_controller.sh && chmod +x ~/.config/retropie-container/configs/all/reset_controller.sh

utilities/reset_controller.sh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,12 @@ done
66

77
sleep 3
88

9-
declare -a controller_names
10-
readarray controller_names < /opt/retropie/configs/all/controller_names
9+
declare -a controller_usb_ids
10+
readarray controller_usb_ids < /opt/retropie/configs/all/controller_usb_ids
1111

1212
let i=0
13-
while (( ${#controller_names[@]} > i )); do
14-
controller="${controller_names[i++]}"
13+
while (( ${#controller_usb_ids[@]} > i )); do
14+
controller="${controller_usb_ids[i++]}"
1515
sudo /opt/retropie/configs/all/reset_controller.py "$controller"
1616
sleep 1
1717
sudo /opt/retropie/configs/all/reset_controller.py "$controller"

0 commit comments

Comments
 (0)