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
A small distributed download manager to help bypass device-specific bandwidth limitations.

Distributed Download Manager A small distributed download manager to help bypass device-specific bandwidth limitations. Architecture The download mana

Anand Balaji 3 Sep 23, 2022
nextdl - download videos from youtube.com or other video platforms

nextdl - download videos from youtube.com or other video platforms

3 Feb 02, 2022
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

Guneet 6 Dec 16, 2022
Download your Spotify playlists and songs along with album art and metadata

spotDL Download your Spotify playlists and songs along with album art and metadata The fastest, easiest, and most accurate command-line music download

10.6k Jan 03, 2023
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

2 Jan 07, 2022
Downloader Middleware to support Playwright in Scrapy & Gerapy

Gerapy Playwright This is a package for supporting Playwright in Scrapy, also this package is a module in Gerapy. Installation pip3 install gerapy-pla

Gerapy 85 Dec 31, 2022
This simple Python script allows you to download songs on Telegram🌸❤️😁

SongsDownloaderTgBot 📺 YouTube Song Downloader Bot For Telegram 🔮 3X Fast Telethon Based Bot ⚜ Open Source Bot 👨🏻‍💻 Demo : 𝗔𝗻𝗻𝗶𝗲 - 𝗘𝗹𝗶𝘇?

Sehath Perera 23 Dec 03, 2022
Simple avogadr.io batch downloader python script

Simple avogadr.io batch downloader python script

2 Jan 19, 2022
Pytube ve tkinter kütüphanesi ile yapmış olduğum basit ve temel bir youtube video indirme programı.

PyTube Pytube ve tkinter kütüphanesi ile yapmış olduğum basit ve temel bir youtube video indirme programı. Videolar 720p çözünürlükte indirilmektedir.

1 Nov 12, 2021
Code to scrape , download and upload to youtube daily

Youtube_Automated_Channel Code to scrape , download and upload to youtube daily INSTRUCTIONS Download the Github Repository Download and install Pytho

Atsiksdong 2 Dec 19, 2021
squid-dl is a massively parallel yt-dlp-based YouTube downloader.

squid-dl squid-dl is a massively parallel yt-dlp-based YouTube downloader. Installation Run the setup.py, which will install squid-dl and its two depe

tuxlovesyou 51 Jan 05, 2023
Tool to download Netflix in 4k

Netflix-4K-Script Tool to download Netflix in 4k You will need to get a L1 CDM that is whitelsited with Netflix CDM In this script are downgraded

9 Dec 23, 2021
A simple GUI video downloader built off of the python module 'yt-dlp'

Simple-Youtube-DL-Gui Supported Operating Systems Windows 7 (x64), Windows 8 (x64), and Windows 10 (x64) How to use Main Gui Extract program from arch

12 Dec 30, 2022
😷 Dowload dos documentos da CPI da Pandemia

A CPI da Pandemia recebeu milhares de documentos públicos, todos disponibilizados no site do Senado Federal.

Eduardo Cuducos 98 Sep 23, 2022
Download any video from YouTube playlists

youtube-dl Download any videos from YouTube playlists. Requirements Python 3 BeautifulSoup4 PyQt PyQtWebEngine pytube pyyoutube python-decouple Usage

Antonio Fortin 1 Oct 26, 2021
AkShare is an elegant and simple financial data interface library for Python, built for human beings! 开源财经数据接口库

Overview AkShare requires Python(64 bit) 3.7 or greater, aims to make fetch financial data as convenient as possible. Write less, get more! Documentat

Albert King 5.8k Jan 03, 2023
the best video downloader for terminals (currently only compatible with Linux and Windows)

the best video downloader for terminals (currently only compatible with Linux and Windows)

Amaral 2 Oct 14, 2021
A bot to download songs from YouTube to telegram.

Song-Downloader-Bot A BOT TO DOWNLOAD SONGS FROM YOUTUBE. Mandatory variables API_ID - Get It From my.telegram.org API_HASH - Get It From my.telegram.

Ashik Muhammed 38 Dec 11, 2022
You Can download any video/image in all social medias very easy and High Speed.

All-Downloader You Can download any video/image in all social medias very easy and High Speed. also you can easily download videos from web browsers s

Razor Kenway 14 Dec 16, 2022
YouTube Video Search Engine For Python

YouTube-Video-Search-Engine Introduction With the increasing demand for electronic devices, it is hard for people to choose the best products from mul

1 Dec 21, 2021