Set the Rules directory IMPORTANT: this should be the very first call to MathCAT unless the environment var MathCATRulesDir is set
(dir: String)
| 42 | /// Set the Rules directory |
| 43 | /// IMPORTANT: this should be the very first call to MathCAT unless the environment var MathCATRulesDir is set |
| 44 | pub fn set_rules_dir(dir: String) -> Result<()> { |
| 45 | use std::path::PathBuf; |
| 46 | let pref_manager = crate::prefs::PreferenceManager::get(); |
| 47 | return pref_manager.borrow_mut().initialize(PathBuf::from(dir)); |
| 48 | } |
| 49 | |
| 50 | /// Returns the version number (from Cargo.toml) of the build |
| 51 | pub fn get_version() -> String { |