From 66f5d2d8deecd381fc6d9aee130609e7bed8c7fb Mon Sep 17 00:00:00 2001 From: "Rodrigo Rodriguez (Pragmatismo)" Date: Mon, 20 Oct 2025 07:50:51 -0300 Subject: [PATCH] Update PostgreSQL installer commands Add build command before running cargo Update PostgreSQL installation commands to use relative paths Update Linux and macOS installation commands to use `chmod +x ./bin/*` instead of `chmod +x bin/*` --- gbot.sh | 2 +- src/package_manager/installer.rs | 6 ++---- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/gbot.sh b/gbot.sh index 544aaf5a..681f60a0 100755 --- a/gbot.sh +++ b/gbot.sh @@ -1,2 +1,2 @@ clear && \ - RUST_LOG=trace cargo run + RUST_LOG=trace,hyper_util=off cargo build && clear && cargo run diff --git a/src/package_manager/installer.rs b/src/package_manager/installer.rs index f5d913d1..04a85699 100644 --- a/src/package_manager/installer.rs +++ b/src/package_manager/installer.rs @@ -138,8 +138,7 @@ impl PackageManager { binary_name: None, pre_install_cmds_linux: vec![], post_install_cmds_linux: vec![ - "tar -xzf postgresql-18.0.0-x86_64-unknown-linux-gnu.tar.gz --strip-components=1".to_string(), - "chmod +x bin/*".to_string(), + "chmod +x ./bin/*".to_string(), "if [ ! -d \"{{DATA_PATH}}/pgdata\" ]; then ./bin/initdb -D {{DATA_PATH}}/pgdata -U postgres; fi".to_string(), "if [ ! -f \"{{CONF_PATH}}/postgresql.conf\" ]; then echo \"data_directory = '{{DATA_PATH}}/pgdata'\" > {{CONF_PATH}}/postgresql.conf; fi".to_string(), "if [ ! -f \"{{CONF_PATH}}/postgresql.conf\" ]; then echo \"hba_file = '{{CONF_PATH}}/pg_hba.conf'\" >> {{CONF_PATH}}/postgresql.conf; fi".to_string(), @@ -154,8 +153,7 @@ impl PackageManager { ], pre_install_cmds_macos: vec![], post_install_cmds_macos: vec![ - "tar -xzf postgresql-18.0.0-x86_64-unknown-linux-gnu.tar.gz --strip-components=1".to_string(), - "chmod +x bin/*".to_string(), + "chmod +x ./bin/*".to_string(), "if [ ! -d \"{{DATA_PATH}}/pgdata\" ]; then ./bin/initdb -D {{DATA_PATH}}/pgdata -U postgres; fi".to_string(), ], pre_install_cmds_windows: vec![],