Skip to content

Commit 9c0ff07

Browse files
committed
Merged PR posit-dev/positron-python#217: Add initial placeholder for python snippets
Merge pull request #217 from posit-dev/feature/1437 Add initial placeholder for python snippets -------------------- Commit message for posit-dev/positron-python@a2971a6: Add initial placeholder for python snippets Establishes a mechanism to address #1437 Authored-by: Pete Farland <[email protected]> Signed-off-by: Pete Farland <[email protected]>
1 parent 1cf48c1 commit 9c0ff07

File tree

2 files changed

+18
-0
lines changed

2 files changed

+18
-0
lines changed

extensions/positron-python/package.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2059,6 +2059,12 @@
20592059
}
20602060
]
20612061
},
2062+
"snippets": [
2063+
{
2064+
"language": "python",
2065+
"path": "./snippets/python.code-snippets"
2066+
}
2067+
],
20622068
"submenus": [
20632069
{
20642070
"id": "python.run",
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
{
2+
"import <module>": {
3+
"prefix": "im",
4+
"body": "import ${1:module}$0",
5+
"description": "Import a package or module"
6+
},
7+
"from <module> import <names>": {
8+
"prefix": "from",
9+
"body": "from ${1:module} import ${2:names}$0",
10+
"description": "Import names from a package or module"
11+
}
12+
}

0 commit comments

Comments
 (0)