Download every approved Obsidian.md community Plugin and Theme

Overview

obsidian-repos-downloader

Contents

on-push-do-doco

What?

Clone every approved Obsidian.md community Plugin and Theme - to read and search the source code and learn from the community.

This is a Python3 script to download a local copy of all the published community Obsidian plugins and themes, to be used as a large body of example code.

It inspects these files, and then downloads (clones) all the repos listed in them:

Why?

I cannot put it better than the author of the similar project luckman212/obsidian-plugin-downloader:

As an absolute beginner to TypeScript, and a lover of Obsidian I often want to take a look at how someone has achieved a certain feature, called on an API, etc. A quick way to do that is by searching through the existing codebase of the ever growing library of plugins out there.

Setup

Requirements

  • Python 3.6 or above

Download

  1. Download the Latest Release.
    • Choose one of:
      • "Source code (zip)"
      • "Source code (tar.gz)"
    • If you can't see them, click to expand the "Assets"
  2. Expand the downloaded Source Code file
    • This will give you a folder name such as "obsidian-repos-downloader-0.1.0"

Run

Getting Started

The script to run is obsidian-repos-downloader.py

Depending on your platform, here are some example ways you might need to run it:

obsidian-repos-downloader.py
./obsidian-repos-downloader.py
python3 obsidian-repos-downloader.py

Usage - all the arguments

Running obsidian-repos-downloader.py --help gives this output:

usage: obsidian-repos-downloader.py [-h] [-o OUTPUT_DIRECTORY] [-l LIMIT] [-n]
                                    [-t [{plugins,themes,all}]]
                                    [--group-by-user] [--no-group-by-user]

Clone repos included in the obsidian-releases repo, to provide a body of
example plugins and CSS themes.

