Sublime Forum

Why do so many plugins fail to use the edit_settings command? Here's another solution.. edit_settings_plus

#1

When a plugin uses a pairing of one or more configuration files, why is it they aren’t using the edit_settings command which opens the settings window with a base / left and user / right configuration window? It is a lot easier for the end-user to navigate and use especially because the menu closes after clicking on a settings entry in the plugin menu hidden in nested menus layers deep… If a plugin has 5 or so configuration files and they don’t use edit_settings command, then the user has to navigate through the menu 10 times and click on 10 entries. It isn’t much better using edit_settings because they have to navigate through 10 times…

Isn’t it better to navigate through 1 time and click on 1 thing and open every setting? As an option, I think it does… It can also help developers and end-users by opening all of the keybind and mousebind files, along with all default configuration files for Sublime Text, and have another for the plugin…

Anyway, I posted a while back about edit_settings_plus - a command I am developing which allows opening one to many files in a single configuration window… As of right now, it is still stand-alone and can be incorporated into any plugin provided permission is asked to do so. I am considering dropping that stipulation, but if a plugin makes money, that would be another story. If Sublime Text wants to incorporate this into the core program, contact me - I think it would be beneficial to everyone and proper documentation needs to be supplied along with examples so developers know about it as an option, enough of them don’t know about edit_settings and opt for open_file instead which makes it difficult on the end-users, especially if someone has a deficit such as carpal-tunnel syndrome or something else. Sublime has done a great job with pretty much every single other aspect of the program to make it usable with the keyboard only, why make opening configuration files this hard ( This is on devs for not using edit_settings as much as it is on Sublime Text for the lack of information / examples, and because it doesn’t support multiple files )?

The primary features are:

  • Stand-Alone: It requires no add-on libraries meaning if included in a package, that package doesn’t need .no-sublime-package – it does require zipfile and a few other imports, but those are included with Sublimes version of Python - it doesn’t require my Library as a lot of the functionality was stripped out to keep it stand-alone for the time being… This will change soon because the line count will go down when using my library and I already use it for my addon…
  • Backwards Compatible: This addon has been designed to be backwards compatible with the edit_settings command - so you can change existing calls to edit_settings_plus without losing anything, then… from there, you can start using new features!
  • Ease of Use: With a single command call, one to many files can be opened, designated in the base / left or user / right side.
  • Default / Base File Protection: Base files can be editable if the developer argument is set to True to protect files from being edited when released
  • Default / Base File Protection: Save protection - if developer mode is disabled, files on the left / base group can’t be edited, they are marked as readonly… If developer mode is enabled, then they may be edited. The one exception is for files which were read from a package. I may allow editing packaged files at some point…
  • Space Optimization: If only one file is opened, the other group collapses automatically to reduce wasted space - unlike edit_settings, you can open a single file or a single group without the window closing.
  • File Linking: If you click on one file opened with a paired file, they are linked so when it is clicked on base or user side of the window, it will open on the opposite side. Files with the same name are also linked, even if they haven’t been opened together. It is always best to open them together though.
  • Linked File-Closing: If you close a file which is linked, then the linked file will close too.
  • Packed File Opener: Opening archived / packaged files has now been incorporated - you can force it by using the file location res://Packages/PackageName/Path/To/File.ext or res://PackageName/Path/To/File.ext - you can also use the standard path and if it doesn’t exist, it’ll check to see if a package exists and if it exists in the package it’ll be loaded from there
  • Extended Variables / Shorter File-Names / Dynamic File Contents: A large list of extended variables which can be used in file-names and in files which are opened to reduce repetition and find files much faster than before! They can be used to open files including the install directory, packages dir, user dir, and so much more… making linking to files that much easier - I plan on adding more to link to default files directly such as Preferences, Preferences for the OS, Key Binds and more…
  • Mark New Files as Unedited: Scratch system so if a file doesn’t exist on the user side, the default contents are set and the file isn’t marked as unedited unless the user edits it - the same is true for the left / base side unless developer mode is enabled so extracted files show up as unedited

Where can I get it?

Currently it is in my Plugin which can be found here ( And it may be on Package Control already ): https://bitbucket.org/Acecool/AcecoolCodeMappingSystem

Play around with it, and if you want to include it with your plugin, send me a message!

Special Notes regarding operation of the plugin:

  • You must use the same number of entries in base_file, user_file, and default entries if they are lists in the edit_settings style format – Use None entries if you have more base / user files than the other or default… The number of entries should be the same as the largest list. If you use file_list, then you simply add entries with or without one or the other, or with both, base / user file and you don’t have to worry about it.
  • You are not required to have a user and base file in each file_list entry.
  • Do not add base_file, user_file and file_list… Use either base_file and user_file pairing OR file_list. I may add support for everything to be added at some point, but for now, it isn’t officially supported.
  • You can set base_file and user_file to load files along with file_list, but I recommend using file_list OR base_file and / or user_file pairing.
  • A few print statements are enabled by default and are only called in specific instances: One is called when creating links between base / user files, and another is output when closing linked views when either is closed.

What are the ${x} arguments I can use when using the edit_settings_plus style command format inside of files or for use in file-names?

Note: These arguments are the base-level arguments… These are not for within file_list although most will work, I’ll create an extra list for those…
Note: * means it is planned.

ie:

