Gist
approvedby Jun Lin
Display the GitHub Gist.
Obsidian GitHub Gist Plugin
This is a plugin to render the GitHub Gist in Obsidian.
Example
The gist fenced code blocks will be rendered as a embed Gist view.
- With only the Gist ID:
```gist
30efbfd874fb1a16176d3f638a1e712a
```
- With the username and Gist ID:
```gist
linjunpop/30efbfd874fb1a16176d3f638a1e712a
```
- Specify to only show a single file in the Gist:
```gist
linjunpop/30efbfd874fb1a16176d3f638a1e712a#math.ex
30efbfd874fb1a16176d3f638a1e712a#concat.ex
```

Installation
Installing from the Obsidian App
Search "Gist" in Settings -> Community plugins, you can find and install this plugin.
You can check https://help.obsidian.md/Advanced+topics/Third-party+plugins#Discover+and+install+community+plugins for an official guide.
Manually installing the plugin
Find the latest release: https://github.com/linjunpop/obsidian-gist/releases, then copy over main.js, manifest.json, styles.css to your vault's .obsidian/plugins/obsidian-gist directory (ex. VaultFolder/.obsidian/plugins/obsidian-gist/).
Development
Develop the plugin locally
- Clone this repo to a local development folder. For convenience, you can place this folder in your
.obsidian/plugins/obsidian-gistfolder. - Install NodeJS, then run
npm iin the command line under your repo folder. - Run
npm run devto compile your plugin frommain.tstomain.js. - Make changes to
main.ts(or create new.tsfiles). Those changes should be automatically compiled intomain.js. - Reload Obsidian to load the new version of your plugin.
- Enable plugin in settings window.
Releasing new releases
- Update the
manifest.jsonwith a new version number, such as1.0.1, and the minimum Obsidian version required for your latest release. - Update the
versions.jsonfile with"new-plugin-version": "minimum-obsidian-version"so older versions of Obsidian can download an older version of your plugin that's compatible. - Create new GitHub release using your new version number as the "Tag version". Use the exact version number, don't include a prefix
v. - Upload the files
manifest.json,main.js,styles.cssas binary attachments. - Publish the release.
For plugin developers
Search results and similarity scores are powered by semantic analysis of your plugin's README. If your plugin isn't appearing for searches you'd expect, try updating your README to clearly describe your plugin's purpose, features, and use cases.