Skip to content

Added yaml support #2071

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 7 commits into from
Nov 30, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
languageId: yaml
command:
version: 6
spokenForm: change every item
action:
name: clearAndSetSelection
target:
type: primitive
modifiers:
- type: everyScope
scopeType: {type: collectionItem}
usePrePhraseSnapshot: true
initialState:
documentContents: |-
foo: bar
baz: bongo
selections:
- anchor: {line: 0, character: 0}
active: {line: 0, character: 0}
marks: {}
finalState:
documentContents: |+

selections:
- anchor: {line: 0, character: 0}
active: {line: 0, character: 0}
- anchor: {line: 1, character: 0}
active: {line: 1, character: 0}
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
languageId: yaml
command:
version: 6
spokenForm: change every item
action:
name: clearAndSetSelection
target:
type: primitive
modifiers:
- type: everyScope
scopeType: {type: collectionItem}
usePrePhraseSnapshot: true
initialState:
documentContents: "foo: { bar: baz, bongo: 0}"
selections:
- anchor: {line: 0, character: 6}
active: {line: 0, character: 6}
marks: {}
finalState:
documentContents: "foo: { , }"
selections:
- anchor: {line: 0, character: 7}
active: {line: 0, character: 7}
- anchor: {line: 0, character: 9}
active: {line: 0, character: 9}
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
languageId: yaml
command:
version: 6
spokenForm: change every item
action:
name: clearAndSetSelection
target:
type: primitive
modifiers:
- type: everyScope
scopeType: {type: collectionItem}
usePrePhraseSnapshot: true
initialState:
documentContents: |-
foo:
- 0
- 1
selections:
- anchor: {line: 1, character: 2}
active: {line: 1, character: 2}
marks: {}
finalState:
documentContents: |-
foo:


selections:
- anchor: {line: 1, character: 2}
active: {line: 1, character: 2}
- anchor: {line: 2, character: 2}
active: {line: 2, character: 2}
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
languageId: yaml
command:
version: 6
spokenForm: change every item
action:
name: clearAndSetSelection
target:
type: primitive
modifiers:
- type: everyScope
scopeType: {type: collectionItem}
usePrePhraseSnapshot: true
initialState:
documentContents: "bar: [0, 1]"
selections:
- anchor: {line: 0, character: 6}
active: {line: 0, character: 6}
marks: {}
finalState:
documentContents: "bar: [, ]"
selections:
- anchor: {line: 0, character: 6}
active: {line: 0, character: 6}
- anchor: {line: 0, character: 8}
active: {line: 0, character: 8}
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
languageId: yaml
command:
version: 6
spokenForm: change every key
action:
name: clearAndSetSelection
target:
type: primitive
modifiers:
- type: everyScope
scopeType: {type: collectionKey}
usePrePhraseSnapshot: true
initialState:
documentContents: |-
foo: bar
baz: bongo
selections:
- anchor: {line: 0, character: 0}
active: {line: 0, character: 0}
marks: {}
finalState:
documentContents: |-
: bar
: bongo
selections:
- anchor: {line: 0, character: 0}
active: {line: 0, character: 0}
- anchor: {line: 1, character: 0}
active: {line: 1, character: 0}
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
languageId: yaml
command:
version: 6
spokenForm: change every key
action:
name: clearAndSetSelection
target:
type: primitive
modifiers:
- type: everyScope
scopeType: {type: collectionKey}
usePrePhraseSnapshot: true
initialState:
documentContents: "foo: { bar: baz, bongo: 0}"
selections:
- anchor: {line: 0, character: 6}
active: {line: 0, character: 6}
marks: {}
finalState:
documentContents: "foo: { : baz, : 0}"
selections:
- anchor: {line: 0, character: 7}
active: {line: 0, character: 7}
- anchor: {line: 0, character: 14}
active: {line: 0, character: 14}
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
languageId: yaml
command:
version: 6
spokenForm: change every value
action:
name: clearAndSetSelection
target:
type: primitive
modifiers:
- type: everyScope
scopeType: {type: value}
usePrePhraseSnapshot: true
initialState:
documentContents: |-
foo: bar
baz: bongo
selections:
- anchor: {line: 0, character: 0}
active: {line: 0, character: 0}
marks: {}
finalState:
documentContents: |-
foo:
baz:
selections:
- anchor: {line: 0, character: 5}
active: {line: 0, character: 5}
- anchor: {line: 1, character: 5}
active: {line: 1, character: 5}
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
languageId: yaml
command:
version: 6
spokenForm: change every value
action:
name: clearAndSetSelection
target:
type: primitive
modifiers:
- type: everyScope
scopeType: {type: value}
usePrePhraseSnapshot: true
initialState:
documentContents: "foo: { bar: baz, bongo: 0}"
selections:
- anchor: {line: 0, character: 6}
active: {line: 0, character: 6}
marks: {}
finalState:
documentContents: "foo: { bar: , bongo: }"
selections:
- anchor: {line: 0, character: 12}
active: {line: 0, character: 12}
- anchor: {line: 0, character: 21}
active: {line: 0, character: 21}
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
languageId: yaml
command:
version: 6
spokenForm: change item
action:
name: clearAndSetSelection
target:
type: primitive
modifiers:
- type: containingScope
scopeType: {type: collectionItem}
usePrePhraseSnapshot: true
initialState:
documentContents: "foo: bar"
selections:
- anchor: {line: 0, character: 0}
active: {line: 0, character: 0}
marks: {}
finalState:
documentContents: ""
selections:
- anchor: {line: 0, character: 0}
active: {line: 0, character: 0}
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
languageId: yaml
command:
version: 6
spokenForm: change item
action:
name: clearAndSetSelection
target:
type: primitive
modifiers:
- type: containingScope
scopeType: {type: collectionItem}
usePrePhraseSnapshot: true
initialState:
documentContents: |-
foo:
- 0
- 1
selections:
- anchor: {line: 1, character: 2}
active: {line: 1, character: 2}
marks: {}
finalState:
documentContents: |-
foo:

