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
This repository contains code for a youtube-dl GUI written in PyQt.

youtube-dl-GUI This repository contains code for a youtube-dl GUI written in PyQt. It is based on youtube-dl which is a Video downloading script maint

M.Yasoob Ullah Khalid ☺ 191 Jan 02, 2023
YTPY Youtube Downloader Made by: Ferreira, Amarau and Rodric

YTPY Youtube Downloader Made by: Ferreira, Amarau and Rodric How to Install on Linux: sudo apt install python3 python3-pip git pip install pytube git

7 Nov 24, 2022
Convert BMS songs to osu! With options to convert keysounds and convert to 7key.

bmx2osu Convert BMS to osu! With options to: convert keysounds to one song file using BMX2WAV include 7k version change Overall Difficulty and HP Drai

7 Nov 28, 2022
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
Downloads photos you saved from a specific profile.

instagram-download-saved A python script that downloads photos you saved from a specific profile. The only dependency is instaloader, an open-source p

Aviv 1 Dec 19, 2021
In this repository you will find the test carried out to enter, as a python developer, the company Keeper Solutions.

Bookmarks In this repository you will find the test carried out to enter, as a python developer, the company Keeper Solutions. First it is necessary t

0 Jan 12, 2022
A Python script to download PDB files associated with a Portable Executable (PE)

A Python script to download PDB files associated with a Portable Executable (PE)

Podalirius 33 Jan 03, 2023
Pantheon - The fastest YouTube downloader.

A Youtube downloader written in Python3, using HTTP requests and an API.

Billy 38 Nov 21, 2022
命令行版本的HLS/DASH流下载器,支持标准AES-128-CBC解密

XstreamDL-CLI 基于python 3.7.4+的,命令行版本的,HLS/DASH流下载器,支持标准AES-128-CBC解密 使用 首先安装必要的库

xhlove 239 Dec 31, 2022
Simple avogadr.io batch downloader python script

Simple avogadr.io batch downloader python script

2 Jan 19, 2022
Tool To download Amazon 4k SDR HDR 1080, CDM IS Not Included

WV-AMZN-4K-RIPPER Tool To download Amazon 4k SDR HDR 1080, CDM IS Not Included For CDM You can Mail :- Denis Trunov 179 Dec 17, 2022

Scripts to download files and folders programmatically from Google Drive

Google Drive Downloader Scripts Every time I need to download a lot of files from Google Drive (e.g. a dataset), it's always incredibly frustrating an

Ivan Evtimov 6 Jul 22, 2021
Download all games from a public Itch.io Game Jam

Itch Jam Downloader Downloads all games from a public Itch.io Game Jam. What you'll need: Python 3.8+ pip install -r requirements.txt For site mirrori

Dragoon Aethis 19 Dec 07, 2022
Python script for downloading audio from YouTube songs/videos.

Python script for downloading audio from YouTube songs/videos. All you have to do is specify the path to your folder and then type song's/video's name and the sound will be downloaded into your folde

Mateusz Polis 0 Oct 05, 2022
This is a tool to allow downloading any links from r/Roms Magethread

ILYFPR This is a tool to allow downloading any links from r/Roms Magethread Limitations: It downloads ALL roms of the system you choose. This will be

Erase 4 Nov 04, 2021
music downloader written in python. (Uses jiosaavn API)

music downloader written in python. (Uses jiosaavn API)

Rohn Chatterjee 35 Jul 20, 2022
Download a large file from Google Drive (curl/wget fails because of the security notice).

gdown Download a large file from Google Drive. Description Download a large file from Google Drive. If you use curl/wget, it fails with a large file b

Kentaro Wada 2.7k Jan 09, 2023
Python module to download all media from a CyberDrop gallery.

CyberDrop Downloader Intro Let's suppose you found out the Eva G (bby_gee) leak on https://cyberdrop.me/a/aWAt4TWY. You wish you could download the en

Quatrecentquatre 1 Dec 12, 2021
Storing, versioning, and downloading files from S3 made as easy as using open() in Python. Caching included.

open(LARGE) Storing, versioning, and downloading files from S3 made as easy as using open() in Python. Caching included. Motivation Oftentimes, especi

András Schmelczer 2 Jan 30, 2022
A Celery application to collect data, download media and extract information from social media APIs

Project IBEX A Celery application to collect data, download media and extract information from social media APIs. Requirements You must have a Redis D

ibex 4 Dec 15, 2022