Comments (9)
I'd prefer to see us use subcommands or parameters, rather than making that assumption.
from dnfdragora.
(Note, Yumex-DNF code for this)
from dnfdragora.
The reason I suggest accepting the files on the command line directly, with no other parameter, is that that allows having the normal dnfdragora.desktop
claim the RPM MIME type. You may want to add a %F
to the Exec= line (which is ignored if you run it from the menu), but IIRC that is the default anyway.
If you require a special parameter in front of the files, you need a separate dnfdragora-localinstall.desktop
to handle the MIME type.
from dnfdragora.
In that case, we might want to support that mode as well. The switches would be necessary for supporting modes other than install (such as forcing upgrade or doing removal). For symmetry, I'd keep an --install
switch, too.
from dnfdragora.
It should be fixed now, do you think it is needed also for removing? Because i can see a package selection with the intent to install it by clicking or double clicking on it... but does removal make sense?
from dnfdragora.
The .desktop
file part is still missing though. And as I explained in my previous comment, implementing that part would be easier if the code took RPM files to install directly, without an --install
switch (as, e.g., Apper is doing), because then you could just have the normal dnfdragora.desktop
accept RPMs. That is not possible if the switch is required, because if you try to run a .desktop
file with Exec=dnfdragora --install %F
from the menu, it will only ignore the %F
and try to run dnfdragora --install
, which will of course fail. So, in that case, you need a separate .desktop
file.
Apper's command line works the way I am suggesting:
Usage: apper [options] [package]
Apper is an application to get and manage software
Options:
-v, --version Displays version information.
-h, --help Displays this help.
--updates Show updates
--settings Show settings
--backend-details Show backend details
--type <mime-type> Mime type installer
--name <name> Package name installer
--file <file> Single file installer
--resource <lang> Font resource installer
--catalog <file> Catalog installer
--author Show author information.
--license Show license information.
--desktopfile <file name> The base file name of the desktop entry for this
application.
Arguments:
[package] Package file to install
but interestingly, package installation is done by a separate org.kde.apper_installer.desktop
for some reason that is not clear to me.
Yumex-DNF does things your way:
usage: app [-h] [-d] [-y] [--exit] [-I PACKAGE] [-R PACKAGE] [--updateall]
optional arguments:
-h, --help show this help message and exit
-d, --debug
-y, --yes Answer yes/ok to all questions
--exit tell dnfdaemon dbus services used by yumex to exit
-I PACKAGE, --install PACKAGE
Install Package
-R PACKAGE, --remove PACKAGE
Remove Package
--updateall apply all available updates
and includes a dedicated yumex-dnf-local.desktop
to support installation of local RPMs.
Either of the 2 solutions should be implemented:
- add a
dnfdragora-local.desktop
modeled afteryumex-dnf-local.desktop
, or - accept RPMs on the command line without a switch and adjust
dnfdragora.desktop
to claim the MIME type.
Either way, there should be a .desktop
file with
MimeType=application/x-rpm;application/x-redhat-package-manager;
(and the Exec=
line should end in %F
).
from dnfdragora.
Yes you are right, i will add a desktop file for it asap, but we need to add also localization for them, maybe later.
from dnfdragora.
@anaselli I've already got a desktop file to commit. I'll adjust everything to install one. :)
from dnfdragora.
Should be fixed by a934d59 now.
from dnfdragora.
Related Issues (20)
- Clicking to the right of a checkbox sets a remove flag even if the package isn't installed. HOT 1
- Dnfdragora require changes for latest libyui stack
- dnf Dragora constantly crashes, does not even work in wayland. HOT 2
- dnf dragora 2.1.2 won't maximize on gnome wayland on fedora 36 HOT 14
- dnfdragora 2.1.2 starts the app window with 0 width HOT 9
- Dnfdragora backend's (dnfdeamon) ignores DNF's variables HOT 3
- Fedora: dnfdragora doesn't respect /etc/dnf/vars HOT 3
- Feature Request: Clicking on Update Notification should open main GUI HOT 4
- dfndagora hang when search criterion is empty HOT 1
- feature request: add option to save column width ...
- Prepare for DNF 5 HOT 14
- dnfdragora opening as a line. HOT 8
- The app is squashed when is opened HOT 8
- 'Update information' crash dnfdragora HOT 4
- Create an rpm package from dnfdragora sources ? HOT 1
- Broken Matrix room link in README HOT 1
- Updates are available, but the updates list is empty HOT 4
- Statistics in dnfdragora
- dnfdragora-updater Won't start F40 Plasma 6 rc-1 HOT 4
- Dnfdragora doesn't finish the job sometimes recently HOT 12
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dnfdragora.