diff --git a/pkg/mac/build.sh b/pkg/mac/build.sh index 5f29636a497..4cadd38bb72 100755 --- a/pkg/mac/build.sh +++ b/pkg/mac/build.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # Build script to create Mac App Bundle and DMG for pgAdmin4 runtime diff --git a/pkg/pip/build.sh b/pkg/pip/build.sh index ff5a3cabf00..84f21209bd0 100755 --- a/pkg/pip/build.sh +++ b/pkg/pip/build.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash ######################################################################## # diff --git a/pkg/src/build.sh b/pkg/src/build.sh index cb4c931bb1b..09508b90b57 100755 --- a/pkg/src/build.sh +++ b/pkg/src/build.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash ######################################################################## # diff --git a/web/pgAdmin4.py b/web/pgAdmin4.py index 32584cf687a..adc7b7257b7 100644 --- a/web/pgAdmin4.py +++ b/web/pgAdmin4.py @@ -10,6 +10,7 @@ """This is the main application entry point for pgAdmin 4. If running on a webserver, this will provide the WSGI interface, otherwise, we're going to start a web server.""" + import sys if sys.version_info <= (3, 9): @@ -21,6 +22,9 @@ import builtins import os +## +import webbrowser + # We need to include the root directory in sys.path to ensure that we can # find everything we need when running in the standalone runtime. if sys.path[0] != os.path.dirname(os.path.realpath(__file__)): @@ -173,6 +177,7 @@ def main(): config.EFFECTIVE_SERVER_PORT) ) sys.stdout.flush() + webbrowser.open(f"http://{config.DEFAULT_SERVER}:{config.EFFECTIVE_SERVER_PORT}") else: # For unknown reason the runtime does not pass the environment # variables (i.e. PYTHONHOME, and PYTHONPATH), to the Python