Skip to content

Commit 2b0610a

Browse files
authored
Merge pull request #2862 from ReactionMechanismGenerator/oldpythoncall
Tweaking install_rms for Github Actions
2 parents d65c5f3 + 0530efd commit 2b0610a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

install_rms.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ julia_path=$(which julia)
3838
echo "Julia 1.10 binary path: $julia_path"
3939

4040
# Get current conda environment name
41-
current_env=$(conda info --envs | grep '\*' | awk '{print $1}')
41+
current_env=$(conda info --envs | grep -v '^#' | awk '/\*/{print $1}')
4242
echo "Current conda environment: $current_env"
4343

4444
# Set environment variables for the current environment, for future uses
@@ -62,7 +62,7 @@ env | grep JULIA
6262
RMS_BRANCH=${RMS_BRANCH:-for_rmg}
6363
echo "Installing ReactionMechanismSimulator from branch: $RMS_BRANCH"
6464

65-
julia -e "using Pkg; Pkg.add(Pkg.PackageSpec(name=\"ReactionMechanismSimulator\", url=\"https://github.com/ReactionMechanismGenerator/ReactionMechanismSimulator.jl.git\", rev=\"$RMS_BRANCH\")); using ReactionMechanismSimulator; Pkg.instantiate()" || echo "RMS install error - continuing anyway ¯\_(ツ)_/¯"
65+
julia -e "using Pkg; Pkg.add(Pkg.PackageSpec(name=\"ReactionMechanismSimulator\", url=\"https://github.com/ReactionMechanismGenerator/ReactionMechanismSimulator.jl.git\", rev=\"$RMS_BRANCH\")); using ReactionMechanismSimulator; println(read(joinpath(dirname(pathof(ReactionMechanismSimulator)), \"..\", \"Project.toml\"), String)); Pkg.instantiate()" || echo "RMS install error - continuing anyway."
6666

6767
echo "Checking if ReactionMechanismSimulator is installed in the current conda environment for Python usage..."
6868
python -c "from juliacall import Main; import sys; sys.exit(0 if Main.seval('Base.identify_package(\"ReactionMechanismSimulator\") !== nothing') and print('ReactionMechanismSimulator is installed in $current_env') is None else 1)"

0 commit comments

Comments
 (0)