optional arguments:
  -h, --help            show this help message and exit
  -o OUTPUT_DIRECTORY, --output_directory OUTPUT_DIRECTORY
                        The directory where repos will be downloaded. Must
                        already exist. (default: . which means "current
                        working directory")
  -l LIMIT, --limit LIMIT
                        Limit the number of plugin and theme repos that will
                        be downloaded. This is useful when testing the script.
                        0 (zero) means "no limit". Note: the count currently
                        includes any repos already downloaded.(default: 0)
  -n, --dry-run         Print out the commands to be executed, but do no run
                        them. This is useful for testing. Note: it does not
                        print the directory-creation commands, just the git
                        ones
  -t [{plugins,themes,all}], --type [{plugins,themes,all}]
                        The type of repositories to download: plugins, themes
                        or both. (default: all)
  --group-by-user       Put each repository in a sub-folder named for the
                        GitHub user. For example, the plugin
                        "https://github.com/phibr0/obsidian-tabout" would be
                        placed in "plugins/phibr0/obsidian-tabout"
  --no-group-by-user    Put each repository in the same folder, prefixed by
                        the user name. This is the default behaviour. For
                        example, the plugin
                        "https://github.com/phibr0/obsidian-tabout" would be
                        placed in "plugins/phibr0-obsidian-tabout"

Output Directories

The script always creates a plugins/ and themes/ directories for its output.

There are the command-line arguments to determine the structure inside those directories.

Flatter Structure

By default, or when the argument --no-group-by-user is supplied, all the downloaded repos are placed side-by-side. They are prefixed with the username of the developer who wrote them.

For example, running this command (limiting the output to only 4 repositories, for brevity)....

obsidian-repos-downloader.py  --limit 4

... gives this directory structure:

plugins
├── agathauy-wikilinks-to-mdlinks-obsidian
├── aidenlx-alx-folder-note
├── aidenlx-better-fn
└── aidenlx-cm-chs-patch
themes
├── ArtexJay-Obsidian-CyberGlow
├── auroral-ui-aurora-obsidian-md
├── bcdavasconcelos-Obsidian-Ayu
└── bcdavasconcelos-Obsidian-Ayu_Mirage

8 directories

Grouped by User name

When the argument --group-by-user is supplied, all the downloaded repos are placed in sub-directories named with the username of the developer who wrote them.

For example, running this command (limiting the output to only 4 repositories, for brevity)....

obsidian-repos-downloader.py  --limit 4 --group-by-user

... gives this directory structure:

plugins
├── agathauy
│   └── wikilinks-to-mdlinks-obsidian
└── aidenlx
    ├── alx-folder-note
    ├── better-fn
    └── cm-chs-patch
themes
├── ArtexJay
│   └── Obsidian-CyberGlow
├── auroral-ui
│   └── aurora-obsidian-md
└── bcdavasconcelos
    ├── Obsidian-Ayu
    └── Obsidian-Ayu_Mirage

13 directories

Likely Questions

How do I update repos I have already downloaded?

In this early release, there is no mechanism to update any repos that have already been downloaded.

You can do this via git pull, although you would need to script the running of that in every plugin and theme directory.

Workaround: delete the existing downloads, and run the script again.

What order are plugins and themes downloaded in?

They are downloaded in case-insensitive alphabetical order of the repository's GitHub URL, so effectively in order of user name and then repo name.

Alternatives

There is a growing number of alternative mechanisms for downloading Obsidian repos:

You might also like...
Download history data from binance and save to dataframe or csv file

Binance history data downloader Download history data from binance and save to dataframe or csv file

A toolkit to automatically crawl the paper list and download paper pdfs of ACL Ahthology.

ACL-Anthology-Crawler A toolkit to automatically crawl the paper list and download paper pdfs of ACL Anthology

Download all your URI Online Judge source codes and upload to GitHub with simple steps.
Download all your URI Online Judge source codes and upload to GitHub with simple steps.

URI-Code-Downloader Download all your URI Online Judge source codes and upload to GitHub with simple steps. Prerequisites Python 3.x Installing Downlo

Download Apple Music Cover Artwork in the best Quality by providing an Apple Music Link. It downloads the jpg, png and webp version since they often differ from another.
Download Apple Music Cover Artwork in the best Quality by providing an Apple Music Link. It downloads the jpg, png and webp version since they often differ from another.

amogus.py - Version 0.0.5 amogus - Apple Music Hi-Res Artwork Fetcher this is my first real python tool so sorry if its bad amogus is a Python script

bing image downloader app used to download bulk images for a specific search term created using streamlit and bing_image_downloader python packages
bing image downloader app used to download bulk images for a specific search term created using streamlit and bing_image_downloader python packages

bing image downloader app bing image downloader app is used to download bulk images for a specific search term. bing image downloader app gets the sea

Download videos and audio with a graphical interface in python

Youtube-Downloader Download videos and audio with a graphical interface in python Windows To run windows using Command Prompt python main.py linux To

Download all posts and comments in a subreddit

subreddit downloader This subreddit downloader downloads all posts and comments in a subreddit For a tutorial to use this program please follow this m

Download all posts and comments in a subreddit

subreddit downloader This subreddit downloader downloads all posts and comments in a subreddit For a tutorial to use this program please follow this m

Fully automated download and parsing for Texas A&M University's Registrar's grade distribution PDFs for years 2014+.

Fully automated download and parsing for Texas A&M University's Registrar's grade distribution PDFs for years 2014+. Adds the parsing results to a mySQL database.

Comments
  • Trap any errors and continue, displaying them at the end

    Trap any errors and continue, displaying them at the end

    Even on a fast, seemingly stable internet connection, I get random errors when updating...

    It's annoying - it would be more convenient to continue past the errors, and print a summary at the end.

    Example output:

    updating Reocin/obsidian-markdown-formatting-assistant-plugin
    error: cannot pull with rebase: You have unstaged changes.
    error: please commit or stash them.
    Traceback (most recent call last):
      File "./obsidian-repos-downloader.py", line 174, in <module>
        download_repos()
      File "./obsidian-repos-downloader.py", line 170, in download_repos
        downloader.download()
      File "./obsidian-repos-downloader.py", line 100, in download
        self.process_released_plugins()
      File "./obsidian-repos-downloader.py", line 104, in process_released_plugins
        self.process_released_repos("plugins", PLUGINS_JSON_FILE)
      File "./obsidian-repos-downloader.py", line 117, in process_released_repos
        self.clone_repos(sorted_list)
      File "./obsidian-repos-downloader.py", line 123, in clone_repos
        self.clone_repo(plugin)
      File "./obsidian-repos-downloader.py", line 142, in clone_repo
        self.run_or_log(f"updating", command, repo)
      File "./obsidian-repos-downloader.py", line 149, in run_or_log
        subprocess.run(command, shell=True, check=True)
      File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/subprocess.py", line 487, in run
        output=stdout, stderr=stderr)
    subprocess.CalledProcessError: Command 'git pull --quiet' returned non-zero exit status 128.
    

    Ah - just read the error message, and it's not a network error!

    opened by claremacrae 2
  • FR: Use a shallow clone to save bandwidth/disk space

    FR: Use a shallow clone to save bandwidth/disk space

    Similar to #17, using a shallow clone would save a lot of bandwith, diskspace, and reduce download times, even without restricting the download to code only like suggested in #17.

    Essentially use git clone --depth 1 instead of git clone

    opened by chrisgrieser 0
  • FR: restrict to `.ts` / `.css` files

    FR: restrict to `.ts` / `.css` files

    I was pleased to see that this tool can also be used with themes!

    So, I noticed that the download takes quite a bit of time, especially since it downloads the full repos, which also include the high-res promo screenshots from the themes, or demo-videos from the docs from plugins.

    Since the purpose of this tool is primarily to inspect code and not screenshots, how about only downloading .ts and .css (or .scss)? this would immensely speed up the download, and also save bandwidth & file space.

    There could be an option to still download the full repos if so wished by the user

    opened by chrisgrieser 0
