Skip to content

Commit 7cc2ed4

Browse files
Merge pull request #8 from mariobuikhuizen/fix_rename
fix: remove all references to 'code'
2 parents 7415f8f + 0d109d8 commit 7cc2ed4

File tree

4 files changed

+9
-9
lines changed

4 files changed

+9
-9
lines changed

README.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
![Github Actions Status](https://github.com/QuantStack/jupyterlab-snippets/workflows/Build/badge.svg)
44

5-
Code Snippets Extension for JupyterLab.
5+
Snippets Extension for JupyterLab.
66

77
This extension is composed of a Python package named `jupyterlab-snippets`
88
for the server extension and a NPM package named `jupyterlab-snippets`
@@ -22,11 +22,11 @@ jupyter lab build
2222

2323
## Usage
2424

25-
Add snippets in `[jupyter_data_dir]/code_snippets` (see: https://jupyter.readthedocs.io/en/latest/projects/jupyter-directories.html#id2)
25+
Add snippets in `[jupyter_data_dir]/snippets` (see: https://jupyter.readthedocs.io/en/latest/projects/jupyter-directories.html#id2)
2626

27-
In JupyterLab, use the "Code Snippets" menu to select the snippet:
27+
In JupyterLab, use the "Snippets" menu to select the snippet:
2828

29-
<img width="398" alt="Schermafbeelding 2020-03-26 om 13 16 34" src="https://user-images.githubusercontent.com/46192475/77646139-40a21c00-6f64-11ea-9073-fe2d1052928f.png">
29+
<img width="570" alt="Schermafbeelding 2020-03-30 om 17 25 31" src="https://user-images.githubusercontent.com/46192475/77930697-8257fd00-72ab-11ea-8a77-36f45d6442d9.png">
3030

3131

3232
## Troubleshoot

jupyterlab-snippets/loader.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
class SnippetsLoader:
1111
def __init__(self):
12-
self.snippet_paths = jupyter_path("code_snippets")
12+
self.snippet_paths = jupyter_path("snippets")
1313

1414
def collect_snippets(self):
1515
snippets = []

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "jupyterlab-snippets",
33
"version": "0.1.0",
4-
"description": "Code Snippets Extension for JupyterLab",
4+
"description": "Snippets Extension for JupyterLab",
55
"keywords": [
66
"jupyter",
77
"jupyterlab",

src/index.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@ import {
2222
import { listSnippets, Snippet, fetchSnippet } from "./snippets";
2323

2424
/**
25-
* The command IDs used by the code snippets plugin.
25+
* The command IDs used by the snippets plugin.
2626
*/
2727
namespace CommandIDs {
28-
export const open = "code-snippets:open";
28+
export const open = "snippets:open";
2929
}
3030

3131
/**
@@ -130,7 +130,7 @@ const extension: JupyterFrontEndPlugin<void> = {
130130
if (menu) {
131131
const list = await listSnippets();
132132
const snippetsMenu = createMenu(commands, toTree(list));
133-
snippetsMenu.title.label = 'Code Snippets';
133+
snippetsMenu.title.label = 'Snippets';
134134
menu.addMenu(snippetsMenu);
135135
}
136136
}

0 commit comments

Comments
 (0)