From: noarchwastaken <noarchwastaken@users.noreply.github.com>
To: ml@inbox.vuxu.org
Subject: Re: [PR PATCH] [Updated] New package: drawio-desktop-14.6.13
Date: Sun, 13 Jun 2021 05:14:18 +0200 [thread overview]
Message-ID: <20210613031418.g5LKkLp0kTcFoivTy4CEV-R0UZn6SARoKv9cWipA0Oc@z> (raw)
In-Reply-To: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-31195@inbox.vuxu.org>
[-- Attachment #1: Type: text/plain, Size: 1623 bytes --]
There is an updated pull request by noarchwastaken against master on the void-packages repository
https://github.com/noarchwastaken/void-packages drawio-desktop
https://github.com/void-linux/void-packages/pull/31195
New package: drawio-desktop-14.6.13
<!-- Mark items with [x] where applicable -->
#### General
- [x] This is a new package and it conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements)
#### Have the results of the proposed changes been tested?
- [x] I use the packages affected by the proposed changes on a regular basis and confirm this PR works for me
- [ ] I generally don't use the affected packages but briefly tested this PR
<!--
If GitHub CI cannot be used to validate the build result (for example, if the
build is likely to take several hours), make sure to
[skip CI](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration).
When skipping CI, uncomment and fill out the following section.
Note: for builds that are likely to complete in less than 2 hours, it is not
acceptable to skip CI.
-->
<!--
#### Does it build and run successfully?
(Please choose at least one native build and, if supported, at least one cross build. More are better.)
- [ ] I built this PR locally for my native architecture, (ARCH-LIBC)
- [ ] I built this PR locally for these architectures (if supported. mark crossbuilds):
- [ ] aarch64-musl
- [ ] armv7l
- [ ] armv6l-musl
-->
A patch file from https://github.com/void-linux/void-packages/pull/31195.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-drawio-desktop-31195.patch --]
[-- Type: text/x-diff, Size: 5207 bytes --]
From c6dd89547ef16a9f2851e30f6d8d21343ca13764 Mon Sep 17 00:00:00 2001
From: noarchwastaken <noarch@n0ar.ch>
Date: Fri, 28 May 2021 15:50:16 -0400
Subject: [PATCH] New package: drawio-desktop-14.6.13
---
srcpkgs/drawio-desktop/files/drawio | 2 +
srcpkgs/drawio-desktop/files/drawio.desktop | 10 +++
srcpkgs/drawio-desktop/files/drawio.xml | 8 +++
srcpkgs/drawio-desktop/template | 76 +++++++++++++++++++++
4 files changed, 96 insertions(+)
create mode 100644 srcpkgs/drawio-desktop/files/drawio
create mode 100644 srcpkgs/drawio-desktop/files/drawio.desktop
create mode 100644 srcpkgs/drawio-desktop/files/drawio.xml
create mode 100644 srcpkgs/drawio-desktop/template
diff --git a/srcpkgs/drawio-desktop/files/drawio b/srcpkgs/drawio-desktop/files/drawio
new file mode 100644
index 000000000000..719030008c28
--- /dev/null
+++ b/srcpkgs/drawio-desktop/files/drawio
@@ -0,0 +1,2 @@
+#!/bin/sh
+exec electron12 /usr/lib/drawio-desktop.asar "$@"
diff --git a/srcpkgs/drawio-desktop/files/drawio.desktop b/srcpkgs/drawio-desktop/files/drawio.desktop
new file mode 100644
index 000000000000..80bc4e74dea7
--- /dev/null
+++ b/srcpkgs/drawio-desktop/files/drawio.desktop
@@ -0,0 +1,10 @@
+[Desktop Entry]
+Name=draw.io
+Exec=drawio %U
+Terminal=false
+Type=Application
+Icon=drawio
+StartupWMClass=drawio
+Comment=diagrams.net desktop
+MimeType=application/vnd.jgraph.mxfile;application/vnd.visio;
+Categories=Graphics;
diff --git a/srcpkgs/drawio-desktop/files/drawio.xml b/srcpkgs/drawio-desktop/files/drawio.xml
new file mode 100644
index 000000000000..686729c26673
--- /dev/null
+++ b/srcpkgs/drawio-desktop/files/drawio.xml
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<mime-info xmlns='http://www.freedesktop.org/standards/shared-mime-info'>
+ <mime-type type="application/vnd.jgraph.mxfile">
+ <sub-class-of type="application/xml"/>
+ <comment>draw.io Diagrams</comment>
+ <glob pattern="*.drawio"/>
+ </mime-type>
+</mime-info>
diff --git a/srcpkgs/drawio-desktop/template b/srcpkgs/drawio-desktop/template
new file mode 100644
index 000000000000..d33c5e6cea90
--- /dev/null
+++ b/srcpkgs/drawio-desktop/template
@@ -0,0 +1,76 @@
+# Template file for 'drawio-desktop'
+pkgname=drawio-desktop
+version=14.6.13
+revision=1
+_electron_ver=12
+hostmakedepends="yarn app-builder"
+makedepends="electron${_electron_ver}"
+depends="electron${_electron_ver} libnotify"
+short_desc="Diagram drawing application built on web technology"
+maintainer="noarchwastaken <noarch@n0ar.ch>"
+license="Apache-2.0"
+homepage="https://github.com/jgraph/drawio-desktop"
+distfiles="
+ https://github.com/jgraph/drawio/archive/v${version}.tar.gz>drawio-v${version}.tar.gz
+ https://github.com/jgraph/drawio-desktop/archive/v${version}.tar.gz>drawio-desktop-v${version}.tar.gz"
+checksum="83f27e7acafa434bc3287081ef5cdd5000c03c7c175e078cae4f997ff7100120
+ fa7e1916844fb2b5d6227ec3f2a753f8ee1de074ad05b24d770d586ab0e8bd43"
+
+do_extract() {
+ # simulate git-submodules
+ bsdtar -x --no-same-permissions --no-same-owner -f ${XBPS_SRCDISTDIR}/${pkgname}-${version}/${pkgname}-v${version}.tar.gz --strip-components=1
+ bsdtar -x --no-same-permissions --no-same-owner -f ${XBPS_SRCDISTDIR}/${pkgname}-${version}/drawio-v${version}.tar.gz --strip-components=1 -C drawio
+}
+
+do_configure() {
+ # disable updater
+ vsed '/electron-updater/d' -i package.json drawio/src/main/webapp/package.json
+ UPDATER='const autoUpdater = { on: () => {}, setFeedURL: () => {}, checkForUpdates: () => {} }'
+ vsed -e 's/.*require("electron-updater").*/'"${UPDATER}"'/' -e '/checkForUpdates,/d' -i drawio/src/main/webapp/electron.js
+}
+
+do_build() {
+ export USE_SYSTEM_APP_BUILDER=true
+ export NODE_ENV=production
+
+ yarn add electron-builder electron-notarize # for electron-builder
+ yarn install
+ yarn sync
+ yarn run electron-builder --linux --x64 --dir \
+ --config electron-builder-linux-mac.json \
+ -c.electronDist=/usr/lib/electron${_electron_ver} \
+ -c.electronVersion="$(</usr/lib/electron${_electron_ver}/version)"
+}
+
+do_install() {
+ vinstall "dist/linux-unpacked/resources/app.asar" 644 /usr/lib "drawio-desktop.asar"
+
+ vbin "${FILESDIR}/drawio"
+
+ # create desktop file
+ vinstall "${FILESDIR}/drawio.desktop" 0644 "usr/share/applications"
+
+ # bitmap icons
+ find 'build' -regex '.*/[0-9]+x[0-9]+\.png' |
+ grep -o '[0-9]\+' |
+ sort -u |
+ while read size; do
+ if [[ -f "build/${size}x${size}.png" ]]; then
+ vinstall "build/${size}x${size}.png" 0644 \
+ "usr/share/icons/hicolor/${size}x${size}/apps" "drawio.png"
+ vmkdir "usr/share/icons/hicolor/${size}x${size}/mimetypes"
+ ln -s "/usr/share/icons/hicolor/${size}x${size}/apps/drawio.png" \
+ "${DESTDIR}/usr/share/icons/hicolor/${size}x${size}/mimetypes/application-x-drawio.png"
+ fi
+ done
+
+ # vector icons
+ vinstall "build/icon.svg" 0644 \
+ "/usr/share/icons/hicolor/scalable/apps" "drawio.svg"
+ vmkdir "usr/share/icons/hicolor/scalable/mimetypes"
+ ln -s "/usr/share/icons/hicolor/scalable/apps/drawio.svg" \
+ "${DESTDIR}/usr/share/icons/hicolor/scalable/mimetypes/application-x-drawio.svg"
+
+ # create mime type
+ vinstall "${FILESDIR}/drawio.xml" 0644 "usr/share/mime/packages"
+}
next prev parent reply other threads:[~2021-06-13 3:14 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-28 19:52 [PR PATCH] " noarchwastaken
2021-05-28 20:29 ` [PR PATCH] [Updated] " noarchwastaken
2021-05-28 20:38 ` noarchwastaken
2021-05-28 20:59 ` noarchwastaken
2021-05-28 21:12 ` noarchwastaken
2021-05-29 1:41 ` Johnnynator
2021-05-29 3:46 ` noarchwastaken
2021-05-30 4:58 ` [PR PATCH] [Updated] " noarchwastaken
2021-06-13 3:01 ` noarchwastaken
2021-06-13 3:03 ` noarchwastaken
2021-06-13 3:04 ` noarchwastaken
2021-06-13 3:14 ` noarchwastaken [this message]
2021-06-13 3:51 ` [PR PATCH] [Updated] " noarchwastaken
2022-05-21 1:59 ` github-actions
2022-06-04 2:08 ` [PR PATCH] [Closed]: " github-actions
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210613031418.g5LKkLp0kTcFoivTy4CEV-R0UZn6SARoKv9cWipA0Oc@z \
--to=noarchwastaken@users.noreply.github.com \
--cc=ml@inbox.vuxu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).