|
10 | 10 | <h4 align="center">View and edit all your snippets in one purty place. Yee-haw!</h4>
|
11 | 11 |
|
12 | 12 | <p align="center">
|
13 |
| -<img src="https://img.shields.io/static/v1?logo=visual-studio-code&label=made%20for&message=VS%20Code&color=0000ff" alt="Made for VSCode"> |
14 |
| -<img src="https://img.shields.io/visual-studio-marketplace/v/robole.snippets-ranger?logo=visual-studio-code&color=0000ff" alt="Visual Studio Marketplace Version"> |
15 |
| -<img src="https://img.shields.io/static/v1?logo=visual-studio-code&label=size&message=65KB&color=0000ff" |
| 13 | +<img src="https://img.shields.io/static/v1?logo=visual-studio-code&label=made%20for&message=VS%20Code&color=blue" alt="Made for VSCode"> |
| 14 | +<img src="https://img.shields.io/visual-studio-marketplace/v/robole.snippets-ranger?logo=visual-studio-code&color=blue" alt="Visual Studio Marketplace Version"> |
| 15 | +<img src="https://img.shields.io/static/v1?logo=visual-studio-code&label=size&message=67KB&color=blue" |
16 | 16 | alt="Extension file size in bytes">
|
17 |
| -<img src="https://img.shields.io/visual-studio-marketplace/r/robole.snippets-ranger?logo=visual-studio-code&color=0000ff" alt="Visual Studio Marketplace Rating"> |
18 |
| -<img src="https://img.shields.io/visual-studio-marketplace/d/robole.snippets-ranger?logo=visual-studio-code&color=0000ff" alt="downloads"/> |
19 |
| -<img src="https://img.shields.io/visual-studio-marketplace/i/robole.snippets-ranger?logo=visual-studio-code&color=0000ff" alt="installs"/> |
20 |
| -<img src="https://img.shields.io/static/v1?label=built%20with&message=sarsaparilla%20%26%20javascript&color=0000ff" alt="Built with sarsaparilla and javascript"/> |
21 |
| -<a href="https://ko-fi.com/roboleary"><img src="https://img.shields.io/badge/Buy%20me%20a%20coffee-$4-orange?logo=buy-me-a-coffee" alt="Buy me a coffee"></a> |
| 17 | +<img src="https://img.shields.io/visual-studio-marketplace/r/robole.snippets-ranger?logo=visual-studio-code&color=blue" alt="Visual Studio Marketplace Rating"> |
| 18 | +<img src="https://img.shields.io/visual-studio-marketplace/d/robole.snippets-ranger?logo=visual-studio-code&color=blue" alt="downloads"/> |
| 19 | +<img src="https://img.shields.io/visual-studio-marketplace/i/robole.snippets-ranger?logo=visual-studio-code&color=blue" alt="installs"/> |
| 20 | +<img src="https://img.shields.io/static/v1?label=built%20with&message=sarsaparilla%20%26%20javascript&color=blue" alt="Built with sarsaparilla and javascript"/> |
| 21 | +<a href="https://ko-fi.com/roboleary"><img src="https://img.shields.io/badge/Buy%20me%20a%20coffee-$4-gold?logo=buy-me-a-coffee" alt="Buy me a coffee"></a> |
22 | 22 | </p>
|
23 | 23 |
|
24 |
| -<p align="center"> |
25 |
| -<img src="img/screenshots/demo.webp" width="556" height="482" alt="recording of exploring view opened from the command 'Snippets Ranger: Show me that dur Range, Partner'. An entry of 'Markdown snippets' from the table of contents is selected and clicked, it takes the user down to the table with the snippets displayed for that extension."/> |
26 |
| -</p> |
| 24 | + |
27 | 25 |
|
28 |
| -**Snippets are grouped as: *Project*, *User*, *Extension*, and *VS Code*.** |
| 26 | +Snippets are shown in an **easy to read [webview](https://code.visualstudio.com/api/extension-guides/webview)**. |
29 | 27 |
|
30 |
| -The table of contents facilitates quick navigation to a snippets set. Pressing the <kbd>Home</kbd> key will return you to the table of contents. |
| 28 | +Snippets are formed into posses: |
| 29 | +- ***Project***: These are the snippets contained in the `.vscode` folder of the current workspace, |
| 30 | +- ***User***: These are the global snippet files (`.code-snippets` files) and language snippet files (`.json` files) that you created as an user on your system, |
| 31 | +- ***Extension***: These are the snippets files that are included in extensions you have installed, |
| 32 | +- ***App***: These are the snippets files that are packaged with VS Code. |
31 | 33 |
|
32 |
| -There are sticky headings to ensure you can browse through long snippet lists without losing context. 🦎🔝 |
| 34 | +The extension uses the exact same source files as VS Code does. No double-crossing rattlesnakes! 🐍 |
33 | 35 |
|
34 |
| -You can go to the source snippet file directly with the *View Source File* button. The extension uses **the exact same source files as VS Code does**. |
| 36 | +## Easy navigation |
35 | 37 |
|
36 |
| - |
| 38 | +There are **sticky headings** to ensure you can browse through long snippet lists without losing context. 🦎🔝 |
37 | 39 |
|
38 |
| -**Editing is a piece of cake**.🍰 |
| 40 | + |
39 | 41 |
|
40 |
| - |
| 42 | +The **table of contents** facilitates quick navigation to a snippets set. |
41 | 43 |
|
42 |
| -The *Edit* action button will take you to the specific snippet in the source file to perform an edit. The *Delete* action button will delete the snippet straight away. |
| 44 | + |
43 | 45 |
|
44 |
| -## Activation |
| 46 | +Pressing the <kbd>Home</kbd> key will return you to the table of contents. |
45 | 47 |
|
46 |
| -The extension is only loaded when one of the commands are executed. |
| 48 | +## Easy editing |
| 49 | + |
| 50 | +You can **open the snippets file with the *View Source File* button** contained in the sticky header for each snippets file listed in the view. |
| 51 | + |
| 52 | +In the table, you can **edit individual snippet with the buttons in each row**: |
| 53 | +- The *Edit* action button (identified by the pen icon) will take you to the specific snippet in the source file to perform an edit. |
| 54 | +- The *Delete* action button (identified by the trash icon) will delete the snippet straight away without opening the file. |
| 55 | + |
| 56 | + |
| 57 | + |
| 58 | +If you are working in code and would like to **quickly add a snippet to a snippets file, you can use the `Snippets Ranger: Add new snippet to snippets file...` command**. It has 3 easy steps: |
| 59 | +1. Select some code (no selection is fine too) and run the command, |
| 60 | +1. Choose an existing snippets file or create a new file from the menu, |
| 61 | +1. The file will be opened with a new snippet. Your selection will be in the `body` field as an array of values. You can tab through the properties to fill each one out. |
| 62 | + |
| 63 | + |
47 | 64 |
|
48 | 65 | ## Commands
|
49 | 66 |
|
50 |
| -The following commands can be run from the Command Palette (`Ctrl+Shift+P`): |
| 67 | +The following commands are available: |
51 | 68 |
|
52 |
| -1. **`Snippets Ranger: Show me that dur Range, Partner`**: Opens the view that lists all snippets. |
53 |
| -1. **`Snippets Ranger: Add New Snippet`**: Quickly add a new snippet to a snippet file of your choosing. |
| 69 | +1. **`Snippets Ranger: Show me that dur Range, Partner`**: Opens the view that lists all your snippets. |
| 70 | +1. **`Snippets Ranger: Add new snippet to snippets file...`**: Quickly add a new snippet to a snippet file of your choosing. If you have code selected, this selection will be added to the `body` of the snippet. Any dollar signs in the selection will be escaped (preceded by 2 backslashes) to prevent them being interpeted as tab stops. |
54 | 71 |
|
55 |
| - |
| 72 | +## Activation |
| 73 | + |
| 74 | +The extension is only loaded when one of the commands are executed. |
56 | 75 |
|
57 | 76 | ## Performance
|
58 | 77 |
|
59 |
| -To gather and render approx 6000 snippets sourced from 18 different files, it takes 4.5 seconds on a modestly-specced 4-year old laptop running Ubuntu 18. 🚀 |
| 78 | +To gather and render approx 6000 snippets sourced from 18 different files, it takes 4.5 seconds on a modestly-specced laptop running Ubuntu 18. 🚀 |
60 | 79 |
|
61 | 80 | ## Contribute
|
62 | 81 |
|
63 |
| -Contributions are welcome. If you have a suggestion or find a bug, please file an issue. |
64 |
| - |
65 |
| -Please do not offer a PR without raising an issue first, my time for reviews are limited. You can [support me](https://ko-fi.com/roboleary) to increase my time available. |
66 |
| - |
67 |
| -## Appreciate |
| 82 | +Contributions are welcome. If you have a suggestion or find a bug, please file an issue. Please do not offer a PR without raising an issue first, my time for reviews are limited. |
68 | 83 |
|
69 |
| -You can show your appreciation by: |
70 |
| -1. [Buying me a coffee or sponsoring me](https://ko-fi.com/roboleary) |
71 |
| -1. Leaving a positive review in the [visual studio marketplace](https://marketplace.visualstudio.com/items?itemName=robole.snippets-ranger&ssr=false#review-details). |
72 |
| -1. Starring the repo 🌟. |
| 84 | +To help other people find the extension, you can [star the repo 🌟](https://github.com/robole/vscode-snippets-ranger), and leave a positive review in the [Visual Studio Marketplace](https://marketplace.visualstudio.com/items?itemName=robole.snippets-ranger&ssr=false#review-details) or [Open VSX Registry](https://open-vsx.org/extension/robole/snippets-ranger/reviews). |
73 | 85 |
|
74 |
| -This will **help other people find the extension**. It will **encourage me to continue maintenance**, and may provide **a path to dedicating more time to open-source** in the future. |
| 86 | +You can [support me](https://ko-fi.com/roboleary) to make issues in this project a higher priority and allow me to dedicate more time I can dedicate to open-source projects. |
75 | 87 |
|
76 | 88 | ## Learn more about snippets
|
77 | 89 |
|
|
0 commit comments