self.window.run_command(
	'edit_settings_plus',
	{
		'argument_1': value_1,
		'argument_2': value_2,
		'argument_3': value_3
	}
);
  • base_file: This corresponds to the edit_settings base style command format - it can be a single string filename, or a list of base / left side grouped files… - These arguments, as lists, must have the same number of entries - None can be used as an entry to ensure the same number of entries.
  • base: This is an alias of base_file - Note: This can not be used in conjunction with base_file… Use one or the other.
  • user_file: This corresponds to the edit_settings base style command format - it can be a single string filename, or a list of user / right side grouped files. - These arguments, as lists, lists must have the same number of entries - None can be used as an entry to ensure the same number of entries.
  • user: This is an alias of user_file - Note: This can not be used in conjunction with user_file… Use one or the other.
  • default: This defines the default contents to use for a user file. Note: If file_list is used and this is defined, then if default or contents isn’t set for an entry, then this is used instead…
  • default_user: This is an alias of default Note: If file_list is used and this is not defined, then if default or contents or default_user or contents_user isn’t set for an entry, then this is used instead…
  • default_base: This defines default contents to use for a default file if the file doesn’t exist. Note: If file_list is used and this is not defined, then if default_base or contents_base isn’t set for an entry, then this is used instead…
  • contents: This is an alias of default - Note: This can not be used in conjunction with default. Use one, or the other.
  • contents_user: This is an alias of default_user - Note: This can not be used in conjunction with default. Use one, or the other.
  • contents_base: This is an alias of default_base - Note: This can not be used in conjunction with default. Use one, or the other.
  • syntax: This forces a syntax to be assigned for highlighting the loaded file - this affects the User and Base files.
  • syntax_user: This forces a syntax to be assigned to the User file only. Note: If file_list is used and this is defined, then if syntax or syntax_user isn’t set for an entry, then this is used instead…
  • syntax_base: This forces a syntax to be assigned to the Base file only. Note: If file_list is used and this is defined, then if syntax or syntax_base isn’t set for an entry, then this is used instead…
  • repo: This is used to populate the ${repo} data so you can set up links to ${repo}/issues/new/ without repeating yourself - this can be used in file bodies too!
  • package: This can be automatically populated if you use the supplied code in your package ( The supplied code is part of edit_settings_plus.py - it will report the package name of the package where it was included from, so if you don’t want to be required to manually set the package name for each command, you need to include edit_settings_plus from your package ), however if you don’t then when using it, it will show up as MyPackage or something similar… You can manually input the data - for instance, I would use AcecoolCodeMappingSystem for my current package.
  • file_list: This is a Dictionary argument, it can contain Dictionary Entries with any of the previous arguments, except base_file and user_file must be a single string filename. - I may add support for these to be lists at a later point, but for now, they’re not set up that way.
  • files: This is an alias of file_list
  • developer: This enables developer mode, if set to True - default is False. When developer mode is active, additional features are enabled and some are disabled. For instance, Base files, when developer mode is disabled, are set to ReadOnly - but when developer mode is enabled, Read Only is disabled so the package developer can make changes to the file.
  • debugging: When debugging is set to True, internal print statements are triggered and output to the console to show how edit_settings_plus is running, what it is doing, etc… Helpful if there are problems so you can see exactly where an issue is happening.
  • view: If not defined, the Active View from the Active Window is used. These are used to define the View which was used to call the command - this is important if you want to grab the view settings for syntax, for instance. These are passed through to ExtractVariables and this one returns _view.settings( ); for syntax. In this case, if we want to get the syntax settings file for the view we called edit_settings_plus from so it can be opened, this lets us do it or lets us redirect it to some other view we want the syntax information from…
  • window: If not defined, the Active Window is used. These are used to define the Window which was used to call the command - this is important if you want to grab window properties. These are passed through to ExtractVariables and this one returns _window.extract_variables( ); This provides a lot of information, namely the details for the Project, workspace, session, etc…
  • sidebar: This is used to define whether or not the sidebar should be opened in the newly created Settings Window. By default, this is set to False meaning the sidebar will be hidden in the settings window.
  • minimap: This is used to define whether or not the minimap is visible in the newly created Settings Window. By Default, this is True.

What are the ${x} arguments I can use when using the edit_settings_plus style command format inside of a file_list entry?

ie:

self.window.run_command(
	'edit_settings_plus',
	{
		'file_list':	
		[
			{ 'entry_1_arg_1': entry_1_arg_1_value, 'entry_1_arg_2': entry_1_arg_2_value, 'entry_1_arg_3': entry_1_arg_3_value },
			{ 'entry_2_arg_1': entry_2_arg_1_value, 'entry_2_arg_2': entry_2_arg_2_value, 'entry_2_arg_3': entry_2_arg_3_value },
			{ 'entry_3_arg_1': entry_3_arg_1_value, 'entry_3_arg_2': entry_3_arg_2_value, 'entry_3_arg_3': entry_3_arg_3_value }
		]
	}
);
  • base_file: This corresponds to the edit_settings base style command format - it can be a single string filename, or a list of base / left side grouped files… - These arguments, as lists, must have the same number of entries - None can be used as an entry to ensure the same number of entries.
  • base: This is an alias of base_file - Note: This can not be used in conjunction with base_file… Use one or the other.
  • user_file: This corresponds to the edit_settings base style command format - it can be a single string filename, or a list of user / right side grouped files. - These arguments, as lists, lists must have the same number of entries - None can be used as an entry to ensure the same number of entries.
  • user: This is an alias of user_file - Note: This can not be used in conjunction with user_file… Use one or the other.
  • default: This defines the default contents to use for a user file. Note: inside of a file_list entry - if default is not defined for the entry, but it is defined outside of the file_list then the entry inherits the value from the global setting - this is so you can define a single base, if you want, and use variables inside of the file to make it fit the file itself…
  • default_user: This is an alias of default Note: inside of a file_list entry - if default_user is not defined for the entry, but it is defined outside of the file_list then the entry inherits the value from the global setting - this is so you can define a single base, if you want, and use variables inside of the file to make it fit the file itself…
  • default_base: This defines default contents to use for a default file if the file doesn’t exist. Note: inside of a file_list entry - if default_base is not defined for the entry, but it is defined outside of the file_list then the entry inherits the value from the global setting - this is so you can define a single base, if you want, and use variables inside of the file to make it fit the file itself…
  • contents: This is an alias of default - Note: This can not be used in conjunction with default. Use one, or the other.
  • contents_user: This is an alias of default_user - Note: This can not be used in conjunction with default. Use one, or the other.
  • contents_base: This is an alias of default_base - Note: This can not be used in conjunction with default. Use one, or the other.
  • syntax: This forces a syntax to be assigned for highlighting the loaded file - this affects the User and Base files.
  • syntax_user: This forces a syntax to be assigned to the User file only. Note: If file_list is used and this is defined, then if syntax or syntax_user isn’t set for an entry, then this is used instead…
  • syntax_base: This forces a syntax to be assigned to the Base file only. Note: If file_list is used and this is defined, then if syntax or syntax_base isn’t set for an entry, then this is used instead…
0 Likes

#2

So, how does it work? It’s quite simple, you can define a command, or call it using the exact same method as edit_settings… You can further extend the files from 2 by changing the user / base file key to a table ( supports tuple, dict and list ) or you can use my format which adds additional functionality. Below are a few options…

edit_settings style command structure:

Example 1 - Using edit_settings style command:
This example would almost work if you used edit_settings as the command instead of edit_settings_plus - the limitation is a single file in the base and user groups…

##
## Command - Open Plugin Menu Files
##
class edit_settings_x_cmd_open_sublime_prefs( sublime_plugin.WindowCommand ):
	##
	def description( self ):
		return '[ Sublime ] Open Default and User Preferences'

	## Open all of the menu files in the package...
	def run( self ):
		self.window.run_command(
			'edit_settings_plus',
			{
				## Open Sublime Text Preferences
				'base_file':	'${default}/Preferences.sublime-settings',
				'user_file':	'${user}/Preferences.sublime-settings',
				'default':		'//\n// Sublime Text - Preferences - User\n//\n{\n\t$0\n}\n'
			}
		);

Example 2 - Using edit_settings style command, extended to support multiple files
This example adds on top of the previous, except instead of only opening a single file in each, all of the settings files are opened… This includes both Preference files, along with the keymap and mousemap files. - This would take quite a few clicks in a menu, but here it can be done with a single menu item or single command…

Also, as seen, this works almost exactly like edit_settings command using their argument names, etc… but by adding functionality, it makes everything more efficient.

Also, if the files aren’t extracted for the default, now with the res:// system, they’ll be loaded from the package automatically…

