public static String simplifyRef(String catalogRefString) {
		if (Util.isURL(catalogRefString)) {
			ImplicitCatalogRef ref = ImplicitCatalogRef.extract(catalogRefString);
			if (ref != null) {
				return ref.toString();
			}
		} else if (!isValidCatalogReference(catalogRefString)) {
			if (catalogRefString.endsWith("/" + JBANG_CATALOG_REPO)) {
				return catalogRefString.substring(0, catalogRefString.length() - 14);
			} else {
				return catalogRefString.replace("/" + JBANG_CATALOG_REPO + "~", "~");
			}
		}
		return catalogRefString;
	}
Returns a Catalog containing all the aliases from local catalog files merged
into one. This follows the system where aliases that are "nearest" have
priority.

@param includeImplicits Determines if the implicit catalogs should be merged
                        or not
@return a Catalog object
src/main/java/dev/jbang/catalog/Catalog.java