Skip to content

Support insertSnippet action #304

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

Merged
merged 18 commits into from
Jun 30, 2022
Merged

Support insertSnippet action #304

merged 18 commits into from
Jun 30, 2022

Conversation

pokey
Copy link
Member

@pokey pokey commented Oct 26, 2021

Adds support for the following type of command:

  • "snip funk"
  • "snip funk hello world"
  • "snip funk after air"

Still todo:

  • Final check on cpu usage when no custom snippets
  • wait for Improved update selections #306
  • fix "snip funk before this"
  • Test "snip if after air and bat"
  • Test "snip if after air and before bat"
  • Test "snip if after air and before bat and cap"
  • remove undo stop for delimiter insertion
  • fix that mark for "insert snippet after"
  • Fix bug with "snip funk before this" with multiple cursors in same statement (+test)
  • Fix bug with "pour this" with multiple cursors in same statement (+test)
  • test multiple placeholders of same variable for wrap, with it as wrap var
  • test multiple placeholders of same variable for wrap, with it not as wrap var
  • test multiple placeholders of same variable for insert, with it as substitution var
  • test multiple placeholders of same variable for insert, with it not as substitution var
  • Only show error messages in active window
  • Add docs

@pokey pokey marked this pull request as draft October 26, 2021 11:42
@pokey pokey changed the base branch from main to improved-update-selections November 3, 2021 21:12
Base automatically changed from improved-update-selections to main November 7, 2021 07:36
@pokey pokey force-pushed the insert-snippet branch 5 times, most recently from db951fb to 87fd2d9 Compare December 17, 2021 13:39
@pokey pokey force-pushed the insert-snippet branch 2 times, most recently from 37489d0 to dedd131 Compare January 5, 2022 18:51
@pokey pokey added this to the 0.26.0 milestone Jan 15, 2022
@pokey pokey assigned pokey and unassigned pokey Jan 18, 2022
@pokey pokey force-pushed the insert-snippet branch 2 times, most recently from 1e70456 to 974cd8a Compare January 27, 2022 14:27
Copy link
Member Author

@pokey pokey left a comment

Choose a reason for hiding this comment

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

Ok I believe I've addressed all comments! Here is a diff

@pokey pokey merged commit 2a68c81 into main Jun 30, 2022
@pokey pokey deleted the insert-snippet branch June 30, 2022 13:40
cursorless-bot pushed a commit that referenced this pull request Jun 30, 2022
* Support insertSnippet action

Handle action modifiers before positional modifiers

* Fixes from Andreas PR review session

* Tweaks from PR feedback

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Make halt overridable

* Clean up snippet error handling

* Throw error if multiple snippet definitions match a context

* Improve comment

* Update comment

* Cleanup

* More cleanup

* Add doc string

* Support cascading scope types for snippets

* Update doc string

* Removed duplicate test

* Restructure tests

* At link to issue

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
thetomcraig-aya pushed a commit to thetomcraig/cursorless that referenced this pull request Mar 27, 2024
* Support insertSnippet action

Handle action modifiers before positional modifiers

* Fixes from Andreas PR review session

* Tweaks from PR feedback

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Make halt overridable

* Clean up snippet error handling

* Throw error if multiple snippet definitions match a context

* Improve comment

* Update comment

* Cleanup

* More cleanup

* Add doc string

* Support cascading scope types for snippets

* Update doc string

* Removed duplicate test

* Restructure tests

* At link to issue

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
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.

3 participants