Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cli runner for native linux installation #420

Closed
hcwinsemius opened this issue May 23, 2024 · 1 comment
Closed

cli runner for native linux installation #420

hcwinsemius opened this issue May 23, 2024 · 1 comment

Comments

@hcwinsemius
Copy link

Feature type

Adding new functionality

Improvement Description

It would be helpful to add a command-line interface, similar to wflow_cli.exe to the repository for linux users.

Implementation Description

This can be achieved by installing Julia plus the required packages, and a bash script that behaves similar to wflow_cli.exe. The following script already does what is needed.

#!/bin/bash
# this is a simple wflow runner that behaves in a similar way as windows wflow_cli.exe
# but calls the julia code directly
source ~/.bash_profile
if [ -z $1 ]
then
  echo "No .toml file is set, please define the .toml file as input argument"
  exit 1
fi
export toml=$1

# check if .toml exists, if not return error
if [ ! -f $toml ]
then
  echo ".toml file $toml cannot be found. Please check if the path is correctly set."
  exit 1
fi
julia_cmd="julia -e 'using Wflow; Wflow.run()' '$toml'"
export julia_cmd
echo "Running Wflow julia with the following command:"
echo $julia_cmd
eval "$julia_cmd"
 

Additional Context

No response

@JoostBuitink
Copy link
Contributor

Thanks for reporting this. We do automatically create Linux binaries for every release, and their are stored on the (Deltares) P-drive. I believe that there is/was some internal discussion on sharing these binaries through official Deltares channels (legal aspects), and I don't know what the current status is. I'll share the path to the Linux binaries on the P drive with you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants