Compare commits
14 Commits
| Author | SHA256 | Date | |
|---|---|---|---|
| 750d2a4ef1 | |||
| bda732a074 | |||
| 7518e65a9b | |||
| 537b867cb8 | |||
| 496eaf413e | |||
| 6d8cbf72ba | |||
| 168a67c8d1 | |||
| 5097a364ef | |||
| c2b2d41901 | |||
| 4cd355a6ee | |||
| abcd16d6ef | |||
| 06c1683168 | |||
| 0b9da1d25c | |||
| 4158b31df9 |
51
asar.changes
51
asar.changes
@@ -1,3 +1,54 @@
|
||||
-------------------------------------------------------------------
|
||||
Sat May 17 11:40:13 UTC 2025 - Bruno Pitrus <brunopitrus@hotmail.com>
|
||||
|
||||
- New upstream release 4.0.0
|
||||
* Rewrite program to use ES modules and require Node 22
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Apr 7 14:04:51 UTC 2025 - Bruno Pitrus <brunopitrus@hotmail.com>
|
||||
|
||||
- New upstream release 3.4.1
|
||||
* allow ../ symlink Streams when they're still within the package (gh#electron/asar#363)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Apr 2 10:29:53 UTC 2025 - Bruno Pitrus <brunopitrus@hotmail.com>
|
||||
|
||||
- New upstream release 3.4.0
|
||||
* add in-memory API for streaming files to destination asar
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Jan 7 20:14:41 UTC 2025 - Bruno Pitrus <brunopitrus@hotmail.com>
|
||||
|
||||
- New upstream release 3.2.18
|
||||
* Respect unpack minimatch for symlinks within previously unpacked directories (gh#electron/asar#341)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Nov 7 10:57:33 UTC 2024 - Bruno Pitrus <brunopitrus@hotmail.com>
|
||||
|
||||
- New upstream release 3.2.17
|
||||
* isUnpackedDir matches non-child directories that have same folder name prefix (gh#electron/asar#333)
|
||||
* checking if symlink with same prefix points outside the directory (gh#electron/asar#335)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Nov 6 15:52:11 UTC 2024 - Bruno Pitrus <brunopitrus@hotmail.com>
|
||||
|
||||
- New upstream release 3.2.16
|
||||
* Enable getNode to follow directory links (gh#electron/asar#248)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Sep 11 08:00:37 UTC 2024 - Bruno Pitrus <brunopitrus@hotmail.com>
|
||||
|
||||
- New upstream release 3.2.13
|
||||
* Export a `default` property (gh#electron/asar#325)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Sep 10 20:20:43 UTC 2024 - Bruno Pitrus <brunopitrus@hotmail.com>
|
||||
|
||||
- New upstream release 3.2.11
|
||||
* complete rewrite of the program in Typescript
|
||||
* ensure symlinks do not write unexpectedly (gh#electron/asar#322)
|
||||
- Run test suite in %check
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Sun May 5 15:36:24 UTC 2024 - Bruno Pitrus <brunopitrus@hotmail.com>
|
||||
|
||||
|
||||
48
asar.spec
48
asar.spec
@@ -17,7 +17,7 @@
|
||||
|
||||
|
||||
Name: asar
|
||||
Version: 3.2.10
|
||||
Version: 4.0.0
|
||||
Release: 0
|
||||
Summary: Creating atom-shell (electron) app packages
|
||||
License: MIT and ISC
|
||||
@@ -38,6 +38,7 @@ BuildRequires: nodejs-npm
|
||||
%else
|
||||
BuildRequires: npm
|
||||
%endif
|
||||
BuildRequires: typescript
|
||||
BuildRequires: zstd
|
||||
|
||||
%global __requires_exclude ^npm(.*)$
|
||||
@@ -50,24 +51,39 @@ having random access support.
|
||||
|
||||
%prep
|
||||
%autosetup -p1 -a 1
|
||||
# Use system typescript for building
|
||||
rm -rf node_modules/typescript
|
||||
rm -v node_modules/.bin/ts{c,server}
|
||||
|
||||
%build
|
||||
export ELECTRON_SKIP_BINARY_DOWNLOAD=1
|
||||
npm rebuild --verbose --foreground-scripts
|
||||
# tsc may return a non-zero exit code due to type warnings despite actually succesfully compiling the code.
|
||||
# If it fails to compile, it will be catched anyway in #check.
|
||||
tsc --removeComments --sourceMap false || true
|
||||
|
||||
%install
|
||||
mkdir -pv %{buildroot}%{nodejs_sitelib}/@electron
|
||||
mkdir -pv %{buildroot}%{_bindir}
|
||||
cp -lr . %{buildroot}%{nodejs_sitelib}/@electron/asar
|
||||
ln -srv %{buildroot}%{nodejs_sitelib}/@electron/asar/bin/asar.js %{buildroot}%{_bindir}/asar
|
||||
cp -alr . %{buildroot}%{nodejs_sitelib}/@electron/asar
|
||||
ln -srv %{buildroot}%{nodejs_sitelib}/@electron/asar/bin/asar.mjs %{buildroot}%{_bindir}/asar
|
||||
# symlink old package name
|
||||
ln -srv %{buildroot}%{nodejs_sitelib}/{@electron/,}asar
|
||||
#fix shebang
|
||||
sed -i '1s/env //' %{buildroot}%{nodejs_sitelib}/@electron/asar/bin/asar.js
|
||||
sed -i '1s/env //' %{buildroot}%{nodejs_sitelib}/@electron/asar/bin/asar.mjs
|
||||
cd %{buildroot}%{nodejs_sitelib}/asar
|
||||
|
||||
# Correct bogus version in package.json
|
||||
jq -cj '.version="%{version}"' package.json > new
|
||||
mv new package.json
|
||||
|
||||
#remove devdependencies
|
||||
jq -cj 'del(.devDependencies)' package.json > tmp
|
||||
mv -v tmp package.json
|
||||
npm prune --omit=dev --verbose --ignore-scripts
|
||||
|
||||
mv -v new package.json
|
||||
|
||||
|
||||
#Remove development garbage
|
||||
find -name example -print0 |xargs -r0 -- rm -rvf
|
||||
find -name test -print0 |xargs -r0 -- rm -rvf
|
||||
@@ -76,7 +92,10 @@ find -name @types -print0 |xargs -r0 -- rm -rvf
|
||||
find -name .github -print0 |xargs -r0 -- rm -rvf
|
||||
find -name .circleci -print0 |xargs -r0 -- rm -rvf
|
||||
find -name '*.md' -type f -print -delete
|
||||
find -name '*.map' -type f -print -delete
|
||||
find -name '*.markdown' -type f -print -delete
|
||||
find -name '*.cts' -type f -print -delete
|
||||
find -name '*.mts' -type f -print -delete
|
||||
find -name '*.ts' -type f -print -delete
|
||||
find -name '.*.yml' -type f -print -delete
|
||||
find -name '.*ignore' -type f -print -delete
|
||||
@@ -84,17 +103,32 @@ find -name 'snapcraft*' -type f -print -delete
|
||||
find -name '.git*' -type f -print -delete
|
||||
find -name yarn.lock -type f -print -delete
|
||||
find -name '.yarn*' -type f -print -delete
|
||||
find -name '*package-lock.json' -type f -print -delete
|
||||
find -name '.prettierrc*' -type f -print -delete
|
||||
find -name '.releaserc*' -type f -print -delete
|
||||
find -name '.mocharc*' -type f -print -delete
|
||||
find -name tsconfig.json -type f -print -delete
|
||||
find -name .nvmrc -type f -print -delete
|
||||
|
||||
#remove symlink to no longer existent dev executable
|
||||
rm -v node_modules/.bin/node-which
|
||||
|
||||
# Remove empty directories
|
||||
find . -type d -empty -print -delete
|
||||
|
||||
%fdupes %{buildroot}
|
||||
|
||||
%check
|
||||
pushd %{buildroot}%{nodejs_sitelib}
|
||||
# https://docs.fedoraproject.org/en-US/packaging-guidelines/Node.js/#_build_testing_in_check
|
||||
%{__nodejs} -e 'require("./")'
|
||||
%{__nodejs} -e 'require("@electron/asar")'
|
||||
|
||||
#check that the executable starts
|
||||
./@electron/asar/bin/asar.mjs -h
|
||||
popd
|
||||
|
||||
#We can't run tests, we don't have mocha available.
|
||||
#the actual test suite
|
||||
npx mocha -- --timeout '"20000"'
|
||||
|
||||
%files
|
||||
%defattr(-,root,root)
|
||||
|
||||
@@ -40,7 +40,7 @@ pushd "$ASAR_PATH" || cleanup_and_exit 1
|
||||
|
||||
|
||||
echo ">>>>>> Install npm modules"
|
||||
yarn install --frozen-lockfile --ignore-engines --ignore-platform --ignore-scripts --production --link-duplicates
|
||||
yarn install --frozen-lockfile --ignore-engines --ignore-platform --ignore-scripts --link-duplicates
|
||||
ret=$?
|
||||
if [ $ret -ne 0 ]; then
|
||||
echo "ERROR: yarn install failed"
|
||||
@@ -65,7 +65,8 @@ echo '>>>>>> Remove vendored binaries'
|
||||
find . -type f| sponge |\
|
||||
xargs -P"$(nproc)" -- sh -c 'file "$@" | grep -v '\'': .*script'\'' | grep '\'': .*executable'\'' | tee /dev/stderr | sed '\''s/: .*//'\'' | xargs rm -fv'
|
||||
|
||||
|
||||
echo ">>>>>> Remove empty directories"
|
||||
find . -type d -empty -print -delete
|
||||
|
||||
echo ">>>>>> Package vendor files"
|
||||
rm -f "${ASAR_PKGDIR}/vendor.tar.zst"
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:b1756c31e8cd42257081b81726b1489a3923709e4cbf86f7d377fab3870b1e26
|
||||
size 83884
|
||||
3
v4.0.0.tar.gz
Normal file
3
v4.0.0.tar.gz
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:309ee3662aaeebf60ccf3d4ec7be43022114cc035d2a481deb50651d8f627643
|
||||
size 79872
|
||||
@@ -1,3 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:cb65f1c689dc7f1915c21590c44e95fb9d573e752c35026277e25bc0521a0a1b
|
||||
size 79194
|
||||
oid sha256:4ef8b0898802b682c6728873ffcdf7fbf982e6072cc87bc44dd6ae24b89870f1
|
||||
size 9525130
|
||||
|
||||
Reference in New Issue
Block a user