Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add match_current_position flag to GsInlineDiffCommand #1137

Merged
merged 1 commit into from
Jul 6, 2019

Conversation

kaste
Copy link
Collaborator

@kaste kaste commented Jul 5, 2019

If set to true it will jump to the correct position you were editing in the
inline diff.

E.g. a keybinding

  {
      "keys": ["ctrl+shift+["],
      "command": "gs_inline_diff",
      "args": { "match_current_position": true }
  },

Workflow: edit buffer/file, save, issue command, inline diff will show up and jump to the correct position you were on while editing, ctrl+tab or ctrl+w to continue editing on the file, and so on.

pt = view.text_point(row, col)
view.sel().add(sublime.Region(pt, pt))
view.show_at_center(pt)
view.show_at_center(pt)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

twice?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch, removed that.

If set to true it will jump to the correct position you were editing in the
inline diff.
@stoivo stoivo merged commit 7fd517b into timbrel:dev Jul 6, 2019
@kaste kaste deleted the inline-diff-jump-to branch July 7, 2019 07:14
@kaste kaste mentioned this pull request Oct 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants