Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor Code, Update .gitignore, Add Fallback Installation Command #29

Open
wants to merge 12 commits into
base: master
Choose a base branch
from

Conversation

Nusab19
Copy link

@Nusab19 Nusab19 commented Apr 2, 2024

  • Add constant variables to use across the app.
  • Reduce code duplication
  • Refactor code and format using black
  • Add fallback installation command for windows
  • Update .gitignore file
  • Add note about running installation command(windows) in CMD
  • Add basic unittest for the application

Copy link

vercel bot commented Apr 2, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
blink-eye ✅ Ready (Inspect) Visit Preview 💬 Add feedback Apr 3, 2024 1:05pm

Copy link
Contributor

@fluentmoheshwar fluentmoheshwar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove icon from linux build script it's not supported on linux

@fluentmoheshwar
Copy link
Contributor

Update BlinkEye_Fedora.spec to this:

Name:           BlinkEye
Version:        1.4.0
Release:        1%{?dist}
Summary:        Blink Eye is a minimalist eye care reminder app designed to reduce eye strain during extended screen usage.

License:        MIT
URL:            https://github.com/nomandhoni-cs/blink-eye

%description
Blink Eye is a minimalist eye care reminder app designed to reduce eye strain during extended screen usage. It provides customization timers, full-screen popups, audio mute functionality for a seamless user experience.

%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT/%{_bindir}
cp dist/%{name} $RPM_BUILD_ROOT/%{_bindir}

%clean
rm -rf $RPM_BUILD_ROOT

%files
%{_bindir}/%{name}
%license LICENSE.txt

%changelog
* Mon Apr 01 2024 Moheshwar Amarnath Biswas
- First Linux Version

and build_fedora.sh to this:

#!/usr/bin/env bash

ver="1.4.0"

echo Installing Dependencies...
sudo dnf install -y rpmdevtools rpmlint python3-devel python3-pip python3-tkinter
pip install wheel
pip install -r REQUIREMENTS.txt
pip install pyinstaller
echo Building the executable...
pyinstaller --name BlinkEye --onefile --windowed --add-data="./Assets/*:./Assets" --hidden-import plyer.platforms.linux.notification --clean blink_eye.py
echo Building the installer...
rpmdev-setuptree
cp -r ./* ~/rpmbuild/BUILD
cp ../LICENSE.txt ~/rpmbuild/BUILD/LICENSE.txt
rpmbuild -bb ./BlinkEye_Fedora.spec
rm -rf ~/rpmbuild/BUILD
mkdir -p ./ExecutableFile/
mv ~/rpmbuild/RPMS/x86_64/BlinkEye-$ver-1.fc39.x86_64.rpm ./ExecutableFile/BlinkEye-$ver-1.fc39.x86_64.rpm

and you're good to go.

@Nusab19
Copy link
Author

Nusab19 commented Apr 3, 2024

Done

Copy link
Contributor

@fluentmoheshwar fluentmoheshwar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants