After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 583637 - Change command line interface to be more compatible with .desktop files
Change command line interface to be more compatible with .desktop files
Status: RESOLVED FIXED
Product: pitivi
Classification: Other
Component: General
0.13.1
Other Mac OS
: Normal blocker
: 0.13.2
Assigned To: Alessandro Decina
Pitivi maintainers
Depends on:
Blocks:
 
 
Reported: 2009-05-23 12:45 UTC by Alessandro Decina
Modified: 2009-07-24 15:38 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
proposed change (4.24 KB, patch)
2009-05-23 13:17 UTC, Alessandro Decina
none Details | Review

Description Alessandro Decina 2009-05-23 12:45:19 UTC
This is what our command line interface looks like right now:

Usage: pitivi [-p PROJECT_FILE] [-a] [MEDIA_FILE]...

Starts the video editor, optionally loading PROJECT_FILE. If no project is
given, pitivi creates a new project. Remaining arguments are treated as clips
to be imported into the project. If -a is specified, these clips will also be
added to the end of the project timeline.

Options:
  -h, --help            show this help message and exit
  -a, --add-to-timeline
                        Add each MEDIA_FILE to timeline after importing.


This means that to associate .xptv files with pitivi, we have to put "Exec=pitivi -p %f" in the .desktop file. Unfortunately, if we do that, then it's not possible to launch pitivi from the GNOME menu, as that would be like calling "pitivi -p" (without an argument to -p).

To solve this, we could change the command line to:

Usage: pitivi -i [-a] [MEDIA_FILE]...
       pitivi [PROJECT_FILE]

Starts the video editor, optionally loading PROJECT_FILE. If no project is
given, pitivi creates a new project.

Alternatively, when the -i option is used, command line arguments are treated as clips to be imported into the project. If -a is specified, these clips will also be added to the end of the project timeline.

Options:
  -h, --help            show this help message and exit
  -i, --import          Import each MEDIA_FILE in the project.
  -a, --add-to-timeline
                        Add each MEDIA_FILE to timeline after importing.

This way we could simply have "Exec=pitivi %f" in the .desktop file.
Comment 1 Alessandro Decina 2009-05-23 13:06:45 UTC
Mmmh this would break string freeze though.
Comment 2 Edward Hervey 2009-05-23 13:16:52 UTC
Event though this is a string freeze break... we need it in.
Comment 3 Alessandro Decina 2009-05-23 13:17:37 UTC
Created attachment 135233 [details] [review]
proposed change