I combined the commits. The change that lets it work when a project isn't loaded is:

	if (prj_org)
	{
		header_patterns = get_precompiled_patterns(prj_org->header_patterns);
		source_patterns = get_precompiled_patterns(prj_org->source_patterns);
	}
	else
	{
		// use default header/source patterns if project isn't open
		gchar **headers, **source;
		headers = g_strsplit(PRJORG_PATTERNS_HEADER, " ", -1);
		source = g_strsplit(PRJORG_PATTERNS_SOURCE, " ", -1);

		header_patterns = get_precompiled_patterns(headers);
		source_patterns = get_precompiled_patterns(source);

		g_strfreev(headers);
		g_strfreev(source);
	}

If a general config is added to set commands for open folder/terminal, an option to set preferred header/source file extensions could be added as well. Rather than mess with it in this or the open folder/terminal PRs, I'd prefer to open (yet another) PR specifically to add general preferences.


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications on the go with GitHub Mobile for iOS or Android.