mirror of
https://github.com/hensm/fx_cast.git
synced 2026-06-12 10:39:57 +00:00
Centralize package info and do version checking between app/ext
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
Package: fx-cast-bridge
|
||||
Version: 0.0.1
|
||||
Package: {{packageName}}
|
||||
Version: {{applicationVersion}}
|
||||
Priority: optional
|
||||
Architecture: amd64
|
||||
Description: fx_cast Bridge application
|
||||
Description: {{applicationName}}
|
||||
|
||||
@@ -1,20 +0,0 @@
|
||||
Name: fx_cast_bridge
|
||||
Summary: fx_cast Bridge application
|
||||
Version: 0.0.1
|
||||
Release: 1
|
||||
License: MIT
|
||||
|
||||
%description
|
||||
fx_cast Bridge application
|
||||
|
||||
%install
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
mkdir -p $RPM_BUILD_ROOT/opt/fx_cast/ \
|
||||
$RPM_BUILD_ROOT/usr/lib/mozilla/native-messaging-hosts/
|
||||
|
||||
cp %{_distdir}/bridge $RPM_BUILD_ROOT/opt/fx_cast/
|
||||
cp %{_distdir}/fx_cast_bridge.json $RPM_BUILD_ROOT/usr/lib/mozilla/native-messaging-hosts/
|
||||
|
||||
%files
|
||||
/opt/fx_cast/bridge
|
||||
/usr/lib/mozilla/native-messaging-hosts/fx_cast_bridge.json
|
||||
20
app/packaging/linux/rpm/package.spec
Normal file
20
app/packaging/linux/rpm/package.spec
Normal file
@@ -0,0 +1,20 @@
|
||||
Name: {{packageName}}
|
||||
Summary: {{applicationName}}
|
||||
Version: {{applicationVersion}}
|
||||
Release: 1
|
||||
License: MIT
|
||||
|
||||
%description
|
||||
{{applicationName}}
|
||||
|
||||
%install
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
mkdir -p $RPM_BUILD_ROOT/{{{executablePath}}} \
|
||||
$RPM_BUILD_ROOT/{{{manifestPath}}}
|
||||
|
||||
cp %{_distdir}/{{{executableName}}} $RPM_BUILD_ROOT/{{{executablePath}}}
|
||||
cp %{_distdir}/{{{manifestName}}} $RPM_BUILD_ROOT/{{{manifestPath}}}
|
||||
|
||||
%files
|
||||
{{{executablePath}}}/{{{executableName}}}
|
||||
{{{manifestPath}}}/{{{manifestName}}}
|
||||
@@ -1,17 +1,17 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<installer-gui-script minSpecVersion="1">
|
||||
<title>fx_cast Bridge</title>
|
||||
<title>{{applicationName}}</title>
|
||||
<domains enable_anywhere="false" enable_currentUserHome="true" enable_localSystem="true" />
|
||||
<pkg-ref id="tf.matt.fx_cast_bridge"/>
|
||||
<pkg-ref id="{{packageId}}"/>
|
||||
<options customize="never" require-scripts="false"/>
|
||||
<choices-outline>
|
||||
<line choice="default">
|
||||
<line choice="tf.matt.fx_cast_bridge"/>
|
||||
<line choice="{{packageId}}"/>
|
||||
</line>
|
||||
</choices-outline>
|
||||
<choice id="default"/>
|
||||
<choice id="tf.matt.fx_cast_bridge" visible="false">
|
||||
<pkg-ref id="tf.matt.fx_cast_bridge"/>
|
||||
<choice id="{{packageId}}" visible="false">
|
||||
<pkg-ref id="{{packageId}}"/>
|
||||
</choice>
|
||||
<pkg-ref id="tf.matt.fx_cast_bridge" version="0.0.1" onConclusion="none">fx_cast_bridge_default.pkg</pkg-ref>
|
||||
<pkg-ref id="{{packageId}}" onConclusion="none">{{componentName}}</pkg-ref>
|
||||
</installer-gui-script>
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
# If the target location isn't root, we need to rewrite
|
||||
# the manifest path to point to the user directory.
|
||||
if [ "$2" != "/" ]; then
|
||||
manifestPath=$2"/Library/Application Support/Mozilla/NativeMessagingHosts/fx_cast_bridge.json"
|
||||
manifestPath=$2"/Library/Application Support/Mozilla/NativeMessagingHosts/{{{manifestName}}}"
|
||||
sed -i.bak 's,"path": "/Library,"path": "'$2'/Library,g' "$manifestPath"
|
||||
rm "$manifestPath.bak"
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user