From 865ffb458803cd8fa8b1ebd3067cbc2f6aaa4ea9 Mon Sep 17 00:00:00 2001 From: Emmanuel Averty Date: Sat, 16 Mar 2024 17:13:54 +0100 Subject: [PATCH] add documentation in resources.py --- src/utils/resources.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/utils/resources.py b/src/utils/resources.py index 166be46f2..0a645cb69 100644 --- a/src/utils/resources.py +++ b/src/utils/resources.py @@ -317,6 +317,9 @@ class SourcesResource(AppResource): - `format` : The "format" of the asset. It is typically automatically guessed from the extension of the URL (or the mention of "tarball", "zipball" in the URL), but can be set explicitly: - `tar.gz`, `tar.xz`, `tar.bz2` : will use `tar` to extract the archive - `zip` : will use `unzip` to extract the archive + - `gz` : will use `gunzip` to extract + - `bz2` : will use `bunzip2` to extract + - `xz` : will use `xz -d` to extract - `docker` : useful to extract files from an already-built docker image (instead of rebuilding them locally). Will use `docker-image-extract` - `whatever`: whatever arbitrary value, not really meaningful except to imply that the file won't be extracted (eg because it's a .deb to be manually installed with dpkg/apt, or a script, or ...) - `in_subdir`: `true` (default) or `false`, depending on if there's an intermediate subdir in the archive before accessing the actual files. Can also be `N` (an integer) to handle special cases where there's `N` level of subdir to get rid of to actually access the files