install.fish 611 B

1234567891011121314151617181920212223242526
  1. #!/usr/bin/fish
  2. if test -z $GD_SHOW_PROJECTS
  3. echo "List your Godot project folder in env var GD_SHOW_PROJECTS (separated by spaces)"
  4. exit 1
  5. end
  6. set SRC_FOLDER ./godot/addons/slide_show
  7. if not test -d $SRC_FOLDER
  8. echo "This script should run in the Git Root folder"
  9. exit 2
  10. end
  11. for f in $GD_SHOW_PROJECTS
  12. echo "install GodotSlideShowPlugin in : $f"
  13. if not test -d $f
  14. echo "directory expected : $f"
  15. exit 3
  16. end
  17. if not test -f $f/project.godot
  18. echo "project.godot expected in : $f"
  19. exit 4
  20. end
  21. mkdir --parents $f/addons/slide_show
  22. rsync --delete --recursive --verbose $SRC_FOLDER $f/addons/
  23. end