##
## Command - Open Plugin Menu Files
##
class edit_settings_x_cmd_open_sublime_all_prefs( sublime_plugin.WindowCommand ):
	## Defaults
	__default_prefs__				= '//\n// Sublime Text - Preferences - User\n//\n{\n\t$0\n}\n'
	__default_platform_prefs__		= '//\n// Sublime Text - Platform Preferences - User\n//\n{\n\t$0\n}\n'
	__default_platform_keymap__		= '//\n// Sublime Text - Key-Map: Platform Specific - ${platform} - User\n//\n{\n\t$0\n}\n'
	__default_platform_mousemap__	= '//\n// Sublime Text - Mouse-Map: Platform Specific - ${platform} - User\n//\n{\n\t$0\n}\n'

	##
	def description( self ):
		return '[ Sublime ] Open Default and User Preferences'

	## Open all of the menu files in the package...
	def run( self ):
		self.window.run_command(
			'edit_settings_plus',
			{
				## Open Sublime Text Preferences
				'base_file':	
				[ 
					'${default}/Preferences.sublime-settings',
					'${default}/Preferences (${platform}).sublime-settings',
					'${default}/Default (${platform}).sublime-keymap',
					'${default}/Default (${platform}).sublime-mousemap'
				],
				'user_file':	
				[
					'${user}/Preferences.sublime-settings',
					'${user}/Preferences (${platform}).sublime-settings',
					'${user}/Default (${platform}).sublime-keymap',
					'${user}/Default (${platform}).sublime-mousemap'
				],

				## Default values for the user file...
				'default':	
				[
					self.__default_prefs__,
					self.__default_platform_prefs__,
					self.__default_platform_keymap__,
					self.__default_platform_mousemap__
				]
			}
		);

Example 3: This example shows how to use None entries to ensure the same number of entries in each list if you have base_file and user_file set up along with defaults, and they are all lists… If you only use one or the other, then you don’t need to worry about it…

##
## Command - Open Plugin Menu Files
##
class edit_settings_x_cmd_open_sublime_odd_prefs( sublime_plugin.WindowCommand ):
	##
	def description( self ):
		return '[ Sublime ] Open Default and User Preferences - odd'

	## Open all of the menu files in the package...
	def run( self ):
		self.window.run_command(
			'edit_settings_plus',
			{
				## Open Sublime Text Preferences
				'base_file':	
				[ 
					None,
					'${default}/Preferences (${platform}).sublime-settings',
					None,
					None
				],
				'user_file':	
				[
					'${user}/Preferences.sublime-settings',
					'${user}/Preferences (${platform}).sublime-settings',
					'${user}/Default (${platform}).sublime-keymap',
					'${user}/Default (${platform}).sublime-mousemap'
				],

				## Default values for the user file...
				'default':	
				[
					None,
					'Platform Preferences',
					None,
					None
				]
			}
		);

edit_settings_plus style command structure: These are similar to the above examples, except they use file_list and add in some extra settings…

Example 1 - Base Example
This is the same as example 2 above, except it uses file_list and the base and user file along with the default entries are on a single line… It looks a bit more compact.

##
## Command - Open Sublime Text Configuration Files
##
class edit_settings_plus_cmd_open_sublime_all_prefs( sublime_plugin.WindowCommand ):
	## Defaults
	__default_prefs__				= '//\n// Sublime Text - Preferences - User\n//\n{\n\t$0\n}\n'
	__default_platform_prefs__		= '//\n// Sublime Text - Platform Preferences - User\n//\n{\n\t$0\n}\n'
	__default_platform_keymap__		= '//\n// Sublime Text - Key-Map: Platform Specific - ${platform} - User\n//\n{\n\t$0\n}\n'
	__default_platform_mousemap__	= '//\n// Sublime Text - Mouse-Map: Platform Specific - ${platform} - User\n//\n{\n\t$0\n}\n'

	##
	def description( self ):
		return '[ Sublime ] Open Default and User Preferences'

	## Open all of the menu files in the package...
	def run( self ):
		self.window.run_command(
			'edit_settings_plus',
			{
				## Open Sublime Text Preferences
				'file_list':	
				[
					{ 'base_file': '${default}/Preferences.sublime-settings',					'user_file': '${user}/Preferences.sublime-settings',			'default': self.__default_prefs__							},
					{ 'base_file': '${default}/Preferences (${platform}).sublime-settings',		'user_file': '${user}/Preferences.sublime-settings',			'default': self.__default_platform_prefs__					},
					{ 'base_file': '${default}/Default (${platform}).sublime-keymap',			'user_file': '${user}/Preferences.sublime-settings',			'default': self.__default_platform_keymap__					},
					{ 'base_file': '${default}/Default (${platform}).sublime-mousemap',			'user_file': '${user}/Preferences.sublime-settings',			'default': self.__default_platform_mousemap__				}
				]
			}
		);

Example 2 - Alternate

Now, lets use some of the new features, besides the ones we’ve been using to open more files and to shorten the length of file-name needed… Lets force some of the files to use different syntax for highlighting and maybe a few other things…

This sets the syntax used to highlight for a few of the files to Python, one to JavaScript, and the other which is set to None is the same as it not being present ( You don’t need to add the argument just to set it to None… it is optional - I’m just adding it here to place emphasis on the fact that no change is made )

##
## Command - Open Sublime Text Configuration Files
##
class edit_settings_plus_cmd_open_sublime_all_prefs_extra( sublime_plugin.WindowCommand ):
	## Defaults
	__default_prefs__				= '//\n// Sublime Text - Preferences - User\n//\n{\n\t$0\n}\n'
	__default_platform_prefs__		= '//\n// Sublime Text - Platform Preferences - User\n//\n{\n\t$0\n}\n'
	__default_platform_keymap__		= '//\n// Sublime Text - Key-Map: Platform Specific - ${platform} - User\n//\n{\n\t$0\n}\n'
	__default_platform_mousemap__	= '//\n// Sublime Text - Mouse-Map: Platform Specific - ${platform} - User\n//\n{\n\t$0\n}\n'

	## Syntax File Links
	__syntax_python__				= 'Packages/Python/Python.sublime-syntax'
	__syntax_javascript__			= 'Packages/JavaScript/JavaScript.sublime-syntax'

	##
	def description( self ):
		return '[ Sublime ] Open Default and User Preferences with Syntax declarations...'

	## Enables / Disables the menu item based on whether the active / focused file-tab is set...
	def is_enabled( self ):
		return self.window.active_view( ) is not None

	## Open all of the menu files in the package...
	def run( self ):
		self.window.run_command(
			'edit_settings_plus',
			{
				## Open Sublime Text Preferences
				'file_list':
				[
					{ 'base_file': '${default}/Preferences.sublime-settings',					'user_file': '${user}/Preferences.sublime-settings',			'default': self.__default_prefs__,						'syntax': None							},
					{ 'base_file': '${default}/Preferences (${platform}).sublime-settings',		'user_file': '${user}/Preferences.sublime-settings',			'default': self.__default_platform_prefs__,				'syntax': __syntax_python__				},
					{ 'base_file': '${default}/Default (${platform}).sublime-keymap',			'user_file': '${user}/Preferences.sublime-settings',			'default': self.__default_platform_keymap__,			'syntax': __syntax_python__				},
					{ 'base_file': '${default}/Default (${platform}).sublime-mousemap',			'user_file': '${user}/Preferences.sublime-settings',			'default': self.__default_platform_mousemap__,			'syntax': __syntax_javascript__			}
				]
			}
		);