- 1
selections:
- anchor: {line: 1, character: 2}
active: {line: 1, character: 2}
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
languageId: yaml
command:
version: 6
spokenForm: change item
action:
name: clearAndSetSelection
target:
type: primitive
modifiers:
- type: containingScope
scopeType: {type: collectionItem}
usePrePhraseSnapshot: true
initialState:
documentContents: "bar: [0, 1]"
selections:
- anchor: {line: 0, character: 6}
active: {line: 0, character: 6}
marks: {}
finalState:
documentContents: "bar: [, 1]"
selections:
- anchor: {line: 0, character: 6}
active: {line: 0, character: 6}
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
languageId: yaml
command:
version: 6
spokenForm: change item
action:
name: clearAndSetSelection
target:
type: primitive
modifiers:
- type: containingScope
scopeType: {type: collectionItem}
usePrePhraseSnapshot: true
initialState:
documentContents: |
- aaa: bbb
selections:
- anchor: {line: 0, character: 0}
active: {line: 0, character: 0}
marks: {}
finalState:
documentContents: |+

selections:
- anchor: {line: 0, character: 0}
active: {line: 0, character: 0}
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
languageId: yaml
command:
version: 6
spokenForm: change key
action:
name: clearAndSetSelection
target:
type: primitive
modifiers:
- type: containingScope
scopeType: {type: collectionKey}
usePrePhraseSnapshot: true
initialState:
documentContents: "foo: bar"
selections:
- anchor: {line: 0, character: 0}
active: {line: 0, character: 0}
marks: {}
finalState:
documentContents: ": bar"
selections:
- anchor: {line: 0, character: 0}
active: {line: 0, character: 0}
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
languageId: yaml
command:
version: 6
spokenForm: change leading value
action:
name: clearAndSetSelection
target:
type: primitive
modifiers:
- {type: leading}
- type: containingScope
scopeType: {type: value}
usePrePhraseSnapshot: true
initialState:
documentContents: "foo: bar"
selections:
- anchor: {line: 0, character: 0}
active: {line: 0, character: 0}
marks: {}
finalState:
documentContents: foobar
selections:
- anchor: {line: 0, character: 3}
active: {line: 0, character: 3}
Loading