Simply exporting them to file - say 'myshortcuts.dat' makes a list as a text file thus.
[Accelerators]
Count=64
0 0 0 Space selectSelectionTool:
0 0 0 L selectLineTool:
0 0 0 E selectEraseTool:
0 0 0 C selectCircleTool:
0 0 0 A selectArcTool:
0 0 0 M selectMoveTool:
...
The 0 0 0 fields represents modifier keys Ctrl/Alt/Shift, so
0 0 0 H editHide:
0 0 1 H Edit/Unhide/All ###shift
This is used to Import your setting in the Preferences window.
To ensure that they over-write any pre-existing ones you really need to edit the Windows Registry [ ๐ค - be verycareful!]...
HKEY_CURRENT_USER\Software\Google\Sketchup7\Settings Num_Shortcuts = REG_DWORD = 64 [or total of list length] Shortcut_1 = REG_SZ = "0 0 0 Space selectSelectionTool:" Shortcut_2 = REG_SZ = "0 0 0 L selectLineTool:"
etc...
You would 'empty' the 'Settings' prior to re-importing new ones ?
Don't try this unless you know what you are doing... else= ๐ฎ
If you did then you could [with SUp closed] use a batch file to clear the Registry's '...\Settings' entries and then use those saved in the 'myshortcuts.dat' etc to remake those entries to suit...
An alternative way to get a list of shortcuts is using the Ruby Console command:
myshortcuts_array=Sketchup.get_shortcuts
which returns an array of tab delimited shortcuts - e.g.
["Ctrl+A\tEdit/Select All", "Ctrl+C\tEdit/Copy", ...]
You could manipulate each entry in that array and puts it into an external file [ myshortcuts_file="...\\myshortcuts.dat" ?] - this is equivalent to Exporting your current shortcut settings from Preferences - e.g. "Ctrl+A\tEdit/Select All" >>becomes***>> "1 0 0 A Edit/Select All"
###becomes 'simplied' - the testing and pattern matching is 'cod' here == it's NOT real code !
text=myshortcuts_array[i]
ctrl = "1 " if text.includes "Ctrl" else ctrl = "0 "
alt = "1 " if text.includes "Alt" else alt = "0 "
shift = "1 " if text.includes "Shift" else shift = "0 "
key = text.split("+")[1].split("\t")[0]
command = " " + text.split("+")[1].split("\t")[1]
line = ctrl+alt+shift+key+command
myshortcuts_file.puts(line)
###
You could make the script auto-run on close and always keep a list of your current shortcuts ? You could then reimport them as desired using Preferences/Import or using a Registry batch-file lash-up...
Hope there're a few ideas there...