Releases(1.1.2)
  • 1.1.2(Dec 5, 2021)

    Improvements made:

    • Any errors cloning or updating repos are trapped, and reported, then re-reported on completion (#14)
    • Noted how to deal with such errors in the README, under "What if there is an error?"
    Source code(tar.gz)
    Source code(zip)
  • 1.1.1(Oct 20, 2021)

  • 1.1.0(Oct 19, 2021)

    Improvements made:

    • Add "-t" shortcut for "--type" argument (#6)
    • Add -n, --dry-run arg, for testing (#5)
    • Download repos in case-insensitive alphabetical order (#4)
    • Remove unnecessary snippet and anchor links from README.md
    Source code(tar.gz)
    Source code(zip)
  • 1.0.0(Oct 19, 2021)

    Python3 script to download every approved Obsidian.md community Plugin and Theme

    For details, see the README

    Changes:

    • Make git clone output less verbose
    • Much better documentation
    Source code(tar.gz)
    Source code(zip)
  • 0.0.1(Oct 19, 2021)

Owner
Clare Macrae
I'm an independent consultant who loves working with legacy and hard-to-test code. I specialise in helping teams get such code under test.
Clare Macrae
Animoo - Python scraper made with BeautifulSoup4 that scrapes images from /c/.

Animoo - Python scraper made with BeautifulSoup4 that scrapes images from /c/. Features Scrapes 10 pages Scrapes each thread Downloads all the images

aether 1 Dec 29, 2021
A simple Python program which uses youtube-dl for downloading YouTube videos as mp3 files.

yt-mp3 converter This is a simple Python program which uses youtube-dl for downloading YouTube videos as mp3 files. This program is for you if you are

nostalgicnerdpenguin 1 Oct 24, 2021
Download Thumbnail of YouTube Videos

Download Thumbnail of YouTube Videos in High Quality Variables: API_ID : Get From my.telegram.org API_HASH : Get from my.telegram.org BOT_TOKEN : Your

Arun 6 Jun 08, 2022
Download courses from khanacademy.org

khan-dl A python script to download courses from Khan Academy using youtube-dl and beautifulsoup4.

rand-net 806 Jan 03, 2023
Fetch papers and metadata.

Fetch PubMed Central for open-access papers as well as Sci-Hub

4 Oct 31, 2022
A lightweight, dependency-free Python library (and command-line utility) for downloading YouTube Videos.

A lightweight, dependency-free Python library (and command-line utility) for downloading YouTube Videos.

pytube 7.9k Jan 02, 2023
Simple tool downloads public PoC (refer from nomi-sec)

PoC Collection This is the little script to collect the proof-of-concept which is refered from nomi-sec. The repository now is only develop for linux-

2 Aug 17, 2022
Noto fonts go universal! Download Noto fonts combined to suit your region

noto-cjk Noto CJK fonts Noto Serif CJK update was released on 25 October 2021. We moved the release history and other notes into both Sans and Serif s

Google Fonts 2k Jan 02, 2023
Python module to donwload all Pixiv artworks of a user using it's user ID.

Python module to donwload all Pixiv artworks of a user using it's user ID. You need a PHPSESSID token to export NSFW.

Quatrecentquatre 1 Jan 27, 2022
Youtube Video Downloader Using Python Gui Appliction with progress Bar

Youtube-Video-Downloader Youtube Video Downloader Using Python Gui Appliction with progress Bar Module Used Pytube Tkinter Pil Urllib Bytes Io LICENSE

Community Programmer 6 Dec 19, 2022
Gogoanime-dl - Gogoanime downloader for downloading anime.

gogoanime-dl With this script, you can download episodes of your favorite anime from Gogoanime. The current site that's developed against is https://w

1 Jan 06, 2022
Python script to download (TCR) genes from IMGT/GENE-DB

IMGTgeneDL 0.1.0 Jamie Heather | CCR @ MGH | 2021 This script provides an alternative way to access TCR and IG genes stored in IMGT/GENE-DB. It's prim

Jamie Heather 1 Mar 30, 2022
This Program helps you download songs from the Spotify track's link you give in.

Spotify-Downloader-GUI This Program helps you download songs from the Spotify track's link you give in. It uses yt-dlp to download songs from Youtube.

Harish 12 Jun 14, 2022
A python program to download one or multiple videos from YouTube.

YouTube-Video-Downloader A python program to download one or multiple videos from YouTube. Quick Start guide First Clone The Project git clone https:/

Imira Randeniya 1 Sep 11, 2022
Download your bandcamp collection using this python script.

bandcamp-downloader Download your Bandcamp collection using this python script. It requires you to have a browser with a logged in session of bandcamp

72 Dec 20, 2022
Programmers-quest - Programmer's Quest! An open source MMO built on top of the Panda3D game engine and Astron server

Programmer's Quest! Programmer's Quest! The open source Python 3 2D MMORPG showc

Jordan Maxwell 5 Oct 07, 2022
🔥 A Bot To Telegram For Download High Qulity Videos & Songs From Youtube

🔥 A Bot To Telegram For Download High Qulity Videos & Songs From Youtube 🎗 Fast And Free Bot No Need To Pay ✅ By SL-Alpha-X-Team ⚡

Official Alpha-X-Team Account 7 Aug 31, 2022
Download YouTube videos/music and images in MP4, JPG with this tool.

ABOUT THE TOOL Download YouTube videos, music and images in MP4, JPG with this tool, with an easy to understand interface. This tool works with both,

TrollSkull 5 Jan 02, 2023
Get the latest updates around you as they happen

Adherent We all are different, experience various things happening around us but we stick together. We are all a part of a greater community. As human

Shreyas Daniel 1 Nov 10, 2022
A python script that discovers hidden YouTube API clients. Just a research project.

YouTube-Internal-Clients A script that discovers hidden internal clients of the YouTube (Innertube) API using bruteforce methods. The script tries cli

David 97 Jan 02, 2023