Import from URL / from GitHub

So I typically have to wait a few weeks to push my packages to Typst Universe; a process that I’ve found to be exceptionally slow. I note that most other ecosystems (e.g. PyPI) may take just a few seconds to accomplish the same process.

For this reason I’m looking to begin transitioning my Typst work away from TU, in the interests of finding a faster development process.

Does anyone know of a way to #import from GitHub, or more generally from a URL? (Or has someone written a package that would make this possible? I could install this manually + bootstrap from there. This is for packages that are dual-use between both my personal and my corporate use.)

I’ve not been able to find anything, but I thought I’d ask here in case others have seen this.

I assume the main slowdown with the universe is waiting for the PR to be merged, is that correct?

As far as I know typst is only able to import local files, with the only exception being that it can make a request to import things from the universe. If I were you, i’d look into making a local package, which has worked for my needs:

Local packages
Want to install a package locally on your system without publishing it or experiment with it before publishing? You can store packages in {data-dir}/typst/packages/{namespace}/{name}/{version} to make them available locally on your system. Here, {data-dir} is
* $XDG_DATA_HOME or ~/.local/share on Linux
* ~/Library/Application Support on macOS
* %APPDATA% on Windows
You may also run typst info and check Package path for the actual path. This would be helpful if you have installed the Typst compiler from Snap or are using special environment variables.
You can create an arbitrary {namespace}. A good namespace for system-local packages is local. Using this namespace:
* Store a package in {data-dir}/typst/packages/local/mypkg/1.0.0
* Import from it with #import "@local/mypkg:1.0.0": *.
Packages in the data directory have precedence over ones in the cache directory.
Note that future iterations of Typst’s package management may change/break this local setup.

You could then push your local package(s) onto a private git repository, and fetch them manually once you’ve updated them (and there are probably many easy ways of automating this fetching depending on the level of automation you desire)