Example 3: This uses built-in helpers in edit_settings_plus.py to open commonly used default files. I am planning on also adding all of the default menu files, and maybe a few more depending on what people are interested in… Sure, the addon already makes adding files short, so why do this? Well, if the default files can be controlled by the plugin so the developer of a plugin doesn’t need to worry about file-name changes, etc… then why not? I honestly wish a lot of the extract / expanded variables I’ve added were available by default because a lot of them are quite useful…

##
## Command - Open Sublime Text Configuration Files ## Command using helpers...
##
class edit_settings_plus_cmd_open_easy_prefs( sublime_plugin.WindowCommand ):
	##
	def description( self ):
		return '[ edit_settings_plus ] Open Preferences using Easy Entries'

	## Open all of the menu files in the package...
	def run( self ):
		self.window.run_command(
			'edit_settings_plus',
			{
				## Open Sublime Text Preferences
				'file_list':
				[
					## This opens the User 'Path/To/Syntax.sublime-settings' Settings Configuration File For the Base file, it opens the sublime-syntax or .tmLanguage file as it doesn't appear there are default syntax based configuration files that I've seen yet...
					EDIT_SETTINGS_PLUS_ENTRY_SYNTAX_CONFIG,

					## This opens the Default and User 'Preferences.sublime-settings' File
					EDIT_SETTINGS_PLUS_ENTRY_PREFERENCES,

					## This opens the Default and User 'Preferences (PLATFORM).sublime-settings' File
					EDIT_SETTINGS_PLUS_ENTRY_PLATFORM_PREFERENCES,

					## This opens the Default and User 'Default (PLATFORM).sublime-keymap' File
					EDIT_SETTINGS_PLUS_ENTRY_KEYMAP,

					## This opens the Default and User 'Default (PLATFORM).sublime-mousemap' File
					EDIT_SETTINGS_PLUS_ENTRY_MOUSEMAP
				]
			}
		);

Example 3 uses the following defaults: - Note: I may actually add more of these helper defaults to make opening default files that much easier, and if a file-name ever changes, the plugin update can handle it and I am quick to push through such changes… I would need to add in a version backwards compatible system if they change in the future though and I do need to verify older filenames…

##
## Default Command Entries
##

## Preferences
EDIT_SETTINGS_PLUS_ENTRY_PREFERENCES			= {	'base_file': '${sublime_path_preferences_default}',					'user_file': '${sublime_path_preferences_user}',					'default': '${edit_settings_plus_default_data_preferences}',				};
			
## Platform Preferences			
EDIT_SETTINGS_PLUS_ENTRY_PLATFORM_PREFERENCES	= {	'base_file': '${sublime_path_platform_preferences_default}',		'user_file': '${sublime_path_platform_preferences_user}',			'default': '${edit_settings_plus_default_data_platform_preferences}',		};
			
## KeyMap			
EDIT_SETTINGS_PLUS_ENTRY_KEYMAP					= {	'base_file': '${sublime_path_platform_keymap_default}',				'user_file': '${sublime_path_platform_keymap_user}',				'default': '${edit_settings_plus_default_data_platform_keymap}',			};
			
## MouseMap			
EDIT_SETTINGS_PLUS_ENTRY_MOUSEMAP				= {	'base_file': '${sublime_path_platform_mousemap_default}',			'user_file': '${sublime_path_platform_mousemap_user}',				'default': '${edit_settings_plus_default_data_platform_mousemap}',			};
			
## Syntax			
EDIT_SETTINGS_PLUS_ENTRY_SYNTAX					= {	'base_file': '${syntax_path}',										'user_file': '${sublime_path_syntax_settings_user}',				'default': '${edit_settings_plus_default_data_syntax_settings}',			}; 
0 Likes

#3

What about the extended variables which can be used in the naming, some of which are seen above? Here is a complete list of the current list - note: some of these come from sublime.active_window( ).extract_variables( ), and a lot come from new additions:

Note: package was manually overwritten to be MyPackageFolderName

//
// Acecool - Code Mapping System - Extracted Vars Example
//
// Note: Because of our use of several sources - some values may be identical and some vars may be shortened - treat these as aliases...
//


//
// Computer / Software Information - The following variables and results pertains to your computer and Sublime Text...
//

// This is a built in helper to return Case-Correct Windows / Linux / OSX / etc.. and is future-proof
${platform}																		Windows

// This returns the CPU architecture - ie 32 bit / 64 bit as "x32" or "x64" -- WARNING: This returns Windows for some reason??? Bug? Should return x32 or x64...
${architecture} || ${arch}														x64 && x64

//Sublime Text Version
${version_sublime}																3176

// Incredibly Important: Path Delimiter for file paths - This should be used instead of manually using \ or /...
${slash} || ${delim} || ${delimiter} || ${path_delimiter}						\ && \ && \ && \


//
// THIS file information - Only defined if it is a file-name used, not data being passed through...
//

// The filename with path
${this_file}																	C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\User\ACMS_EXPANDABLE_VARS_EXAMPLE.md

// The File-Path
${this_file_path}																C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\User

// The file-name by itself
${this_file_name}																ACMS_EXPANDABLE_VARS_EXAMPLE.md

// The base-filename without the extension
${this_file_base_name}															ACMS_EXPANDABLE_VARS_EXAMPLE

// The file extension
${this_file_ext}																md


//
// File Information - The following variables and results pertains to the file which was active / in-focus at the time edit_settings_plus was called...
//

// Full path to the file with file extension
${file} || ${active_view_file}													C:\AcecoolGit\acecooldev_sublimetext3\AppData\Sublime Text 3\Packages\AcecoolCodeMappingSystem\edit_settings_plus.py && C:\AcecoolGit\acecooldev_sublimetext3\AppData\Sublime Text 3\Packages\AcecoolCodeMappingSystem\edit_settings_plus.py

// File Path without file-name...
${file_path} || ${active_view_path}												C:\AcecoolGit\acecooldev_sublimetext3\AppData\Sublime Text 3\Packages\AcecoolCodeMappingSystem && C:\AcecoolGit\acecooldev_sublimetext3\AppData\Sublime Text 3\Packages\AcecoolCodeMappingSystem

// Filename without path - with and without the extension
${file_name} || ${active_view_filename}											edit_settings_plus.py && edit_settings_plus.py

// Base Filename
${file_base_name}																edit_settings_plus

// File Extension for the file which was active at the time edit_settings_plus was called... and aliases.. ie: py, sublime-settings, cpp, ahk, etc..
${file_extension} || ${extension} || ${ext}										py && py && py


//
// Syntax Information - The following variables and results pertains to the Syntax / Language Definition being used by the file which was active / in-focus at the time edit_settings_plus was called...
//

