From b375bd8d7eae79089f28259ae3478acac9831bbc Mon Sep 17 00:00:00 2001 From: AJ ONeal Date: Sat, 12 Oct 2024 02:21:15 +0000 Subject: [PATCH] feat(psql): add aliases --- postgres-client/README.md | 11 +++++++++++ postgres-client/install.sh | 12 ++++++++++++ postgresql-client/README.md | 11 +++++++++++ postgresql-client/install.sh | 12 ++++++++++++ 4 files changed, 46 insertions(+) create mode 100644 postgres-client/README.md create mode 100644 postgres-client/install.sh create mode 100644 postgresql-client/README.md create mode 100644 postgresql-client/install.sh diff --git a/postgres-client/README.md b/postgres-client/README.md new file mode 100644 index 0000000..0669719 --- /dev/null +++ b/postgres-client/README.md @@ -0,0 +1,11 @@ +--- +title: Postgres Client (PSQL alias) +homepage: https://webinstall.dev/psql +tagline: | + Alias for https://webinstall.dev/psql +alias: psql +description: | + See https://webinstall.dev/psql +--- + +Alias for https://webinstall.dev/psql diff --git a/postgres-client/install.sh b/postgres-client/install.sh new file mode 100644 index 0000000..016a48a --- /dev/null +++ b/postgres-client/install.sh @@ -0,0 +1,12 @@ +#!/bin/sh +set -e +set -u + +__redirect_alias_psql() { + echo "'postgres-client' is an alias for 'psql'" + sleep 2.5 + WEBI_HOST=${WEBI_HOST:-"https://webi.sh"} + curl -fsSL "$WEBI_HOST/psql@${WEBI_VERSION-}" | sh +} + +__redirect_alias_psql diff --git a/postgresql-client/README.md b/postgresql-client/README.md new file mode 100644 index 0000000..2b53d1a --- /dev/null +++ b/postgresql-client/README.md @@ -0,0 +1,11 @@ +--- +title: PostgreSQL Client (PSQL alias) +homepage: https://webinstall.dev/psql +tagline: | + Alias for https://webinstall.dev/psql +alias: psql +description: | + See https://webinstall.dev/psql +--- + +Alias for https://webinstall.dev/psql diff --git a/postgresql-client/install.sh b/postgresql-client/install.sh new file mode 100644 index 0000000..6087800 --- /dev/null +++ b/postgresql-client/install.sh @@ -0,0 +1,12 @@ +#!/bin/sh +set -e +set -u + +__redirect_alias_psql() { + echo "'postgresql-client' is an alias for 'psql'" + sleep 2.5 + WEBI_HOST=${WEBI_HOST:-"https://webi.sh"} + curl -fsSL "$WEBI_HOST/psql@${WEBI_VERSION-}" | sh +} + +__redirect_alias_psql