From ee0c1ea32c170c6ac416544146cfc6d6468384e1 Mon Sep 17 00:00:00 2001 From: rzmk <30333942+rzmk@users.noreply.github.com> Date: Wed, 3 Sep 2025 21:59:07 -0400 Subject: [PATCH] feat: add installation options for interactive and non-interactive modes --- README.md | 12 ++++++++++-- install.bash | 13 ++++++++++--- 2 files changed, 20 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 1b609a0..0de466c 100644 --- a/README.md +++ b/README.md @@ -19,10 +19,18 @@ > [!NOTE] > The `/etc/ckan/default/ckan.ini` config file will have its comments removed for now. There are plans to fix this in a future release of `ckan-devstaller`. -Paste this into your new Ubuntu 22.04 instance's terminal: +You have two common options to choose from for installation. Paste one of the following scripts into your new Ubuntu 22.04 instance's terminal. + +### Install with non-interactive mode (default config) ```bash -wget -O - https://github.com/dathere/ckan-devstaller/releases/download/0.1.0/install.bash | bash +wget -O - https://github.com/dathere/ckan-devstaller/releases/download/0.2.0/install.bash | bash -s default +``` + +### Install with interactive mode + +```bash +wget -O - https://github.com/dathere/ckan-devstaller/releases/download/0.2.0/install.bash | bash ``` ## Demos diff --git a/install.bash b/install.bash index e42149f..22f5fe0 100644 --- a/install.bash +++ b/install.bash @@ -11,11 +11,18 @@ sudo apt install curl -y cd ~/ # Download the ckan-devstaller binary file -curl -LO https://github.com/dathere/ckan-devstaller/releases/download/0.1.0/ckan-devstaller +curl -LO https://github.com/dathere/ckan-devstaller/releases/download/0.2.0/ckan-devstaller # Add execute permission to ckan-devstaller binary file sudo chmod +x ./ckan-devstaller -# Run the ckan-devstaller binary file with defaults enabled -./ckan-devstaller --default +# Run the ckan-devstaller binary file +# If the user provides an argument "default", run ckan-devstaller in non-interactive mode with the default config +# Otherwise run ckan-devstaller in interactive mode +flag=$1 +if [ $flag == "default" ]; then + ./ckan-devstaller --default +else + ./ckan-devstaller +fi