protected void loadGhidraScriptProperties(ResourceFile file) throws IOException {

		Msg.info(this, "Reading script properties file: " + file.getAbsolutePath());
		if (!file.isFile()) {
			Msg.warn(this, ".properties file '" + file.toString() + "' is not a valid file.");
			return;
		}

		try (Scanner scanner = new Scanner(file.getInputStream(), "ASCII")) {

			while (scanner.hasNextLine()) {
				String line = scanner.nextLine().trim();

				// Ignore any comments or empty lines
				if (line.startsWith("#") || line.startsWith("!") || line.isEmpty()) {
					continue;
				}

				// break on '=' character
				int equalsIndex = line.indexOf('=');
				if (equalsIndex > 0) {
					String key = line.substring(0, equalsIndex).trim();
					String value = line.substring(equalsIndex + 1).trim();
					propertiesMap.put(key, value);
				}
			}
		}
		catch (FileNotFoundException fnfe) {
			throw new IOException("Could not find .properties file '" + file.toString() + "'");
		}
	}
Load a .properties file.

@param file  the .properties file
@throws IOException if there is an exception loading the properties file
Ghidra/Features/Base/src/main/java/ghidra/app/script/GhidraScriptProperties.java