// Syntax / Language Name for the file which was active at the time edit_settings_plus was called... and aliases..
${syntax} || ${language} || ${lang}												Python && Python && Python

// Full Path to the Syntax User Configuration File ie: 'Packages\User\Python.sublime-settings'
${user_syntax}																	C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\User\Python.sublime-settings

// Full Path to the Syntax / Language Definition File with filename and Extension.
${syntax_path}																	C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\Python\Python.sublime-syntax

// The Syntax Path, ready to use for _view.set_syntax( 'Packages\Python\Python.sublime-syntax' ); as it requires 'Packages\'
${syntax_path_ready}															Packages\Python\Python.sublime-syntax

// Base Path starting after 'Packages\' .. ie: 'JavaScript\JSON.sublime-syntax' .. to the Syntax / Language Definition File with filename and Extension.
${syntax_path_base}																Python\Python.sublime-syntax

// Syntax / Language Definition File Name with Extension
${syntax_file}																	Python.sublime-syntax

// Syntax / Language Definition Data - File Extenson.. ie: 'tmLanguage' or 'sublime-syntax'
${syntax_ext}																	sublime-syntax


//
// Package Information
//

// Package Name - Returns either the package name provided in the arguments list, or the magic __package__ result...
${package_name}																	MyPackageFolderName


//
// Magic Package Information
//

// The Magic Package Name ( uses __package__ instead of the built in code - this should return the proper name of where 'edit_settings_plus.py' resides regardless )...
${magic_package}																AcecoolCodeMappingSystem


//
// Magic 'edit_settings_plus.py' File Information
//

// The Magic File Path
${magic_file_path}																C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\AcecoolCodeMappingSystem\edit_settings_plus.py

// The Magic File Base Path
${magic_file_path_base}															C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\AcecoolCodeMappingSystem

// The Magic File Name
${magic_filename}																edit_settings_plus.py

// The Magic File Base Name
${magic_file_base_name}															edit_settings_plus

// The Magic File Extension
${magic_file_ext}																py


//
// Sublime Text Folder Structure - The following variables and results pertains to the application data folder-structure used by Sublime Text, and the active package...
//

// Full path to the Packages folder
${packages_path}																C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages

// Full path to the Packages folder
${packages}																		C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages

// Full Path to the Package Directory ie: 'Packages\PackageName' - Windows Example: '%AppData%\Sublime Text 3\Packages\AcecoolCodeMappingSystem'
${package}																		C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\MyPackageFolderName

// Full Path to the User Packages Directory ie: 'Packages\User' - Windows Example: '%AppData%\Sublime Text 3\Packages\User'
${user}																			C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\User

// Full Path to the User Package Directory ie: 'Packages\User\PackageName' - Windows Example: '%AppData%\Sublime Text 3\Packages\User\AcecoolCodeMappingSystem'
${user_package}																	C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\User\MyPackageFolderName

// Full Path to the Default Packages Directory ie: 'Packages\Default' - Windows Example: %AppData%\Sublime Text 3\Packages\Default'
${default}																		C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\Default

// Full Path to the Installed Packages Directory ie: '..\Installed Packages' - Windows Example: %AppData%\Sublime Text 3\Installed Packages'
${packages_installed}															C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Installed Packages

// Full Path to the Sublime Text Cache Directory ie: 'Cache\' - Windows Example: '%AppData%\..\Local\Sublime Text 3\Packages\User'
${cache}																		C:\Users\Acecool\AppData\Local\Sublime Text 3\Cache


//
// Environment Paths
//

// Local AppData
${local}																		C:\Users\Acecool\AppData\Local

// AppData
${appdata}																		C:\Users\Acecool\AppData\Roaming


//
// Sublime Text Install Directory Structure - The following variables and results pertain to the installation folder of Sublime Text and important files / folders within..
//

// Full path to the Sublime Text Installation Directory ( Directory where the executable is ) -- 'C:\Program Files\Sublime Text 3'
${sublime_install_path}															C:\Program Files\Sublime Text 3

// Full path to the Sublime Text Installation Directory ( Directory where the executable is ), then the Packages Sub-Directory.
${sublime_packages_path}														C:\Program Files\Sublime Text 3\Packages

// Full path to the Sublime Changelog file -- 'C:\Program Files\Sublime Text 3\changelog.txt'
${sublime_changelog_path}														C:\Program Files\Sublime Text 3\changelog.txt

// Full path to the Sublime Executable Path -- 'C:\Program Files\Sublime Text 3\sublime_text.exe'
${sublime_exe_path}																C:\Program Files\Sublime Text 3\sublime_text.exe

// The Executable Filename for Sublime Text - 'sublime_text.exe'
${sublime_exe_filename}															sublime_text.exe

// The base filename for the Sublime Text Executable -- 'sublime_text'
${sublime_exe_name}																sublime_text

// Full path to the Sublime Executable Extension (.exe, .dmg, etc.. ) -- 'exe'
${sublime_exe_extension}														exe



//
// Sublime Text Window Session / Project Information - The following data pertains to the Sublime Text window session, project folders, etc.. as seen in menu > project > *
//

// Project Based - These contain data regarding the Sublime Text Window Session - The Project with folder data in the sidebar, etc.. nothing to do with Sublime Text Packages...

// Sublime Text Loaded Project Folder - This is a folder added to the project... Where is the entire list of them?
${folder}																		C:\AcecoolGit\acecooldev_sublimetext3\AppData\Sublime Text 3\Packages\AcecoolCodeMappingSystem

// Sublime Text Loaded Project or Workspace Path - This is the full path to the saved workspace / project file
${project_path}																	C:\Users\Acecool\Dropbox\AppSettingsAndWorkSpaces\Workspaces

// Sublime Text Loaded Project or Workspacce Path with File - This is where the saved workspace / project file is stored
${project}																		C:\Users\Acecool\Dropbox\AppSettingsAndWorkSpaces\Workspaces\AcecoolCodeMappingSystem - Latest.sublime-project

// Sublime Text Saved Project / Workspace Filename
${project_name}																	AcecoolCodeMappingSystem - Latest.sublime-project

// Sublime Text Saved Project / Workspace File Base Name
${project_base_name}															AcecoolCodeMappingSystem - Latest

// Sublime Text Saved Project / Workspace File Extension
${project_extension}															sublime-project


//
// Miscellaneous Variables - The following have no other categorization...
//

// Base Repo URL - Useful when adding multiple menu items to the Repo such as: View Wiki, View All Issues, Submit New Issue, etc.. Note: ARG repo REQUIRED to be of use!
${repo}																			https://bitbucket.org/MyName/MyRepoNameOrID


//
// Sublime Text - Default File Paths ( Base )
//
${sublime_path_preferences_default}												C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\Default\Preferences.sublime-settings
${sublime_path_platform_preferences_default}									C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\Default\Preferences (Windows).sublime-settings
${sublime_path_platform_keymap_default} || ${sublime_path_keymap_default}		C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\Default\Default (Windows).sublime-keymap && C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\Default\Default (Windows).sublime-keymap
${sublime_path_platform_mousemap_default} || ${sublime_path_mousemap_default}	C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\Default\Default (Windows).sublime-mousemap && C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\Default\Default (Windows).sublime-mousemap



