Skip to content

Commit 91cac73

Browse files
Update insertion delimiter for document scope (#2929)
Got tired of how often I need to say `"pour file slap"`. Also that the document should have a smaller insertion delimiter compared to a function is bit weird.
1 parent bfe4040 commit 91cac73

File tree

6 files changed

+10
-6
lines changed

6 files changed

+10
-6
lines changed

data/fixtures/recorded/positions/bringHarpToAfterFile.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ initialState:
2828
finalState:
2929
documentContents: |-
3030
hello world
31+
3132
hello
3233
selections:
3334
- anchor: {line: 0, character: 0}

data/fixtures/recorded/positions/bringWhaleToBeforeFile.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,8 @@ initialState:
2828
finalState:
2929
documentContents: |-
3030
world
31+
3132
hello world
3233
selections:
33-
- anchor: {line: 1, character: 0}
34-
active: {line: 1, character: 0}
34+
- anchor: {line: 2, character: 0}
35+
active: {line: 2, character: 0}

data/fixtures/recorded/selectionTypes/bringHarpToAfterFile.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ initialState:
2828
finalState:
2929
documentContents: |-
3030
hello world
31+
3132
hello
3233
selections:
3334
- anchor: {line: 0, character: 11}

data/fixtures/recorded/selectionTypes/bringWhaleToBeforeFile.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,8 @@ initialState:
2828
finalState:
2929
documentContents: |-
3030
world
31+
3132
hello world
3233
selections:
33-
- anchor: {line: 1, character: 11}
34-
active: {line: 1, character: 11}
34+
- anchor: {line: 2, character: 11}
35+
active: {line: 2, character: 11}

data/fixtures/scopes/textual/document.scope

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,4 @@ ccc
2929
5| ccc
3030
---<
3131

32-
[Insertion delimiter] = "\n"
32+
[Insertion delimiter] = "\n\n"

packages/cursorless-engine/src/processTargets/targets/DocumentTarget.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { PlainTarget } from "./PlainTarget";
77
export class DocumentTarget extends BaseTarget<CommonTargetParameters> {
88
type = "DocumentTarget";
99
textualType: TextualType = "line";
10-
insertionDelimiter = "\n";
10+
insertionDelimiter = "\n\n";
1111

1212
constructor(parameters: CommonTargetParameters) {
1313
super(parameters);

0 commit comments

Comments
 (0)