If you have code snippets you want to share with the community, then this is how: The following gif shows you how to download new snippets within the app. Otherwise, you can work entirely offline. Checking for updates is the only time that the app needs internet connectivity. New code snippets, once available, can be imported into XCSnippetsApp without re-installing the app. If you know about other helpful repostories, please let me know and I will also include their code snippets. Nearly 200 code snippets are available thanks to various open-source repositories which I listed in my app's README file. I created and open-sourced a macOS application, XCSnippetsApp, to address my needs. An application that allows me to explore code snippets from the Swift and iOS community, view and edit the snippets before adding them conveniently into Xcode. I wished there was a tool that could act as a staging area. Also, I did not want to download code snippets from each repository and import them into Xcode immediately. Hopefully, you’ll find this useful for your own workflows, and once again, my sincerest appreciation for Renfei for making this change to the app and further enabling it’s functionality and linkability.There are a couple of open-source repositories on GitHub sharing such code snippets, but I struggled to get an overview across all repositories. Summaryīeing able to bidirectionally link to a note in Obsidian to create documentation for my code snippets, and to other automations like Keyboard Maestro macros gives me a greater control over my documentation, and to an extent a sense of peace that things are neatly connected and as I progress, I won’t have to rely on in-file scans to determine if some code is used or not - something that can be particularly painful where the code snippet may have been indented. Once in place, this will allow you to quickly grab a deep link for any SnippetsLab snippet via Hookmark. `menu_click`, by Jacob Rus, September 2006 - Accepts a list of form: `) delay 0.2 - Build and return the Markdown link set strMarkdownLink to "(" & ( get the clipboard ) & ")" return strMarkdownLink The integration script is for the Get Address integration, and you can find out all about adding and using integration scripts on the Hookmark creating integration scripts page. If you want to help with the beta testing of the app, Renefei has a page all about it. The beta version the key menu item was added to is 3.3 build 3127, so the script below should work with that and any subsequent version of SnippetsLab. I do so appreciate developers who are willing to make these sorts of app tweaks to help their users. I decided to reach out to SnippetLab’s developer, Renfei Song, and we got into a discussion about my desire to use SnippetsLab with Hookmark.Īfter a bit of back and forth and me explaining the principles in a little detail, a new beta release of the app was forthcoming with a new menu item that I could then use to get the specific deep link I was looking for. Unfortunately, I couldn’t quite get one easy access to one thing. I looked at a few options with the SnippetsLab application, and I could get pretty far in getting it to work with Hookmark. More so, what I really wanted was to “hook” this into my existing automation documentation workflow utilising Hookmark and Obsidian. I wanted to find a way that enabled me to easily generate a way to track the relationship between a snippet and where it was used. The challenge then you end up with multiple locations where the code is used, and multiple places to maintain the code if there are any changes. In these cases, SnippetsLab is my go to utility.Īs far as possible, I like to use a cenralised library approach for my code, but as noted above, not all code snippets belong in a library. Code that isn’t practical to include in a single library. Sometimes I write (or find) code that I may want to use in several standalone places. SnippetsLab is a Mac code management utility that allows you to keep common snippets of code easily accessible. In this post I am going to explain a bit more about this. A small update to the user interface has enabled me to construct a basic integration with Hookmark (the app formerly known as Hook). My efforts to link together my documentation and automation took a little jump forward recently with a new beta of the code library utility called SnippetsLab. Automation Documentation: Hooking SnippetsLab
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |