Shortcut to move to a specific part of a text fileSublime Text 3 API : Get all text from a fileHow do I move to end of line in Vim?Set default syntax to different filetype in Sublime Text 2How do I reformat HTML code using Sublime Text 2?Indenting code in Sublime text 2?Sublime Text 2 - View whitespace charactersSublime Text 2 - Show file navigation in sidebarWhat is the shortcut to Auto import all in Android Studio?Sublime Text: Select all instances of a variable and edit variable nameComparing the contents of two files in Sublime TextSublime Text - Shortcut to move cursor to “found” text?

Point of the the Dothraki's attack in GoT S8E3?

Which module had more 'comfort' in terms of living space, the Lunar Module or the Command module?

Verb "geeitet" in an old scientific text

Does a card have a keyword if it has the same effect as said keyword?

Why is "Vayechulu" said 3 times on Leil Shabbat?

Why do people keep telling me that I am a bad photographer?

I need a disease

Manager is threatening to grade me poorly if I don't complete the project

I'm in your subnets, golfing your code

Pressure inside an infinite ocean?

Why was the battle set up *outside* Winterfell?

What is a smasher?

How can modem speed be 10 times slower than router?

Why is B♯ higher than C♭ in 31-ET?

Did we get closer to another plane than we were supposed to, or was the pilot just protecting our delicate sensibilities?

Hyperlink on red background

How important is people skills in academic career and applications?

Can an isometry leave entropy invariant?

Out of scope work duties and resignation

How can I support myself financially as a 17 year old with a loan?

Why isn't nylon as strong as kevlar?

What are the differences between credential stuffing and password spraying?

Randomness of Python's random

What are the advantages of luxury car brands like Acura/Lexus over their sibling non-luxury brands Honda/Toyota?



Shortcut to move to a specific part of a text file


Sublime Text 3 API : Get all text from a fileHow do I move to end of line in Vim?Set default syntax to different filetype in Sublime Text 2How do I reformat HTML code using Sublime Text 2?Indenting code in Sublime text 2?Sublime Text 2 - View whitespace charactersSublime Text 2 - Show file navigation in sidebarWhat is the shortcut to Auto import all in Android Studio?Sublime Text: Select all instances of a variable and edit variable nameComparing the contents of two files in Sublime TextSublime Text - Shortcut to move cursor to “found” text?






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty height:90px;width:728px;box-sizing:border-box;








1















I'd like to create a keyboard shortcut (such as CTRL+T) that automatically moves the cursor to the line after the occurence of a fixed text, such as &todo.



Example:



foo 
bar
&todo
fix bug #783
blah
blah2


Pressing CTRL+T would automatically move the cursor to the line beginning with fix ....



Currently I'm doing it like this:




  • CTRL F

  • enter &todo, ENTER


  • ESCAPE (closes the Search bottom panel)

  • HOME


  • DOWN ARROW (moves to next line)

but this requires too many actions.



How to do that in a single key shortcut?










