
wget
github.comからtarballをインポートして、一時ファイルを作成せずにサブディレクトリを抽出しようとしています。
wget -qO- https://github.com/django-nonrel/django-nonrel/tarball/develop | tar xzf - django
エラーが発生します。
tar: django: Not found in archive
tar: Exiting with failure status due to previous errors
明らかに私は何か間違っています。
答え1
--strip-components=1
djangoディレクトリ自体は作成されたgzipコンテンツのサブディレクトリなので、GNU tarオプションを使用する必要があります。 GNU tarを使用するとします。次に、tarに名前付きサブディレクトリを探していることを知らせる必要がありますdjango
。
wget -qO- https://github.com/django-nonrel/django-nonrel/tarball/develop | tar --strip-components=1 -zxf - \*/django
FWIW、私も--no-check-certificate
使用する必要がありますwget
。