//
// Sublime Text - Default File Paths ( User )
//
${sublime_path_preferences_user}												C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\User\Preferences.sublime-settings
${sublime_path_platform_preferences_user}										C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\User\Preferences (Windows).sublime-settings
${sublime_path_platform_keymap_user} || ${sublime_path_keymap_user}				C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\User\Default (Windows).sublime-keymap && C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\User\Default (Windows).sublime-keymap
${sublime_path_platform_mousemap_user} || ${sublime_path_mousemap_user}			C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\User\Default (Windows).sublime-mousemap && C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\User\Default (Windows).sublime-mousemap


//
// Sublime Text - Default Menu Paths
//

// Context Menu - This menu appears when you right-click inside of a view / file in the text-editor area...
${sublime_path_menu_context}													C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\Default\Context.sublime-menu

## Encoding Menu - This menu appears when choosing file-encoding
${sublime_path_menu_encoding}													C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\Default\Encoding.sublime-menu

## Find In Files Menu - This menu appears when
${sublime_path_menu_find_in_files}												C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\Default\Find in Files.sublime-menu

## Indentation Menu - This menu appears when
${sublime_path_menu_indentation}												C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\Default\Indentation.sublime-menu

## Main Menu - This menu appears when
${sublime_path_menu_main}														C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\Default\Main.sublime-menu

## Side Bar Mount Point Menu - This menu appears when
${sublime_path_menu_side_bar_mount_point}										C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\Default\Side Bar Mount Point.sublime-menu

## Side Bar Menu - This menu appears when
${sublime_path_menu_side_bar}													C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\Default\Side Bar.sublime-menu

## Syntax Menu - This menu appears when
${sublime_path_menu_syntax}														C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\Default\Syntax.sublime-menu

## Tab Context Menu - This menu appears when you right-click a view tab
${sublime_path_menu_tab_context}												C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\Default\Tab Context.sublime-menu

## Widget Context Menu - This menu appears when
${sublime_path_menu_widget_context}												C:\Users\Acecool\AppData\Roaming\Sublime Text 3\Packages\Default\Widget Context.sublime-menu


//
// Sublime Text - Default Menu Files
//

// Context Menu - This menu appears when you right-click inside of a view / file in the text-editor area...
${sublime_filename_menu_context}												Context.sublime-menu

## Encoding Menu - This menu appears when choosing file-encoding
${sublime_filename_menu_encoding}												Encoding.sublime-menu

## Find In Files Menu - This menu appears when
${sublime_filename_menu_find_in_files}											Find in Files.sublime-menu

## Indentation Menu - This menu appears when
${sublime_filename_menu_indentation}											Indentation.sublime-menu

## Main Menu - This menu appears when
${sublime_filename_menu_main}													Main.sublime-menu

## Side Bar Mount Point Menu - This menu appears when
${sublime_filename_menu_side_bar_mount_point}									Side Bar Mount Point.sublime-menu

## Side Bar Menu - This menu appears when
${sublime_filename_menu_side_bar}												Side Bar.sublime-menu

## Syntax Menu - This menu appears when
${sublime_filename_menu_syntax}													Syntax.sublime-menu

## Tab Context Menu - This menu appears when you right-click a view tab
${sublime_filename_menu_tab_context}											Tab Context.sublime-menu

## Widget Context Menu - This menu appears when
${sublime_filename_menu_widget_context}											Widget Context.sublime-menu


