import does not need to be so pythonistic. We can drop the from and all keywords and use the following behaviour:
import [SH_LIBPATH implied/]path/to_library -> attempts to figure out if library exists. No? If the extension isn't .sh, then does path/to_library.sh exist? Yes? Load it.
import [SH_LIBPATH implied/]path/to_library.sh -> for loading a specific named library
import /a/different/path/to_library.sh -> as above, load a specific pathed library
import [SH_LIBPATH implied/]path -> just load all of the libraries in this directory. There's no need to handle from or all keywords: import text should just import all the libraries under text/
import
does not need to be so pythonistic. We can drop thefrom
andall
keywords and use the following behaviour:import [SH_LIBPATH implied/]path/to_library
-> attempts to figure out if library exists. No? If the extension isn't.sh
, then doespath/to_library.sh
exist? Yes? Load it.import [SH_LIBPATH implied/]path/to_library.sh
-> for loading a specific named libraryimport /a/different/path/to_library.sh
-> as above, load a specific pathed libraryimport [SH_LIBPATH implied/]path
-> just load all of the libraries in this directory. There's no need to handlefrom
orall
keywords:import text
should just import all the libraries undertext/