@@ -14,7 +14,7 @@ class SshStudio < Formula
1414 depends_on "gtk4"
1515 depends_on "libadwaita"
1616 depends_on "pygobject3"
17- depends_on "python@3.12 "
17+ depends_on "python@3.13 "
1818
1919 resource "blueprint-compiler" do
2020 url "https://gitlab.gnome.org/GNOME/blueprint-compiler/-/archive/v0.18.0/blueprint-compiler-v0.18.0.tar.gz"
@@ -29,15 +29,15 @@ def install
2929 end
3030 ENV . prepend_path "PATH" , libexec /"bin"
3131
32- ENV [ "PYTHON" ] = Formula [ "python@3.12 " ] . opt_bin /"python3"
32+ ENV [ "PYTHON" ] = Formula [ "python@3.13 " ] . opt_bin /"python3"
3333
34- inreplace "data/ssh-studio.in" , "python3" , "#{ Formula [ "python@3.12 " ] . opt_bin } /python3"
34+ inreplace "data/ssh-studio.in" , "python3" , "#{ Formula [ "python@3.13 " ] . opt_bin } /python3"
3535
3636 system "meson" , "setup" , "build" , *std_meson_args
3737 system "meson" , "compile" , "-C" , "build"
3838 system "meson" , "install" , "-C" , "build"
3939
40- python_version = Formula [ "python@3.12 " ] . version . major_minor
40+ python_version = Formula [ "python@3.13 " ] . version . major_minor
4141 python_site_packages = lib /"python#{ python_version } /site-packages"
4242 python_site_packages . mkpath
4343
@@ -50,6 +50,17 @@ def install
5050 cp_r Dir [ "src/ui/*.py" ] , python_site_packages /"ssh_studio/ui/"
5151 cp_r "src/ui/__init__.py" , python_site_packages /"ssh_studio/ui/"
5252
53+ ( libexec /"bin" ) . mkpath
54+ if ( bin /"ssh-studio" ) . exist?
55+ mv bin /"ssh-studio" , libexec /"bin/ssh-studio"
56+ end
57+ ( bin /"ssh-studio" ) . write <<~SH
58+ #!/bin/bash
59+ export PYTHONPATH="#{ python_site_packages } "
60+ exec "#{ Formula [ "[email protected] " ] . opt_bin } /python3" -m ssh_studio.main "$@" 61+ SH
62+ chmod 0755 , bin /"ssh-studio"
63+
5364 app_root = prefix /"Applications/SSH Studio.app/Contents"
5465 ( app_root /"MacOS" ) . mkpath
5566 ( app_root /"Resources" ) . mkpath
@@ -73,7 +84,8 @@ def install
7384
7485 ( app_root /"MacOS/ssh-studio" ) . write <<~SH
7586 #!/bin/bash
76- exec "#{ Formula [ "[email protected] " ] . opt_bin } /python3" -m ssh_studio.main "$@" 87+ export PYTHONPATH="#{ python_site_packages } "
88+ exec "#{ Formula [ "[email protected] " ] . opt_bin } /python3" -m ssh_studio.main "$@" 7789 SH
7890 chmod 0755 , ( app_root /"MacOS/ssh-studio" )
7991 end
0 commit comments