share|improve this question






























    1















    I'd like to create a keyboard shortcut (such as CTRL+T) that automatically moves the cursor to the line after the occurence of a fixed text, such as &todo.



    Example:



    foo 
    bar
    &todo
    fix bug #783
    blah
    blah2


    Pressing CTRL+T would automatically move the cursor to the line beginning with fix ....



    Currently I'm doing it like this:




    • CTRL F

    • enter &todo, ENTER


    • ESCAPE (closes the Search bottom panel)

    • HOME


    • DOWN ARROW (moves to next line)

    but this requires too many actions.



    How to do that in a single key shortcut?










    share|improve this question


























      1












      1








      1








      I'd like to create a keyboard shortcut (such as CTRL+T) that automatically moves the cursor to the line after the occurence of a fixed text, such as &todo.



      Example:



      foo 
      bar
      &todo
      fix bug #783
      blah
      blah2


      Pressing CTRL+T would automatically move the cursor to the line beginning with fix ....



      Currently I'm doing it like this:




      • CTRL F

      • enter &todo, ENTER


      • ESCAPE (closes the Search bottom panel)

      • HOME


      • DOWN ARROW (moves to next line)

      but this requires too many actions.



      How to do that in a single key shortcut?










      share|improve this question
















      I'd like to create a keyboard shortcut (such as CTRL+T) that automatically moves the cursor to the line after the occurence of a fixed text, such as &todo.



      Example:



      foo 
      bar
      &todo
      fix bug #783
      blah
      blah2


      Pressing CTRL+T would automatically move the cursor to the line beginning with fix ....



      Currently I'm doing it like this:




      • CTRL F

      • enter &todo, ENTER


      • ESCAPE (closes the Search bottom panel)

      • HOME


      • DOWN ARROW (moves to next line)

      but this requires too many actions.



      How to do that in a single key shortcut?







      keyboard-shortcuts sublimetext2 sublimetext sublime-text-plugin






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Mar 23 at 10:36









      mattst

      5,52832130




      5,52832130










      asked Mar 20 at 13:49









      BasjBasj

      6,23334115248




      6,23334115248






















          2 Answers
          2






          active

          oldest

          votes


















          1














          The best solution is it use a plugin to do that.



          The plugin below does what you require. It will find the next occurrence of pattern (i.e. the &todo marker) below the current cursor position, move the cursor to the line below it, and centre that position in the window. If the pattern is not found below the current cursor position it will search again from the top of the buffer providing a wrap around feature.



          Copy and paste the following Python code into a buffer and save it in your Sublime Text config User folder as GoToPattern.py.



          import sublime
          import sublime_plugin

          class GotoPatternCommand(sublime_plugin.TextCommand):

          def run(self, edit, pattern):

          sels = self.view.sel()
          # Optional flags; see API.
          flags = sublime.LITERAL | sublime.IGNORECASE
          start_pos = sels[0].end() if len(sels) > 0 else 0
          find_pos = self.view.find(pattern, start_pos, flags)

          if not find_pos and start_pos > 0:
          # Begin search again at the top of the buffer; wrap around
          # feature, i.e. do not stop the search at the buffer's end.
          find_pos = self.view.find(pattern, 0, flags)

          if not find_pos:
          sublime.status_message("'' not found".format(pattern))
          return

          sels.clear()
          sels.add(find_pos.begin())
          self.view.show_at_center(find_pos.begin())
          row, col = self.view.rowcol(find_pos.begin())
          self.view.run_command("goto_line", "line": row + 2)
          # Uncomment for: cursor to the end of the line.
          # self.view.run_command("move_to", "to": "eol")


          Add key bindings:



          // The pattern arg, i.e. "&todo", can be changed to anything you want
          // and other key bindings can also be added to use different patterns.
          "keys": ["???"], "command": "goto_pattern", "args": "pattern": "&todo"


          Add a Command Palette entry to Default.sublime-commands if you want:



          "caption": "GoToPattern: &todo", "command": "goto_pattern", "args": "pattern": "&todo",


          These links may be useful to you ST v. 2 API and ST v. 3 API.



          P.S. Did you know that Sublime Text has bookmarks? [Just in case you didn't.]






          share|improve this answer
































            0














            I found a solution: to do this, first create a gototodo.py file in "C:UsersUserAppDataRoamingSublime Text 2PackagesUser" containing:



            import sublime, sublime_plugin

            class GototodoCommand(sublime_plugin.TextCommand):
            def run(self, edit):
            contents = self.view.substr(sublime.Region(0, self.view.size())) # https://stackoverflow.com/questions/20182008/sublime-text-3-api-get-all-text-from-a-file
            a = contents.find('&todo')
            cursors = self.view.sel()
            cursors.clear()
            location = sublime.Region(a, a)
            cursors.add(location)
            self.view.show_at_center(location)

            (row, col) = self.view.rowcol(self.view.sel()[0].begin()) # go to the next line
            self.view.run_command("goto_line", "line": row+2)


            Then add this in "C:UsersUserAppDataRoamingSublime Text 2PackagesUserDefault (Windows).sublime-keymap":



             "keys": ["ctrl+t"], "command": "gototodo" 


            Done!






            share|improve this answer

























            • No need for import subprocess. Your plugin will only ever move the cursor to the first occurrence of "&todo".

              – mattst
              Mar 27 at 17:07












            • Sublime Text version 3 has been stable for 5+ years and is almost certainly a much better choice than the very old version 2 which was last updated in 2013. Version 3 has been out of beta for several years and it is the default download on SublimeText.com.

              – mattst
              Mar 27 at 17:09











            • @mattst You're right about subprocess, I first included it because of something totally different (nearly another plugin), but you're right, it should be removed. I'll edit now.

              – Basj
              Mar 27 at 22:48











            • @mattst About ST version: would this code here run perfectly on ST3 or would a few modifications be required here?

              – Basj
              Mar 27 at 22:49






            • 1





              No modifications needed, it works fine, I tested it to make sure. Note that ST2 and ST3 can both be installed on the same computer while you make the transition from version 2 to 3.

              – mattst
              Mar 28 at 12:28











            Your Answer






            StackExchange.ifUsing("editor", function ()
            StackExchange.using("externalEditor", function ()
            StackExchange.using("snippets", function ()
            StackExchange.snippets.init();
            );
            );
            , "code-snippets");

            StackExchange.ready(function()
            var channelOptions =
            tags: "".split(" "),
            id: "1"
            ;
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function()
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled)
            StackExchange.using("snippets", function()
            createEditor();
            );

            else
            createEditor();

            );

            function createEditor()
            StackExchange.prepareEditor(
            heartbeatType: 'answer',
            autoActivateHeartbeat: false,
            convertImagesToLinks: true,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: 10,
            bindNavPrevention: true,
            postfix: "",
            imageUploader:
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            ,
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            );



            );













            draft saved

            draft discarded


















            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55262326%2fshortcut-to-move-to-a-specific-part-of-a-text-file%23new-answer', 'question_page');

            );

            Post as a guest















            Required, but never shown

























            2 Answers
            2






            active

            oldest

            votes








            2 Answers
            2






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes









            1














            The best solution is it use a plugin to do that.



            The plugin below does what you require. It will find the next occurrence of pattern (i.e. the &todo marker) below the current cursor position, move the cursor to the line below it, and centre that position in the window. If the pattern is not found below the current cursor position it will search again from the top of the buffer providing a wrap around feature.



            Copy and paste the following Python code into a buffer and save it in your Sublime Text config User folder as GoToPattern.py.



            import sublime
            import sublime_plugin

            class GotoPatternCommand(sublime_plugin.TextCommand):

            def run(self, edit, pattern):

            sels = self.view.sel()
            # Optional flags; see API.
            flags = sublime.LITERAL | sublime.IGNORECASE
            start_pos = sels[0].end() if len(sels) > 0 else 0
            find_pos = self.view.find(pattern, start_pos, flags)

            if not find_pos and start_pos > 0:
            # Begin search again at the top of the buffer; wrap around
            # feature, i.e. do not stop the search at the buffer's end.
            find_pos = self.view.find(pattern, 0, flags)

            if not find_pos:
            sublime.status_message("'' not found".format(pattern))
            return

            sels.clear()
            sels.add(find_pos.begin())
            self.view.show_at_center(find_pos.begin())
            row, col = self.view.rowcol(find_pos.begin())
            self.view.run_command("goto_line", "line": row + 2)
            # Uncomment for: cursor to the end of the line.
            # self.view.run_command("move_to", "to": "eol")


            Add key bindings:



            // The pattern arg, i.e. "&todo", can be changed to anything you want
            // and other key bindings can also be added to use different patterns.
            "keys": ["???"], "command": "goto_pattern", "args": "pattern": "&todo"


            Add a Command Palette entry to Default.sublime-commands if you want:



            "caption": "GoToPattern: &todo", "command": "goto_pattern", "args": "pattern": "&todo",


            These links may be useful to you ST v. 2 API and ST v. 3 API.



            P.S. Did you know that Sublime Text has bookmarks? [Just in case you didn't.]






            share|improve this answer





























              1














              The best solution is it use a plugin to do that.



              The plugin below does what you require. It will find the next occurrence of pattern (i.e. the &todo marker) below the current cursor position, move the cursor to the line below it, and centre that position in the window. If the pattern is not found below the current cursor position it will search again from the top of the buffer providing a wrap around feature.



              Copy and paste the following Python code into a buffer and save it in your Sublime Text config User folder as GoToPattern.py.



              import sublime
              import sublime_plugin

              class GotoPatternCommand(sublime_plugin.TextCommand):

              def run(self, edit, pattern):

              sels = self.view.sel()
              # Optional flags; see API.
              flags = sublime.LITERAL | sublime.IGNORECASE
              start_pos = sels[0].end() if len(sels) > 0 else 0
              find_pos = self.view.find(pattern, start_pos, flags)

              if not find_pos and start_pos > 0:
              # Begin search again at the top of the buffer; wrap around
              # feature, i.e. do not stop the search at the buffer's end.
              find_pos = self.view.find(pattern, 0, flags)

              if not find_pos:
              sublime.status_message("'' not found".format(pattern))
              return

              sels.clear()
              sels.add(find_pos.begin())
              self.view.show_at_center(find_pos.begin())
              row, col = self.view.rowcol(find_pos.begin())
              self.view.run_command("goto_line", "line": row + 2)
              # Uncomment for: cursor to the end of the line.
              # self.view.run_command("move_to", "to": "eol")


              Add key bindings:



              // The pattern arg, i.e. "&todo", can be changed to anything you want
              // and other key bindings can also be added to use different patterns.
              "keys": ["???"], "command": "goto_pattern", "args": "pattern": "&todo"


              Add a Command Palette entry to Default.sublime-commands if you want:



              "caption": "GoToPattern: &todo", "command": "goto_pattern", "args": "pattern": "&todo",


              These links may be useful to you ST v. 2 API and ST v. 3 API.



              P.S. Did you know that Sublime Text has bookmarks? [Just in case you didn't.]






              share|improve this answer



























                1












                1








                1







                The best solution is it use a plugin to do that.



                The plugin below does what you require. It will find the next occurrence of pattern (i.e. the &todo marker) below the current cursor position, move the cursor to the line below it, and centre that position in the window. If the pattern is not found below the current cursor position it will search again from the top of the buffer providing a wrap around feature.



                Copy and paste the following Python code into a buffer and save it in your Sublime Text config User folder as GoToPattern.py.



                import sublime
                import sublime_plugin

                class GotoPatternCommand(sublime_plugin.TextCommand):

                def run(self, edit, pattern):

                sels = self.view.sel()
                # Optional flags; see API.
                flags = sublime.LITERAL | sublime.IGNORECASE
                start_pos = sels[0].end() if len(sels) > 0 else 0
                find_pos = self.view.find(pattern, start_pos, flags)

                if not find_pos and start_pos > 0:
                # Begin search again at the top of the buffer; wrap around
                # feature, i.e. do not stop the search at the buffer's end.
                find_pos = self.view.find(pattern, 0, flags)

                if not find_pos:
                sublime.status_message("'' not found".format(pattern))
                return

                sels.clear()
                sels.add(find_pos.begin())
                self.view.show_at_center(find_pos.begin())
                row, col = self.view.rowcol(find_pos.begin())
                self.view.run_command("goto_line", "line": row + 2)
                # Uncomment for: cursor to the end of the line.
                # self.view.run_command("move_to", "to": "eol")


                Add key bindings:



                // The pattern arg, i.e. "&todo", can be changed to anything you want
                // and other key bindings can also be added to use different patterns.
                "keys": ["???"], "command": "goto_pattern", "args": "pattern": "&todo"


                Add a Command Palette entry to Default.sublime-commands if you want:



                "caption": "GoToPattern: &todo", "command": "goto_pattern", "args": "pattern": "&todo",


                These links may be useful to you ST v. 2 API and ST v. 3 API.



                P.S. Did you know that Sublime Text has bookmarks? [Just in case you didn't.]






                share|improve this answer















                The best solution is it use a plugin to do that.



                The plugin below does what you require. It will find the next occurrence of pattern (i.e. the &todo marker) below the current cursor position, move the cursor to the line below it, and centre that position in the window. If the pattern is not found below the current cursor position it will search again from the top of the buffer providing a wrap around feature.



                Copy and paste the following Python code into a buffer and save it in your Sublime Text config User folder as GoToPattern.py.



                import sublime
                import sublime_plugin

                class GotoPatternCommand(sublime_plugin.TextCommand):

                def run(self, edit, pattern):

                sels = self.view.sel()
                # Optional flags; see API.
                flags = sublime.LITERAL | sublime.IGNORECASE
                start_pos = sels[0].end() if len(sels) > 0 else 0
                find_pos = self.view.find(pattern, start_pos, flags)

                if not find_pos and start_pos > 0:
                # Begin search again at the top of the buffer; wrap around
                # feature, i.e. do not stop the search at the buffer's end.
                find_pos = self.view.find(pattern, 0, flags)

                if not find_pos:
                sublime.status_message("'' not found".format(pattern))
                return

                sels.clear()
                sels.add(find_pos.begin())
                self.view.show_at_center(find_pos.begin())
                row, col = self.view.rowcol(find_pos.begin())
                self.view.run_command("goto_line", "line": row + 2)
                # Uncomment for: cursor to the end of the line.
                # self.view.run_command("move_to", "to": "eol")


                Add key bindings:



                // The pattern arg, i.e. "&todo", can be changed to anything you want
                // and other key bindings can also be added to use different patterns.
                "keys": ["???"], "command": "goto_pattern", "args": "pattern": "&todo"


                Add a Command Palette entry to Default.sublime-commands if you want:



                "caption": "GoToPattern: &todo", "command": "goto_pattern", "args": "pattern": "&todo",


                These links may be useful to you ST v. 2 API and ST v. 3 API.



                P.S. Did you know that Sublime Text has bookmarks? [Just in case you didn't.]







                share|improve this answer














                share|improve this answer



                share|improve this answer








                edited Apr 7 at 8:40

























                answered Mar 22 at 22:10









                mattstmattst

                5,52832130




                5,52832130























                    0














                    I found a solution: to do this, first create a gototodo.py file in "C:UsersUserAppDataRoamingSublime Text 2PackagesUser" containing:



                    import sublime, sublime_plugin

                    class GototodoCommand(sublime_plugin.TextCommand):
                    def run(self, edit):
                    contents = self.view.substr(sublime.Region(0, self.view.size())) # https://stackoverflow.com/questions/20182008/sublime-text-3-api-get-all-text-from-a-file
                    a = contents.find('&todo')
                    cursors = self.view.sel()
                    cursors.clear()
                    location = sublime.Region(a, a)
                    cursors.add(location)
                    self.view.show_at_center(location)

                    (row, col) = self.view.rowcol(self.view.sel()[0].begin()) # go to the next line
                    self.view.run_command("goto_line", "line": row+2)


                    Then add this in "C:UsersUserAppDataRoamingSublime Text 2PackagesUserDefault (Windows).sublime-keymap":



                     "keys": ["ctrl+t"], "command": "gototodo" 


                    Done!






                    share|improve this answer

























                    • No need for import subprocess. Your plugin will only ever move the cursor to the first occurrence of "&todo".

                      – mattst
                      Mar 27 at 17:07












                    • Sublime Text version 3 has been stable for 5+ years and is almost certainly a much better choice than the very old version 2 which was last updated in 2013. Version 3 has been out of beta for several years and it is the default download on SublimeText.com.

                      – mattst
                      Mar 27 at 17:09











                    • @mattst You're right about subprocess, I first included it because of something totally different (nearly another plugin), but you're right, it should be removed. I'll edit now.

                      – Basj
                      Mar 27 at 22:48











                    • @mattst About ST version: would this code here run perfectly on ST3 or would a few modifications be required here?

                      – Basj
                      Mar 27 at 22:49






                    • 1





                      No modifications needed, it works fine, I tested it to make sure. Note that ST2 and ST3 can both be installed on the same computer while you make the transition from version 2 to 3.

                      – mattst
                      Mar 28 at 12:28















                    0














                    I found a solution: to do this, first create a gototodo.py file in "C:UsersUserAppDataRoamingSublime Text 2PackagesUser" containing:



                    import sublime, sublime_plugin

                    class GototodoCommand(sublime_plugin.TextCommand):
                    def run(self, edit):
                    contents = self.view.substr(sublime.Region(0, self.view.size())) # https://stackoverflow.com/questions/20182008/sublime-text-3-api-get-all-text-from-a-file
                    a = contents.find('&todo')
                    cursors = self.view.sel()
                    cursors.clear()
                    location = sublime.Region(a, a)
                    cursors.add(location)
                    self.view.show_at_center(location)

                    (row, col) = self.view.rowcol(self.view.sel()[0].begin()) # go to the next line
                    self.view.run_command("goto_line", "line": row+2)


                    Then add this in "C:UsersUserAppDataRoamingSublime Text 2PackagesUserDefault (Windows).sublime-keymap":



                     "keys": ["ctrl+t"], "command": "gototodo" 


                    Done!






                    share|improve this answer

























                    • No need for import subprocess. Your plugin will only ever move the cursor to the first occurrence of "&todo".

                      – mattst
                      Mar 27 at 17:07












                    • Sublime Text version 3 has been stable for 5+ years and is almost certainly a much better choice than the very old version 2 which was last updated in 2013. Version 3 has been out of beta for several years and it is the default download on SublimeText.com.

                      – mattst
                      Mar 27 at 17:09











                    • @mattst You're right about subprocess, I first included it because of something totally different (nearly another plugin), but you're right, it should be removed. I'll edit now.

                      – Basj
                      Mar 27 at 22:48











                    • @mattst About ST version: would this code here run perfectly on ST3 or would a few modifications be required here?

                      – Basj
                      Mar 27 at 22:49






                    • 1





                      No modifications needed, it works fine, I tested it to make sure. Note that ST2 and ST3 can both be installed on the same computer while you make the transition from version 2 to 3.

                      – mattst
                      Mar 28 at 12:28













                    0












                    0








                    0







                    I found a solution: to do this, first create a gototodo.py file in "C:UsersUserAppDataRoamingSublime Text 2PackagesUser" containing:



                    import sublime, sublime_plugin

                    class GototodoCommand(sublime_plugin.TextCommand):
                    def run(self, edit):
                    contents = self.view.substr(sublime.Region(0, self.view.size())) # https://stackoverflow.com/questions/20182008/sublime-text-3-api-get-all-text-from-a-file
                    a = contents.find('&todo')
                    cursors = self.view.sel()
                    cursors.clear()
                    location = sublime.Region(a, a)
                    cursors.add(location)
                    self.view.show_at_center(location)

                    (row, col) = self.view.rowcol(self.view.sel()[0].begin()) # go to the next line
                    self.view.run_command("goto_line", "line": row+2)


                    Then add this in "C:UsersUserAppDataRoamingSublime Text 2PackagesUserDefault (Windows).sublime-keymap":



                     "keys": ["ctrl+t"], "command": "gototodo" 


                    Done!






                    share|improve this answer















                    I found a solution: to do this, first create a gototodo.py file in "C:UsersUserAppDataRoamingSublime Text 2PackagesUser" containing:



                    import sublime, sublime_plugin

                    class GototodoCommand(sublime_plugin.TextCommand):
                    def run(self, edit):
                    contents = self.view.substr(sublime.Region(0, self.view.size())) # https://stackoverflow.com/questions/20182008/sublime-text-3-api-get-all-text-from-a-file
                    a = contents.find('&todo')
                    cursors = self.view.sel()
                    cursors.clear()
                    location = sublime.Region(a, a)
                    cursors.add(location)
                    self.view.show_at_center(location)

                    (row, col) = self.view.rowcol(self.view.sel()[0].begin()) # go to the next line
                    self.view.run_command("goto_line", "line": row+2)


                    Then add this in "C:UsersUserAppDataRoamingSublime Text 2PackagesUserDefault (Windows).sublime-keymap":



                     "keys": ["ctrl+t"], "command": "gototodo" 


                    Done!







                    share|improve this answer














                    share|improve this answer



                    share|improve this answer








                    edited Mar 27 at 22:48

























                    answered Mar 22 at 13:19









                    BasjBasj

                    6,23334115248




                    6,23334115248












                    • No need for import subprocess. Your plugin will only ever move the cursor to the first occurrence of "&todo".

                      – mattst
                      Mar 27 at 17:07












                    • Sublime Text version 3 has been stable for 5+ years and is almost certainly a much better choice than the very old version 2 which was last updated in 2013. Version 3 has been out of beta for several years and it is the default download on SublimeText.com.

                      – mattst
                      Mar 27 at 17:09











                    • @mattst You're right about subprocess, I first included it because of something totally different (nearly another plugin), but you're right, it should be removed. I'll edit now.

                      – Basj
                      Mar 27 at 22:48











                    • @mattst About ST version: would this code here run perfectly on ST3 or would a few modifications be required here?

                      – Basj
                      Mar 27 at 22:49






                    • 1





                      No modifications needed, it works fine, I tested it to make sure. Note that ST2 and ST3 can both be installed on the same computer while you make the transition from version 2 to 3.

                      – mattst
                      Mar 28 at 12:28

















                    • No need for import subprocess. Your plugin will only ever move the cursor to the first occurrence of "&todo".

                      – mattst
                      Mar 27 at 17:07












                    • Sublime Text version 3 has been stable for 5+ years and is almost certainly a much better choice than the very old version 2 which was last updated in 2013. Version 3 has been out of beta for several years and it is the default download on SublimeText.com.

                      – mattst
                      Mar 27 at 17:09











                    • @mattst You're right about subprocess, I first included it because of something totally different (nearly another plugin), but you're right, it should be removed. I'll edit now.

                      – Basj
                      Mar 27 at 22:48











                    • @mattst About ST version: would this code here run perfectly on ST3 or would a few modifications be required here?

                      – Basj
                      Mar 27 at 22:49






                    • 1





                      No modifications needed, it works fine, I tested it to make sure. Note that ST2 and ST3 can both be installed on the same computer while you make the transition from version 2 to 3.

                      – mattst
                      Mar 28 at 12:28
















                    No need for import subprocess. Your plugin will only ever move the cursor to the first occurrence of "&todo".

                    – mattst
                    Mar 27 at 17:07






                    No need for import subprocess. Your plugin will only ever move the cursor to the first occurrence of "&todo".

                    – mattst
                    Mar 27 at 17:07














                    Sublime Text version 3 has been stable for 5+ years and is almost certainly a much better choice than the very old version 2 which was last updated in 2013. Version 3 has been out of beta for several years and it is the default download on SublimeText.com.

                    – mattst
                    Mar 27 at 17:09





                    Sublime Text version 3 has been stable for 5+ years and is almost certainly a much better choice than the very old version 2 which was last updated in 2013. Version 3 has been out of beta for several years and it is the default download on SublimeText.com.

                    – mattst
                    Mar 27 at 17:09













                    @mattst You're right about subprocess, I first included it because of something totally different (nearly another plugin), but you're right, it should be removed. I'll edit now.

                    – Basj
                    Mar 27 at 22:48





                    @mattst You're right about subprocess, I first included it because of something totally different (nearly another plugin), but you're right, it should be removed. I'll edit now.

                    – Basj
                    Mar 27 at 22:48













                    @mattst About ST version: would this code here run perfectly on ST3 or would a few modifications be required here?

                    – Basj
                    Mar 27 at 22:49





                    @mattst About ST version: would this code here run perfectly on ST3 or would a few modifications be required here?

                    – Basj
                    Mar 27 at 22:49




                    1




                    1





                    No modifications needed, it works fine, I tested it to make sure. Note that ST2 and ST3 can both be installed on the same computer while you make the transition from version 2 to 3.

                    – mattst
                    Mar 28 at 12:28





                    No modifications needed, it works fine, I tested it to make sure. Note that ST2 and ST3 can both be installed on the same computer while you make the transition from version 2 to 3.

                    – mattst
                    Mar 28 at 12:28

















                    draft saved

                    draft discarded
















































                    Thanks for contributing an answer to Stack Overflow!


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid


                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.

                    To learn more, see our tips on writing great answers.




                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function ()
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55262326%2fshortcut-to-move-to-a-specific-part-of-a-text-file%23new-answer', 'question_page');

                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown







                    Popular posts from this blog

                    Kamusi Yaliyomo Aina za kamusi | Muundo wa kamusi | Faida za kamusi | Dhima ya picha katika kamusi | Marejeo | Tazama pia | Viungo vya nje | UrambazajiKuhusu kamusiGo-SwahiliWiki-KamusiKamusi ya Kiswahili na Kiingerezakuihariri na kuongeza habari

                    SQL error code 1064 with creating Laravel foreign keysForeign key constraints: When to use ON UPDATE and ON DELETEDropping column with foreign key Laravel error: General error: 1025 Error on renameLaravel SQL Can't create tableLaravel Migration foreign key errorLaravel php artisan migrate:refresh giving a syntax errorSQLSTATE[42S01]: Base table or view already exists or Base table or view already exists: 1050 Tableerror in migrating laravel file to xampp serverSyntax error or access violation: 1064:syntax to use near 'unsigned not null, modelName varchar(191) not null, title varchar(191) not nLaravel cannot create new table field in mysqlLaravel 5.7:Last migration creates table but is not registered in the migration table

                    은진 송씨 목차 역사 본관 분파 인물 조선 왕실과의 인척 관계 집성촌 항렬자 인구 같이 보기 각주 둘러보기 메뉴은진 송씨세종실록 149권, 지리지 충청도 공주목 은진현