You are not logged in.

#1 2010-10-26 09:39:06

adamlogan
Member
Registered: 2010-01-29
Posts: 38

[solved] creating menu entry for handbrake in openbox

I'm lacking in basic linux skills. Am trying to get handbrake to launch from the openbox menu. Am editing the ~.config/openbox/menu.xml file manually. I'm trying to figure out how to launch handbrake. Just executing "handbrake" does nothing, so I'm not sure what the full path is to the executable. Pacman -Qs handbrake outputs "local/handbrake". I am trying to use the find command to figure it out but I just do not know how to use it right. Handbrake does not seem to follow the usual executable-gtk extension. Does pacman install software into different directories based on the repository the package was retrieved from?

find / -executable -name "handbrake*"
find / -executable -exec ls -l {} \; | grep "handbrake"
ls -R | grep -iname "handbrake"

Also I don't like how find outputs every searched directory. I just want to see matching results. How do I do that? I know my attempts at find must be absolutely hideous =/. Talk about fail.

Last edited by adamlogan (2010-10-28 01:44:11)

Offline

#2 2010-10-26 09:49:00

bernarcher
Forum Fellow
From: Germany
Registered: 2009-02-17
Posts: 2,281

Re: [solved] creating menu entry for handbrake in openbox

To find out which executables a package installed, try something like "pacman -Ql <package> | grep bin".

Furthermore do reguarly run "updatedb" (as root) which allows to quickly find any file with the "locate" command by searching the database built by updatedb. Best run updatedb immediately after installing a new package so the database will be kept in synch. (See "man updatedb" and "man locate" for more detail.)

Last edited by bernarcher (2010-10-26 09:49:47)


To know or not to know ...
... the questions remain forever.

Offline

#3 2010-10-26 11:20:15

jocom
Member
Registered: 2009-04-29
Posts: 74

Re: [solved] creating menu entry for handbrake in openbox

You can find the location of any command or shellscript by typing

which yourcommand

The entry for your menu should look something like:

<?xml version="1.0" encoding="utf-8"?>
<openbox_menu xmlns="http://openbox.org/3.4/menu">
    <menu id="root-menu" label="Openbox 3">
        ...
        <item label="Handbrake">
            <action name="Execute">
                <execute>
                    handbrake
                </execute>
            </action>
        </item>
        ...
    </menu>
</openbox_menu>

Hope this works smile

Offline

#4 2010-10-26 13:03:33

adamlogan
Member
Registered: 2010-01-29
Posts: 38

Re: [solved] creating menu entry for handbrake in openbox

@ bernarcher
pacman -ql | grep "bin"
I'm not going to wade through all that output o_O

pacman -ql | grep "handbrake"
gave me
handbrake /usr/
handbrake /usr/bin/
handbrake /usr/bin/ghb
handbrake /usr/share/
handbrake /usr/share/applications/
handbrake /usr/share/applications/ghb.desktop
handbrake /usr/share/icons/
handbrake /usr/share/icons/hicolor/
handbrake /usr/share/icons/hicolor/128x128/
handbrake /usr/share/icons/hicolor/128x128/apps/
handbrake /usr/share/icons/hicolor/128x128/apps/hb-icon.png
handbrake-cli /usr/
handbrake-cli /usr/bin/
handbrake-cli /usr/bin/HandBrakeCLI

I don't get it. Terminal auto/tab completion does not complete handbrake in any of the /bin/ directories. Even handbrake-cli won't complete or execute. The updatedb returns a command not found error. Apropos does not come up with anything related to that updatedb command nor does a pacman -Ss updatedb. Scratching my head wth. Maybe my search path is screwy or something.. But;

echo $PATH
returns
/bin:/usr/bin:/sbin:/usr/sbin:/usr/lib/perl5/core_perl/bin

@jocom
Tried out the which command for both handbrake and handbrake-cli both of which are installed according to pacman. Both returned that it was not found in the same paths as mentioned just now from echo $PATH. Your example is exactly how I did mine. It's not the entry, i have been trying to execute handbrake from cli without success. Am using xterm if that's any help.

I can't believe this still eludes me.

Edit: Something just occured to me. A few days ago I installed e17 desktop environment out of curiosity and tried it. Maybe that changed something? Just did pacman -Rs to remove it. Openbox is simpler/easier imo. Anyways idk what to do next.

Last edited by adamlogan (2010-10-26 13:08:02)

Offline

#5 2010-10-26 13:19:02

skunktrader
Member
From: Brisbane, Australia
Registered: 2010-02-14
Posts: 1,538

Re: [solved] creating menu entry for handbrake in openbox

adamlogan wrote:

pacman -ql | grep "bin"
I'm not going to wade through all that output o_O

Try

pacman -Ql handbrake | grep "bin"

The executable is called ghb

Last edited by skunktrader (2010-10-26 13:20:45)

Offline

#6 2010-10-26 13:37:38

adamlogan
Member
Registered: 2010-01-29
Posts: 38

Re: [solved] creating menu entry for handbrake in openbox

@ all
I wasn't thinking straight. Thank you.

Last edited by adamlogan (2010-10-26 13:40:02)

Offline

Board footer

Powered by FluxBB