rscherf / GitLink

Open your Sublime Text files on GitHub, Bitbucket, Gitlab or Codebase
http://ryan.sc
35 stars 25 forks source link

Bitbucket support #1

Closed naro closed 9 years ago

naro commented 9 years ago

Hi,

I have added bitbucket support. There are also couple of other fixes:

path = /path/to/project/src/project/packages/folder
basename = 'project'
produced wrong remote_path 'src' instead of /src/project/packages/folder
rscherf commented 9 years ago

This is great and also begs the question if we should rename the plugin to RepoLink instead of GithubLink. I don't use BitBucket, but I'm sure many do.

I'll test this tonight, but in the meantime could switch all your 4 space tabs to 2 for consistency?

naro commented 9 years ago

what about GitLink ? When I was trying to find if there is a plugin for this feature, I tried to search for "bit...." in package control but nothing found. Then I tried to browse 'git' plugins and found GithubLink.

4 space to 2 ? I will do it if you prefer that. I'm used to 4 spaces as defined by PEP8 but I can change it if you wish.

rscherf commented 9 years ago

Sure, we can stick to 4 spaces. I'm used to Rails, which is why I made the suggestion. I don't know much about Python as evidenced from my code -- just hacked it together.

rscherf commented 9 years ago

Please update the name to GitLink, and I'll make sure package control gets changed.

naro commented 9 years ago

Ok, will do.

naro commented 9 years ago

Hi, I have renamed the package and sources. I have realized weird behavior before the rename and also after it. I don't know why, but the menu items are disabled. All GitLink sidebar and context menu subitems are disabled. I saw this before I started to modify the plugin - just after I installed it for the first time - and also now. Have you ever experience this behavior? I don't know how to make it work. Tried to restart ST several times.

rscherf commented 9 years ago

I think your problem is the naming of the command. Should be

"GitlinkCommand" not "GitLinkCommand"

If you look back at my source, it was originally GithublinkCommand. Weird case sensitivity in SublimeText.

On Nov 22, 2014, at 7:39 AM, Radim Novotný notifications@github.com wrote:

Hi, I have renamed the package and sources. I have realized weird behavior before the rename and also after it. I don't know why, but the menu items are disabled. All GitLink sidebar and context menu subitems are disabled. I saw this before I started to modify the plugin - just after I installed it for the first time - and also now. Have you ever experience this behavior? I don't know how to make it work. Tried to restart ST several times.

— Reply to this email directly or view it on GitHub.

naro commented 9 years ago

Yay, that's right. Changed it and commands appeared. GitLinkCommand class produces git_link command name. GitlinkCommand productes gitlink command name. Thanks. Pushing the fix in a sec.