Sublime Forum

TortoiseSVN, TortoiseGit and TortoiseHg Plugin

#18

I’m running TortoiseHg 2.0.2 (with Mercurial 1.8.1) for windows 7 64bit. I’ve been using it since TortoiseHg 1.1.5 (with Mercurial 1.7). It’s totally weird. I tryed repairing the install but it hasn’t added it :stuck_out_tongue:

0 Likes

#19

A removal and reinstall didn’t help either :stuck_out_tongue:

Very strange. Must just be my karma.

0 Likes

#20

TortoiseHg 2.0 has migrated to PyQt from PyGtk.
I suppose hgtk.exe doesn’t exists anymore and was replaced with a new executable, check your installation folder and try with the exe files it contains.
With a little luck it could work without changing the ST2 plugin source.

0 Likes

#21

Well it would appear that hg.exe opens cmd so it looks like the replacement but this plugin won’t accept that as the file.

0 Likes

#22

Nope, hg.exe is the standard Mercurial binary, not the TortoisHg that I suppose this plugin need.

Sorry I don’t have a TortoisHg installed and couldn’t install it.
Look for something like hgqt.exe or thgqt.exe

But maybe the command line parameters as changed and the plugin is not compatible.

0 Likes

#23

@firefusion

I’ve updated the plugin to work with the new exe filename for TortoiseHg 2.x. You can grab the latest version from github.com/wbond/sublime_tortoi … all/master.

0 Likes

#24

Ok the context menu items show up but it’s still not working. I’m not sure what I’m meant to have in Tortoise.sublime-settings. If I uncomment the default and change the file name to thg…

{ "hg_hgtk_path": r"C:\Program Files\TortoiseHg\thg.exe", }

I get this error…

http://dl.dropbox.com/u/497583/screenshots/st-tor.png

If I fix it to what I think it should be it doesn’t work.

{ "hg_hgtk_path": "C:\\Program Files\\TortoiseHg\\thg.exe" }

0 Likes

#25

@firefusion

You are good at finding all of my bugs. :smile: Sorry for all of the little glitches along the way. I have fixed the plugin so the example settings file is correct and so that settings are properly used. Be sure to grab the latest zip from github.com/wbond/sublime_tortoi … all/master.

That said, you should not need to set anything in your Tortoise.sublime-settings since you have TortoiseHg installed in a default location.

0 Likes

#26

[quote=“wbond”]@firefusion

You are good at finding all of my bugs. :smile:[/quote]

Yeah sorry :smile:

Still no luck with the new build and no lines in the sublime-settings file. I did notice that if I launch thg.exe manually it opens the tortoise workbench after the command line. I tried change the plugin to just hg.exe as it looked like the only other files that it might be but still no luck :stuck_out_tongue:

0 Likes

#27

@firefusion

What does your console say?

Try commenting out all of the settings in Tortoise.sublime-settings and see if it works. I was successfully running TortoiseHg with custom settings and with default settings on the latest version of Sublime Tortoise.

0 Likes

#28

Ok this is what it says on startup with a fresh tortoise download and without the custom path setting active. No error or anything is output when I try any of the commands (via right click or shortcut).

startup, version: 2050 windows x64 channel: dev executable: /C/Program Files/Sublime Text 2/sublime_text.exe working dir: /C/Windows/system32 packages path: /C/Users/robin/AppData/Roaming/Sublime Text 2/Packages settings path: /C/Users/robin/AppData/Roaming/Sublime Text 2/Settings error parsing session: No data at: 0:0 PackageSetup not required catalogue loaded found 1 files for base name Default.sublime-theme found 6 files for base name Default (Windows).sublime-keymap found 1 files for base name Default (Windows).sublime-mousemap found 1 files for base name Main.sublime-menu Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\comment.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\copy_path.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\delete_word.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\detect_indentation.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\duplicate_line.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\echo.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\exec.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\find_under_expand.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\font.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\goto_line.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\indentation.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\kill_ring.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\mark.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\new_templates.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\paragraph.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\save_on_focus_lost.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\scroll.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\side_bar.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\sort.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\swap_line.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\switch_file.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\transform.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\transpose.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Default\trim_trailing_white_space.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Diff\diff.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\HTML\html_completions.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\HTML\zen_core.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\Tortoise\Tortoise.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\ZenCoding\A1Zen.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\ZenCoding\dynamicsnippets.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\ZenCoding\initzen.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\ZenCoding\multizen.py Reloading plugin C:\Users\robin\AppData\Roaming\Sublime Text 2\Packages\ZenCoding\zc.py loading bindings loading pointer bindings theme loaded app ready loaded 1147 snippets

If i try with the custom path setting nothing happens still on keyboard commands or using the right click items.

Writing file /C/Users/robin/AppData/Roaming/Sublime Text 2/Packages/Tortoise/Tortoise.sublime-settings with encoding UTF-8
reloading /C/Users/robin/AppData/Roaming/Sublime Text 2/Packages/Tortoise/Tortoise.sublime-settings
0 Likes

#29

@firefusion

So there are entries in the right-click menu?

Please paste the following into your console

sublime.log_commands(True)

Then try typing ctrl+alt+c. You should see the following in your console.

command: tortoise_commit

If you don’t, your keyboard settings must be messed up.

You can also explicitly run the commit command by pasting the following into your console. You will need to have a file open from your Hg repository for this to work.

sublime.active_window().active_view().run_command('tortoise_commit')

I’m not sure where to go debugging from there. I am running the same OS, same version of Sublime and the same version of TortoiseHg as you, and everything works perfectly fine.

0 Likes

#30

It does indeed list the commands in the log as it’s meant to (command: tortoise_commit etc). The command to explicitly commit did nothing i’m afraid. I tried removing any plugins I had in sublime but no luck. I’ll keep playing and let you know if I ever fix it :stuck_out_tongue:

0 Likes

#31

Does this depend on Tortoise* for getting the functionality it needs? In other words, would it be possible to make it run on linux, where there are no tortoises :smile: ?

0 Likes

#32

@quesada

Yes, it does depend on Tortoise, specifically because all the plugin does it launch the various Tortoise* dialog windows.

For most Linux users I would imagine it would probably be most useful just to open the terminal in the root of the repository. I vaguely recall there being development of a Nautilus plugin like TortoiseSVN, but I don’t know the progress of that. If it was in a usable state, it probably wouldn’t be too much work to adapt the plugin to launch the Nautilus plugin.

0 Likes

#33

I just fixed a bug with the detection of the svn binary path, which is used for the context menu. If you get a chance, let me know if the latest version works for you. Thanks!

0 Likes

#34

Sorry it’s a while since I last checked this thread. With the latest version of tortoisehg and sublime it’s not even showing the right click menu anymore.

0 Likes

#35

@firefusion

Is there still nothing in the ST2 console?

0 Likes

#36

Within the past few days I fixed some bugs with this package, including issues with file paths that contain spaces, and an issue with file statuses not being properly cached. I hoping this should resolve the issues for a number of people. There are some settings that allow turning off the context menus, but also a debug setting in case users are having performance issues with the menus.

There is now a new preferred way to upgrade the plugin. I’ve just finished writing a package manager that includes auto update functionality. If you install Package Control (wbond.net/sublime_packages/package_control) and run Upgrade Package and select Tortoise, you’ll then automatically get upgraded whenever a new version comes out.

There is also now a webpage that includes some screenshots and documentation for the plugin. You can check it out at wbond.net/sublime_packages/tortoise.

0 Likes

#37

Yay! This plugin finally works for me!

Thank you :smile:

0 Likes