I will list all shortcuts here in future if I add more ideas. Saves people jumping back and forth to get them all.
(Feel free to add any ideas or snippet code to the thread. But leave this post to me)
Snippet Library
`Version 1.0.0`
Snippet Library Listing.zip (24.5 KB)
1, Shortcuts creation and Insert from list of text files.
These two Shortcuts are used in conjunction to create a snippets of text.
- Snippet - Save Text
This allows you to select some text and save it to a folder.
The folder path is /snippets. where the txt file will be saved into and is inside the Shortcuts folder in iCloud Drive.
/iCloud Drive/Shortcuts/snippets/
If the snippets folder does not exist it will be created. It shouldn't overwrite an existing one
- Snippet - Insert Text
This will look in the Snippets folder and list the files alphabetically by file name.
You choose you snippet and it will be inserted.Original Shortcuts
These two are for text inserts type snippets.
You can change the folder paths to where ever you want instead of the one I set.
Snippet Library*
Version 1.1.0
SNIPPETS.shortcut.zip (13.0 KB)
The List will now look in the /snippets folder the same as version 1.
But now also looks in a Shortcuts folder in the Shortcuts App. and combines them as a single list.
You can run either one of the simple text inserts from the /snippets folder or a more complex shortcut where the input if any will be s passed on to the Shortcut.
You do not need to do anything special in the Shortcuts that are run this way.
Apart from if you want them to output by checking the output check box as normal.
This method of Organising Shortcuts can also lend its self to limit the number of Shortcuts you see in the Service menu and also ( @ktewes ) if you have more than one Library pointing at Different Shortcuts/snippets. Then you can get an approximation odf separation.
v1.10 Library Listing show the text file insert snippets as well as Actual Shortcuts to run.
ShortcutsExtras
Shortcut Snippets.zip (68.6 KB)
-
_Snippet Hype Video Tag.shortcut
Inserts a HTML Video Tag block -
_Snippet Hype Image Tag.shortcut
Inserts a HTML Image Tag -
_Snippet JS for loop.shortcut
Inserts a JS for loop block -
_Snippet Hype Head.shortcut
Inserts a HypeJS for HypeDocumentLoad() -
_Snippet Console.log Prompt.shortcut
prompts to insert a console.log() input text with or without quotes -
_Snippet Style Block.shortcut
Inserts a css style block
Snippet - Save Text.shortcut.zip (12.2 KB)
- Snippet - Save Text
This allows you to select some text and save it to a folder.
The folder path is /snippets. where the txt file will be saved into and is inside the Shortcuts folder in iCloud Drive.
Tips
- Keyboard Shortcuts.
You can add a shortcut key to a Shortcut in theShortcuts.app
For example. as well as having my Insert head js code in the Snippet Library as a text insert.
I also have it as a stand alone Shortcut action not linked to the Snippet Library
In the same settings area for setting up show in Service menu, there is a Run with keyboard shortcut field.
I can use CTRL + OPT +⌘ + H
which will insert the head code directly without me using any menus.
Tip Pros :Very quick to insert text/code
Tip Cons: Clutters the service menu because the keyboard shortcut must exist on a menu item.
So use sparingly for most common inserts and use the Libray for the rest.