//
// Ready to use Syntax Files... - These have Packages/ as a prefix, which is a requirement if you use _view.set_syntax( ... ); unfortunately because it doesn't follow the standard file-structure of everything else... and makes it less easy to compile folder structures...
//
${sublime_syntax_ready_asp}														Packages\ASP\ASP.sublime-settings
${sublime_syntax_ready_asp_html}												Packages\ASP\HTML-ASP.sublime-settings
${sublime_syntax_ready_autohotkey}												Packages\AutoHotkey\AutoHotkey.sublime-settings
${sublime_syntax_ready_batch_file}												Packages\Batch File\Batch File.sublime-settings
${sublime_syntax_ready_c}														Packages\C++\C.sublime-settings
${sublime_syntax_ready_c#}														Packages\C#\C#.sublime-settings
${sublime_syntax_ready_c#_build}												Packages\C#\Build.sublime-settings
${sublime_syntax_ready_c}														Packages\C++\C.sublime-settings
${sublime_syntax_ready_css}														Packages\CSS\CSS.sublime-settings
${sublime_syntax_ready_lua_gmod}												Packages\GMod Lua\Lua.tmLanguage
${sublime_syntax_ready_html}													Packages\HTML\HTML.sublime-settings
${sublime_syntax_ready_java}													Packages\Java\Java.sublime-settings
${sublime_syntax_ready_java_properties}											Packages\Java\JavaProperties.sublime-settings
${sublime_syntax_ready_java_server_pages}										Packages\Java\Java Server Pages (JSP).sublime-settings
${sublime_syntax_ready_javascript}												Packages\JavaScript\JavaScript.sublime-settings
${sublime_syntax_ready_json}													Packages\JavaScript\JSON.sublime-settings
${sublime_syntax_ready_markdown}												Packages\Markdown\Markdown.sublime-settings
${sublime_syntax_ready_php}														Packages\PHP\PHP.sublime-settings
${sublime_syntax_ready_text}													Packages\Text\Plain text.tmLanguage
${sublime_syntax_ready_python}													Packages\Python\Python.sublime-settings
${sublime_syntax_ready_regex}													Packages\Regular Expressions\RegExp.sublime-settings
${sublime_syntax_ready_sqf}														Packages\SQF Language\SQF.tmLanguage
${sublime_syntax_ready_sql}														Packages\SQL\SQL.sublime-settings
${sublime_syntax_ready_xml}														Packages\XML\XML.sublime-settings

//
// Syntax Files - These are variable extension.. If your Sublime Version supports it, and it is expected to exist, then .sublime-syntax is used.. Otherwise the older .tmLanguage is used.
//
${sublime_syntax_asp}															ASP\ASP.sublime-settings
${sublime_syntax_asp_html}														ASP\HTML-ASP.sublime-settings
${sublime_syntax_autohotkey}													AutoHotkey\AutoHotkey.sublime-settings
${sublime_syntax_batch_file}													Batch File\Batch File.sublime-settings
${sublime_syntax_c}																C++\C.sublime-settings
${sublime_syntax_c#}															C#\C#.sublime-settings
${sublime_syntax_c#_build}														C#\Build.sublime-settings
${sublime_syntax_c++}															C++\C++.sublime-settings
${sublime_syntax_css}															CSS\CSS.sublime-settings
${sublime_syntax_html}															HTML\HTML.sublime-settings
${sublime_syntax_java}															Java\Java.sublime-settings
${sublime_syntax_java_properties}												Java\JavaProperties.sublime-settings
${sublime_syntax_java_server_pages}												Java\Java Server Pages (JSP).sublime-settings
${sublime_syntax_javascript}													JavaScript\JavaScript.sublime-settings
${sublime_syntax_json}															JavaScript\JSON.sublime-settings
${sublime_syntax_markdown}														Markdown\Markdown.sublime-settings
${sublime_syntax_php}															PHP\PHP.sublime-settings
${sublime_syntax_python}														Python\Python.sublime-settings
${sublime_syntax_regex}															Regular Expressions\RegExp.sublime-settings
${sublime_syntax_sql}															SQL\SQL.sublime-settings
${sublime_syntax_xml}															XML\XML.sublime-settings

## .tmLanguage only...
${sublime_syntax_lua_gmod}														GMod Lua\Lua.tmLanguage
${sublime_syntax_text}															Text\Plain text.tmLanguage
${sublime_syntax_sqf}															SQF Language\SQF.tmLanguage


//
// Sublime Text Default Files
//

// Preferences
${sublime_filename_preferences}													Preferences.sublime-settings
${sublime_filename_platform_preferences}										Preferences (Windows).sublime-settings
${sublime_filename_distraction_free}											Distraction Free.sublime-settings
${sublime_filename_minimap}														Minimap.sublime-settings
${sublime_filename_regex_format_widget}											Regex Format Widget.sublime-settings
${sublime_filename_regex_widget}												Regex Widget.sublime-settings
${sublime_filename_widget}														Widget.sublime-settings

// .tmSettings
${sublime_filename_icon_markup}													Icon (Markup).tmPreferences
${sublime_filename_icon_source}													Icon (Source).tmPreferences
${sublime_filename_icon_text}													Icon (Text).tmPreferences
${sublime_filename_indentation_rules_comments}									Indentation Rules - Comments.tmPreferences
${sublime_filename_indentation_rules}											Indentation Rules.tmPreferences
${sublime_filename_indexed_symbol_list}											Indexed Symbol List.tmPreferences
${sublime_filename_symbol_list}													Symbol List.tmPreferences

// Build Files
${sublime_filename_syntax_tests}												Syntax Tests.sublime-build

// KeyMaps / MouseMaps
${sublime_filename_platform_keymap} || ${sublime_filename_keymap}				Default (Windows).sublime-keymap && Default (Windows).sublime-keymap
${sublime_filename_platform_mousemap} || ${sublime_filename_mousemap}			Default (Windows).sublime-mousemap && Default (Windows).sublime-mousemap



// Menus
${sublime_filename_menu_context}												Context.sublime-menu
${sublime_filename_menu_encoding}												Encoding.sublime-menu
${sublime_filename_menu_find_in_files}											Find in Files.sublime-menu
${sublime_filename_menu_indentation}											Indentation.sublime-menu
${sublime_filename_menu_main}													Main.sublime-menu
${sublime_filename_menu_side_bar_mount_point}									Side Bar Mount Point.sublime-menu
${sublime_filename_menu_side_bar}												Side Bar.sublime-menu
${sublime_filename_menu_syntax}													Syntax.sublime-menu
${sublime_filename_menu_tab_context}											Tab Context.sublime-menu
${sublime_filename_menu_widget_context}											Widget Context.sublime-menu

// Commands
${sublime_filename_command_default}												Default.sublime-commands

// Macros
${sublime_filename_macro_add_line_before}										Add Line Before.sublime-macro
${sublime_filename_macro_add_line_in_braces}									Add Line in Braces.sublime-macro
${sublime_filename_macro_add_line}												Add Line.sublime-macro
${sublime_filename_macro_delete_left_right}										Delete Left Right.sublime-macro
${sublime_filename_macro_delete_line}											Delete Line.sublime-macro
${sublime_filename_macro_delete_to_bol}											Delete to BOL.sublime-macro
${sublime_filename_macro_delete_to_hard_bol}									Delete to Hard BOL.sublime-macro
${sublime_filename_macro_delete_to_hard_eol}									Delete to Hard EOL.sublime-macro


//
// Sublime Text File Extensions
//
${sublime_ext_settings}															.sublime-settings
${sublime_ext_tm_preferences}													.tmPreferences
${sublime_ext_build}															.sublime-build
${sublime_ext_commands}															.sublime-commands
${sublime_ext_keymap}															.sublime-keymap
${sublime_ext_mousemap}															.sublime-mousemap
${sublime_ext_menu}																.sublime-menu
${sublime_ext_macro}															.sublime-macro


//
// Contributors - The following simply lists where each variable came from...
//

// Acecool Library - edit_settings_plus or AcecoolLib_Sublime or AcecoolLib_Python
user, default, cache, packages_installed
package, user_package
syntax / language / lang, user_syntax, syntax_ext, syntax_file, syntax_path, syntax_path_base
extension / ext
architecture / arch
repo
version_sublime

// Sublime Text - Active Window Variables using: sublime.active_window( ).extract_variables( )
platform
packages
project, project_path, project_name, project_base_name, project_extension
file, folder, file_path, file_name, file_base_name, file_extension


//
// Default Data
//


// Preferences Default Data:		${edit_settings_plus_default_data_preferences}
------------------------------------------------------------------------------------------------------------------------------
//
// Sublime Text - Configuration - User
//
{
	
}

------------------------------------------------------------------------------------------------------------------------------


// Preferences Default data:		${edit_settings_plus_default_data_platform_preferences}
------------------------------------------------------------------------------------------------------------------------------
//
// Sublime Text - Windows Configuration - User
//
{
	
}

------------------------------------------------------------------------------------------------------------------------------


// KeyMap Default data:				${edit_settings_plus_default_data_platform_keymap}
------------------------------------------------------------------------------------------------------------------------------
//
// Sublime Text - Windows KeyMap Configuration - User
//
{
	
}

------------------------------------------------------------------------------------------------------------------------------


// MouseMap Default data:			${edit_settings_plus_default_data_platform_mousemap}
------------------------------------------------------------------------------------------------------------------------------
//
// Sublime Text - Windows MouseMap Configuration - User
//
{
	
}

------------------------------------------------------------------------------------------------------------------------------


// Syntax Default data:				${edit_settings_plus_default_data_syntax_settings}
------------------------------------------------------------------------------------------------------------------------------
//
// Sublime Text - Python Syntax Configuration - User
//
{
	
}

------------------------------------------------------------------------------------------------------------------------------


// Menu Default data:				${edit_settings_plus_default_data_menu}
------------------------------------------------------------------------------------------------------------------------------
//
// Sublime Text = AcecoolCodeMappingSystem - ACMS_EXPANDABLE_VARS_EXAMPLE Menu - Custom
//
[
	
]

------------------------------------------------------------------------------------------------------------------------------

Note: I plan on adding default file links such as {default_preferences}, {user_preferences}, {default_platform_preferences}, {user_platform_preferences} and more which will link to places such as %AppData%/Sublime Text 3/Packages/Default/Preferences.sublime-settings, %AppData%/Sublime Text 3/Packages/user/Preferences.sublime-settings, %AppData%/Sublime Text 3/Packages/Default/Preferences (Windows).sublime-settings, %AppData%/Sublime Text 3/Packages/user/Preferences(Windows).sublime-settings automatically using the appropriate paths, platforms, etc…

If you can think of useful shortcuts to use, let me know and I’ll add them in…

0 Likes

#4

Reserved Reserved for future content

0 Likes

#5

Reserved Reserved for future content

Reserved Reserved for future content

Reserved Reserved for future content

0 Likes

#6

Because that command was introduced relatively late in the ST3 beta, and package developers didn’t want to lock out large portions of users who were on the previous stable release.

At this point it is probably safe to use, although it will require package developers to version-gate their new release with build 3116.

2 Likes

#7

For some reason my post was never added…

Cheers, I wasn’t aware of that - but what is stopping from people adding it as a viable option or adding the file for supporting it to their plugin for backwards compatibility?

Anyone using Version 3 should have access to it because of updates, but for Version 2 there should be a way to incorporate features into library files which can be distributed with plugins to ensure functionality can be added to version 2…

Do you have the stats on how many people are using each version? Are those stats available to the public, or developers?

0 Likes

#8

Nothing in particular. I suspect it is mostly that they just never went back to change the command being run from their menus in the packages that existed for 3 years or longer. Even some of my old packages are still guilty of that. Either they just forgot about the new command and that they haven’t changed it in their package yet, or they just haven’t updated the package at all in quite a while, and there are a couple of those.
There is no particular reason not to use the edit_setting command nowadays, unless you still want to support ancient builds (which includes ST2).

Adding another command certainly won’t solve that problem, though.

Will shared some stats from last year, about one month after ST3 was released, based on Package Control installs. Iirc about 2-5% were on ST2 at the time.

1 Like

#9

but what is stopping from people adding it as a viable option or adding the file for supporting it to their plugin for backwards compatibility?

What is stopping me is I never ever use the menus entries to do something with a package because it is too hard to find the package as the packages list is too big and hit that small black arrow to scroll down is awful:

To open a setting file I just use the Side-by-Side Settings package. I had it bind to Ctrl+k, Ctrl+s, then, I just type the plugin name:

In case I forgot the package name, then, I may use the old school menu just to rediscover the package name.

And when creating a new package, I will probably copy/paste some old menu file and it will still be using the old style menu.

0 Likes

#10

To open a setting file I just use the Side-by-Side Settings package

you can use this patch as an alternative for this, it works for other preferences files (menus, keymaps, mousemaps) as well.

0 Likes

#11

@FichteFoll - Adding another command can help…

edit_settings_plus is just like edit_settings, but better… For addons with more than 1 settings file, or if you want to open all of the files associated in a single command you can… For instance, lets say you have key binds for your addon and want to open up sublime text key binds / mouse / etc… you can set up a single command to open up an unlimited number of files on the left / base and right / user side.

On top of being able to open many files, I’ve added file linking. If you save an edit on one side, and the other side is unsaved, it’ll save both, it doesn’t just save random files though, it saves the linked file… File linking so if I have ACMS_Definitions.sublime-settings, ACMS_Plugin.sublime-settings, and ACMS_Mapping.sublime-settings ( I have more ) and I open all 3 in the left and also all 3 User files of the same name in the right. If I edit Mapping on the left ( since I have developer mode enabled, otherwise default / left side data can’t be edited ) and right, and I save either, both save… Also if I click Definitions or Mapping or whatever in the left or right side, it opens the linked file in the other panel too.

All of these features equates to efficiency. Not having to open the default and user files manually saves time. Not having to traverse the menus multiple times also saves time.

I also added res:// file reading - it is automatic so if a plugin isn’t extracted, it will automatically load the file from the packed package. Also, any user file not created gets set up with default data ( marked as unedited to prevent a bunch of ‘this file is not saved’ window from opening - until you edit it )…

I added a ton of expandable variables too which works in file content, file names for loading files and more. This means you can easily open up sublime/_plugin.py file simply by using ${sublime_install_path}${slash]sublime.py ( the slash used is based on the OS and the path is read from Sublime Text ) - I probably went overboard on the expanded variables list, there are a lot, but I wanted to ensure everything could be easily accessible with as little text as possible in addition to being fully cross-platform compatible.

@addons_zz - I completely agree. The menu system is hectic. I wish it was simplified a little. All of the nested menus shouldn’t be necessary if it was organized another way.

I don’t have the up / down arrow probably because I don’t have enough addons installed, and I have a 4k monitor on my primary in addition to extra 1080p monitors.

Am I to assume correctly that the arrow smoothly or slightly choppily scrolls the menu as you hover over or click? If so, it should be changed so if you click it goes page down / up and both arrows should be visible at all times along with the number of pages, the current page number, etc… And, when you re-open the menu, the page you last used should be the one loaded…

I may look into that.

Also, side by side settings seems like an interesting plugin. One of my current goals though is to rewrite the sublime text settings system because it is very resource hungry. If you do something like settings_object( ‘key’, settings_runtime( ‘key’, settings_mapping( ‘key’, 'default ) ) ) and you do it frequently enough, it can cause a lot of lockups… It’s funny though because when you load the settings object into memory it is supposed to be in memory and it should be O( 1 ) but it is very problematic.

On top of that, it doesn’t support inheritance. So if there is a table in the default and you want to replace a single key, you have to copy the entire table into the user settings file instead of copying the table and one key with the change… I am going to fix that…

@All - Another reason I made this, not just for efficiency although that is a primary reason, is because of those of us with deficits such as those with carpel tunnel, visual deficits, muscle spasms, and more can encounter a lot of problems while trying to navigate a menu and if a muscle spasm knocks the mouse off the menu and it collapses you have to start from scratch.

Now, imagine that happening frequently, and having to open 4, 10, or more just to configure a single plugin and see what the plugin has in terms of options. This is why I’m pushing edit_settings and edit_settings_plus so much.

I do like the side by side settings addon now that I know about it because it eliminates the need to go through the menu - but it looks like it only lists the settings files one by one instead of setting up a menu layout ( similar to Resource Extractor, what’s it called? where you can use arrows, press enter, use … t go up and browse files, etc… )… If the entire menu system could be navigated that way, and not close when you open something ( also like the resource plugin ) then that’d also help. Then you’d only have to press enter on a few entries and it wouldn’t close…

I may actually make a menu system which loads the default menu that way so any changes would be supported… I could also make it so any open_file thing for settings would automatically be switched to edit_settings or edit_settings plus if multiple files are to be opened to make it even better…

Thanks for the idea @addons_zz

@AmjadHD - A patch is a great idea, I’ll look into it. But I think I’m going to make a complete menu replacement using the command palette so you can navigate without it closing unless you press escape, or whatever, and can go up / down, nested unlimited, and some things combine for the sake of efficiency.

First, I need to finish my current plugin. I may be able to speed it up by changing the settings system only so I’m actually looking into that now.

0 Likes

#12

Give a look into the https://packagecontrol.io/packages/QuickSettings package, it seems related to your idea.

0 Likes