From b20b250371aad2d42a432db4f73329353be8c000 Mon Sep 17 00:00:00 2001 From: Anchal Gupta Date: Fri, 8 Mar 2024 18:34:39 -0800 Subject: [PATCH 1/2] makefile clones without .jl in .julia/dev and more make r option now checks if it is called from inside a repo that is present in .julia/dev and if present there, it clones the dependent repos without the .jl extension. It also runs dvc pull to ensure sample files have been pulled --- makefile | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/makefile b/makefile index 6656c4a..53b0b8f 100644 --- a/makefile +++ b/makefile @@ -8,15 +8,20 @@ help: @echo env_with_cloned_repo r: + @echo "Pulling sample files using dvc" + -dvc pull @echo "Creating Julia environment by creating local clones of dependent repositories" - @echo "Cloning the repositories" - -cd ..; git clone "git@github.com:ProjectTorreyPines/OMAS.jl.git" - -cd ..; git clone "git@github.com:ProjectTorreyPines/GGDUtils.jl.git" - -cd ..; git clone "git@github.com:ProjectTorreyPines/SOLPS2IMAS.jl.git" - @echo "Generating Project.toml and Manifest.toml" - julia --project=. -e 'using Pkg; Pkg.rm(["OMAS", "GGDUtils", "SOLPS2IMAS", "EFIT"]); Pkg.develop(path="../OMAS.jl"); Pkg.develop(path="../GGDUtils.jl"); Pkg.develop(path="../SOLPS2IMAS.jl"); Pkg.add(url="git@github.com:JuliaFusion/EFIT.jl.git", rev="master"); Pkg.instantiate()' + @echo "Cloning the repositories and generating Manifest.toml" + -dn=$(shell dirname $(shell pwd)); \ + if [[ "$${dn:(-10)}" == ".julia/dev" ]]; then ext="" ; else ext=".jl";fi; \ + git clone "git@github.com:ProjectTorreyPines/OMAS.jl.git" ../OMAS$${ext}; \ + git clone "git@github.com:ProjectTorreyPines/GGDUtils.jl.git" ../GGDUtils$${ext}; \ + git clone "git@github.com:ProjectTorreyPines/SOLPS2IMAS.jl.git" ../SOLPS2IMAS$${ext}; \ + julia --project=. -e 'using Pkg; Pkg.rm(["OMAS", "GGDUtils", "SOLPS2IMAS", "EFIT"]); Pkg.develop(path="../OMAS'$${ext}'"); Pkg.develop(path="../GGDUtils'$${ext}'"); Pkg.develop(path="../SOLPS2IMAS'$${ext}'"); Pkg.add(url="git@github.com:JuliaFusion/EFIT.jl.git", rev="master"); Pkg.instantiate()' env_with_git_url u: + @echo "Pulling sample files using dvc" + -dvc pull @echo "Creating Julia environment with the git urls without creating local clones" @echo "Generating Project.toml and Manifest.toml" julia --project=. -e 'using Pkg; Pkg.rm(["OMAS", "GGDUtils", "SOLPS2IMAS", "EFIT"]); Pkg.add(url="git@github.com:ProjectTorreyPines/OMAS.jl.git", rev="master"); Pkg.add(url="git@github.com:ProjectTorreyPines/GGDUtils.jl.git", rev="master"); Pkg.add(url="git@github.com:ProjectTorreyPines/SOLPS2IMAS.jl.git", rev="master"); Pkg.add(url="git@github.com:JuliaFusion/EFIT.jl.git", rev="master"); Pkg.instantiate()' From 8e2b0a51592c4d10a2d9d1af1cde5e0264815463 Mon Sep 17 00:00:00 2001 From: Anchal Gupta Date: Mon, 11 Mar 2024 10:44:12 -0700 Subject: [PATCH 2/2] Fixed formatting --- src/supersize_profile.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/supersize_profile.jl b/src/supersize_profile.jl index f443df5..703084a 100644 --- a/src/supersize_profile.jl +++ b/src/supersize_profile.jl @@ -878,7 +878,7 @@ function cached_mesh_extension!( clear_cache=false, ) path = "$(@__DIR__)/../data/" - cached_ext_name = path * string(hash(eqdsk_file*b2fgmtry)) * ".mesh_ext.json" + cached_ext_name = path * string(hash(eqdsk_file * b2fgmtry)) * ".mesh_ext.json" if clear_cache rm(cached_ext_name; force=true) return cached_ext_name