SHA256
1
0
forked from pool/asar

Accepting request 1112369 from devel:languages:nodejs

OBS-URL: https://build.opensuse.org/request/show/1112369
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/asar?expand=0&rev=4
This commit is contained in:
Ana Guerrero 2023-09-21 20:13:37 +00:00 committed by Git OBS Bridge
commit 16bf61e24e
7 changed files with 26 additions and 14 deletions

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Tue Sep 19 17:12:27 UTC 2023 - Bruno Pitrus <brunopitrus@hotmail.com>
- New upstream version 3.2.5
* properly handle rejections on `createPackageWithOptions`
-------------------------------------------------------------------
Tue Jan 17 21:50:31 UTC 2023 - Bruno Pitrus <brunopitrus@hotmail.com>
- New upstream version 3.2.3

View File

@ -17,7 +17,7 @@
Name: asar
Version: 3.2.3
Version: 3.2.5
Release: 0
Summary: Creating atom-shell (electron) app packages
License: MIT and ISC
@ -25,7 +25,7 @@ Group: Development/Languages/NodeJS
Url: https://github.com/electron/asar
Source0: https://github.com/electron/asar/archive/refs/tags/v%{version}.tar.gz
# Created by prepare-vendor.sh
Source1: vendor.tar.xz
Source1: vendor.tar.zst
Source2: prepare_vendor.sh
BuildArch: noarch
@ -33,7 +33,12 @@ BuildArch: noarch
BuildRequires: fdupes
BuildRequires: jq
BuildRequires: nodejs-packaging
%if 0%{?fedora} >= 37
BuildRequires: nodejs-npm
%else
BuildRequires: npm
%endif
BuildRequires: zstd
%global __requires_exclude ^npm(.*)$
Provides: nodejs-asar = %{version}
@ -91,7 +96,7 @@ find -name '.releaserc*' -type f -print -delete
%defattr(-,root,root)
%doc CHANGELOG.md README.md
%license LICENSE.md
/usr/bin/asar
%{_bindir}/asar
%{nodejs_sitelib}
%changelog

View File

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -x
# shellcheck disable=2181
ASAR_PKGDIR="$(pwd)"
@ -41,7 +41,7 @@ pushd "$ASAR_PATH" || cleanup_and_exit 1
echo ">>>>>> Install npm modules"
yarn install --pure-lockfile --ignore-engines --ignore-scripts --production
yarn install --pure-lockfile --ignore-engines --ignore-scripts --production --link-duplicates
ret=$?
if [ $ret -ne 0 ]; then
echo "ERROR: yarn install failed"
@ -53,6 +53,7 @@ find node_modules/ -name "*.node" -print -delete
find node_modules/ -name "*.wasm" -print -delete
find node_modules/ -name "*.jar" -print -delete
find node_modules/ -name "*.dll" -print -delete
find node_modules/ -name "*.exe" -print -delete
find node_modules/ -name "*.dylib" -print -delete
find node_modules/ -name "*.so" -print -delete
find node_modules/ -name "*.o" -print -delete
@ -68,12 +69,12 @@ find . -type f| sponge |\
echo ">>>>>> Package vendor files"
rm -f "${ASAR_PKGDIR}/vendor.tar.xz"
XZ_OPT="-T$(nproc) -e9 -vv" tar -vvJcf "${ASAR_PKGDIR}/vendor.tar.xz" node_modules
rm -f "${SIGNAL_PKGDIR}/vendor.tar.zst"
ZSTD_CLEVEL=19 ZSTD_NBTHREADS=$(nproc) tar --zstd --sort=name -vvScf "${ASAR_PKGDIR}/vendor.tar.zst" node_modules
if [ $? -ne 0 ]; then
cleanup_and_exit 1
fi
echo "vendor $(du -sh "${ASAR_PKGDIR}/vendor.tar.xz")"
echo "vendor $(du -sh "${ASAR_PKGDIR}/vendor.tar.zst")"
popd || cleanup_and_exit 1

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:abea204a5d213eed8638c2dd0a507b7f6e89122f09290a84b471a6e660e947d8
size 104776

3
v3.2.5.tar.gz Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:bfe03f456c0027d589a95a459b501b9fa186cadf78892cc8f1ab733eef052dd6
size 107709

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:0b8a7b6bbe19544e16ab7d699d550165e9bb0294982dece2f0be5c1317761915
size 337656

3
vendor.tar.zst Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:39c093d46673cc156397d456ee040ba4ea362dd7dd4944c31ce18801535b1f45
size 86781