not working on OSX via Package control installation #1

francoiskha opened this Issue Nov 15, 2011 · 11 comments

4 participants


I could not make it work on OSX. I installed indent XML via Package control but there is no command available.

@alek-sys alek-sys was assigned Nov 16, 2011

thanks for your comment.
In package folder there is file Default (Windows).sublime-keymap - with keymaps for Windows.
Because I have no Mac I'm not sure I can create correct shortcut for it (I'm not even sure that it has Ctrl key :) ).
So if you are able to create appropriate keymap file for OSX and commit it to github - it would be great. Anyway I'll try to find Mac and add keymap by myself, but it can take a time.

Regards, Alexey.


Hi and thanks for answering so fast

I am not very familiar with Sublime Text 2 (just discovered it). But I will contribute a .sublime-keymap file for OSX. Macs does have a ctrl key though and creating a .sublime-keymap with

{ "keys": ["super+k", "super+f"], "command": "indentxml" }

doesn't work either.
There is probably another problem, I can't run the command "indent xml" or "indentxml". Do you have a way to read logs ? the sublime text console just does not record anything from package installation. As I said I installed from Package Control but moving the files to Packages/User doesn't make it work either.


Ok, here are couple ideas you could check:
1) Launch SublimeText and check console (Ctrl+~) in Windows - is there a line like "Reloading plugin \Packages\Indent XML\"
2) Try to select XML, open console and type view.run_command('indentxml') - this should run command without any hotkeys
3) Try to add keyboard shortcut to User keybindings - open Preferences - "Key bindings - User" and add you hotkey there.

Have you tried to use any other key combination? Like "super+m" - just for test?

P.S. Just checked defaul bindings for OSX and "show console" marked there as "ctrl+backquote". Not sure how it's possible not having control :)


Ok, just checked this on Mac. Installed Sublime Text and Indent XML from "Package control".
They tried super+k, super+f - and it works ok.

Just to clarify, key combination is: press super, press k (do not release super!) and press f then.
May be it looks weird but i just used to it in Visual Studio :)

Hope this helps!


ok so the problem was basically between the keyboard and the chair. I did not understood i had to select the xml text to indent it. I think it would be cool to indent the whole file if nothing is selected. Anyway, it works, i close the issue. Thanks for investigating.


In latest version plugin will check if any text selected, if no - all current document fill be formated.


I've just tested and it works like a charm. Thank you.


Visual Studio does this behavior using (Ctrl+K, Ctrl+D) while keeping the (Ctrl+K, Ctrl+F) reserved for current selections only. Should this do the same?


I'm not quite sure that is good to have two hotkeys for this simple plugin. For me behavior looks clear: when I press ctrl+k, ctrl+f selected text should be formated, if no text selected - all document.


ok, that makes sense.


I'm sorry for reopening a closed case, but is there a way to use this script for indentation, edit and then go back to human unreadable form again? The indent xml works like a charm, I was wondering if there was a way to un-indent as well.

Thanks, again..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment