Skip to main content

Obsidian Snippet Manager is a python script that git pull and move CSS file in your .obsidian/snippet folder.

The goal is to provide a practical way to get semi-auto-update from CSS snippet hosted on GitHub, in waiting of an eventual BRAT update that support that.

Get started

Requirements

  1. Git
  2. Python
  3. pip install Obsidian-Snippet-Manager --upgrade

GUI

You can use the application with an interface, using (in terminal): snipetter.

Information about executable release:

  • It will don't install the CLI command, so you won't have the Obsidian-Shell auto-update.
  • The executable don't use the same environment file as the package : You need to configure two times if you use the two (CLI + executable released)
  • Delete the release delete the environment file. Beware when you update your executable.

You can select the files you want to update or clone. Also, you can only use some specific file from update, instead of entire folder. You can exclude them from futur update using the exclude button.


CLI

Environment

The plugin needs :

  • The absolute path of your vault, as : G:\Drive\Vault
  • A folder that contains all the snippet you want to get the update. This folder can be everywhere on your computer (yes, it can be in .obsidian too.). It will contain all folder of the snippet hosted on GitHub you want to use.
    In case of the folder doesn't exist, the script will create it!

How to use

  1. Adding a new repo : obsnipe clone repository_url
    Additionally, you can exclude a folder from update with adding the --exclude command : obsnipe clone [repository_url] --excluded
    This command work also for file : obsnipe clone [repository_url] --excluded file.css. This file will be added to exclude.yml.
  2. Updating everything : obsnipe
  3. Updating only a repository : obsnipe update folder_name The folder name is the folder that you wish to update the snippet!
    Also, you can update only a specific file with obsnipe update [foldername] --only [filename]

The script will :

  • Git pull
  • Git move every .css (unless the excluded) file in your .obsidian/snippet folder.

Other function

  • obsnipe list : List all GitHub Repository you download.
  • obsnipe exclude [folder_name] : Exclude a folder or a css snippet from update. You can exclude multiple value using : obsnipe exclude [folder1] [filename2]
    Using -add [filename][folder] will add these file in exclude.yml

Note : You can exclude a folder from auto-update using the exclude.yml file, placed in your Snippet Manager folder. You need to add the folder name as a yaml list :

- foldername1
- foldername2

Example

Using Obsidian Snippets Collection

  1. Configuration :
    • Vault is in : G:/Drive/vault
    • My Obsidian Manager Folder is in : D:/Documents/Github/Snippets Manager
  2. obsnipe clone https://github.com/Mara-Li/Obsidian-Snippet-collection
  3. Activate the snippets 🎉

To update this specific snippet : obsnipe update Obsidian-Snippet-collection

In obsidian

You can create a command in Obsidian using Obsidian Shell.

Bonus, you can update your snippet every time obsidian start, like BRAT!

⚠️ WARNING : Every edit on a snippet downloaded by this way will break the script. Please, DON'T EDIT these file, and use another snippet. (Or, use a fork and commit before.)

Credit

Metadata

Release files for Obsidian-Snippet-Manager 2.3.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for Obsidian-Snippet-Manager 2.3.0
File Size Uploaded Provenance Actions
Obsidian_Snippet_Manager-2.3.0.tar.gz 1.3 MB Without provenance Details for Obsidian_Snippet_Manager-2.3.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for Obsidian-Snippet-Manager 2.3.0
File Interpreter ABI Platform Actions
Obsidian_Snippet_Manager-2.3.0-py3-none-any.whl Python 3 none any Details for Obsidian_Snippet_Manager-2.3.0-py3-none-any.whl

Total release size: 1.3 MB

Release files / Obsidian_Snippet_Manager-2.3.0.tar.gz

Download URL Obsidian_Snippet_Manager-2.3.0.tar.gz
Size 1.3 MB
Tags Source
SHA-256 checksum
How to use checksums
b41bb4cb99ddcd77a750d7a0c90fab401321d629784c55cebb9d94d2e6d8eb81
BLAKE2b-256 checksum
How to use checksums
fae36968b1d1bfddda8675fba4c673a5fc4e44e9fd07067cb8e66cbc4e20ceb6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.10.0 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.10.2

Release files / Obsidian_Snippet_Manager-2.3.0-py3-none-any.whl

Download URL Obsidian_Snippet_Manager-2.3.0-py3-none-any.whl
Size 29.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
c3a6f19a688392189280cdaa9d4309dc5033132e7a3ca9fd68ebc8bc0b0f8c0f
BLAKE2b-256 checksum
How to use checksums
b5499455d663fd187c5e2e91b31caea51a685ad745d14a8dabb94f045a84e1fc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.10.0 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.10.2

Security for Obsidian-Snippet-Manager 2.3.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page