-
-
Notifications
You must be signed in to change notification settings - Fork 86
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: update Linux build and add rpm
- Loading branch information
Showing
6 changed files
with
102 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
#!/bin/sh | ||
|
||
# Test requirements | ||
if ! type "shyaml" > /dev/null; then | ||
echo "shyaml is required, install with pip3 install shyaml" | ||
fi | ||
|
||
# Go to project folder | ||
cd $(dirname $0) | ||
cd ../ | ||
|
||
# Read project information | ||
NAME=$(cat pubspec.yaml | shyaml get-value name) | ||
VERSION=$(cat pubspec.yaml | shyaml get-value version | grep -oE "^[^+]+") | ||
DESCRIPTION=$(cat pubspec.yaml | shyaml get-value description) | ||
|
||
# Build project and create structure | ||
flutter build linux --release | ||
mkdir -p build/fedora/release | ||
cp -r build/linux/x64/release/bundle/ build/fedora/release/kitchenowl | ||
cp linux/icon.png build/fedora/release/kitchenowl | ||
|
||
SPEC_FILE="build/fedora/release/$NAME.spec" | ||
echo "Version: v$VERSION" > $SPEC_FILE | ||
cat fedora/$NAME.spec >> $SPEC_FILE | ||
|
||
DESKTOP_FILE="build/fedora/release/$NAME.desktop" | ||
echo "[Desktop Entry]" > $DESKTOP_FILE | ||
echo "Exec=$NAME" >> $DESKTOP_FILE | ||
echo "Icon=/usr/$NAME/icon.png" >> $DESKTOP_FILE | ||
# echo "Name=$NAME" >> $DESKTOP_FILE | ||
echo "Comment=$DESCRIPTION" >> $DESKTOP_FILE | ||
echo "Version=$VERSION" >> $DESKTOP_FILE | ||
cat linux/$NAME.desktop >> $DESKTOP_FILE | ||
|
||
|
||
# Build and cleanup | ||
cd build/fedora/release/ | ||
QA_RPATHS=0x0002 fedpkg --release f35 local |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
Name: KitchenOwl | ||
Release: 1%{?dist} | ||
Summary: KitchenOwl helps you organize your grocery life | ||
License: Apache 2.0 | ||
Source0: kitchenowl | ||
Source1: kitchenowl.desktop | ||
Requires: jsoncpp | ||
Requires: libsecret | ||
|
||
%description | ||
KitchenOwl helps you organize your grocery life. | ||
|
||
%install | ||
mkdir -p %{buildroot}%{_datadir}/kitchenowl | ||
mkdir -p %{buildroot}%{_datadir}/applications | ||
mkdir -p %{buildroot}%{_bindir} | ||
cp -R %{SOURCE0} %{buildroot}%{_datadir} | ||
chmod +x %{buildroot}%{_datadir}/kitchenowl/kitchenowl | ||
ln -s %{_datadir}/kitchenowl/kitchenowl %{buildroot}%{_bindir} | ||
install -p -m 755 %{SOURCE1} %{buildroot}%{_datadir}/applications | ||
|
||
%files | ||
%defattr(-,root,root) | ||
%dir %{_datadir}/kitchenowl | ||
%{_datadir}/applications/kitchenowl.desktop | ||
%{_datadir}/kitchenowl | ||
%{_bindir}/kitchenowl | ||
|
||
%clean | ||
rm -rf %{buildroot} | ||
|
||
%changelog | ||
* Tue Mar 30 2021 Tom Bursch <[email protected]> - 22 | ||
- Initial Release | ||
|
File renamed without changes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
Name=KitchenOwl | ||
Icon=/usr/lib/kitchenowl/icon.png | ||
Terminal=false | ||
Type=Application | ||
Categories=Utility;X-Productivity; |