You are not logged in.

#51 2010-05-09 02:01:02

lucke
Member
From: Poland
Registered: 2004-11-30
Posts: 4,018

Re: ObFilebrowser - a pipe-menu file browser for Openbox

obfilebrowser doesn't like apostrophes in the names, it seems.

Offline

#52 2010-05-10 11:42:06

Xyne
Administrator/PM
Registered: 2008-08-03
Posts: 6,963
Website

Re: ObFilebrowser - a pipe-menu file browser for Openbox

lucke wrote:

obfilebrowser doesn't like apostrophes in the names, it seems.

You don't like to be very specific, it seems. hmm

I just checked with

touch "don't"

and ObFilebrowser displayed it as expected. What did you do, what happened, and what did you expect to happen?

Last edited by Xyne (2010-05-10 11:42:28)


My Arch Linux StuffForum EtiquetteCommunity Ethos - Arch is not for everyone

Offline

#53 2010-05-10 15:09:37

lucke
Member
From: Poland
Registered: 2004-11-30
Posts: 4,018

Re: ObFilebrowser - a pipe-menu file browser for Openbox

Try "mkdir "don't"". Files with the apostrophe in the name seem to work indeed, directories don't work for me. It seems.

Last edited by lucke (2010-05-10 15:51:07)

Offline

#54 2010-05-10 18:27:13

Xyne
Administrator/PM
Registered: 2008-08-03
Posts: 6,963
Website

Re: ObFilebrowser - a pipe-menu file browser for Openbox

It naïvely quoted all directories with single quotes, whence the breakage. It should be fixed now.

Thanks for letting me know.


My Arch Linux StuffForum EtiquetteCommunity Ethos - Arch is not for everyone

Offline

#55 2010-05-17 21:13:33

Dirk Sohler
Member
From: Hamburg, Germany
Registered: 2009-10-03
Posts: 109

Re: ObFilebrowser - a pipe-menu file browser for Openbox

lucke wrote:

obfilebrowser doesn't like apostrophes in the names, it seems.

obrowse works with apostrophes in file or folder names very well.

Offline

#56 2010-05-18 00:20:46

Xyne
Administrator/PM
Registered: 2008-08-03
Posts: 6,963
Website

Re: ObFilebrowser - a pipe-menu file browser for Openbox

Dirk Sohler wrote:
lucke wrote:

obfilebrowser doesn't like apostrophes in the names, it seems.

obrowse works with apostrophes in file or folder names very well.

Ok, three times is enough now. It's rude to repeatedly spam a contribution thread to advertise your own alternative. Furthermore your last point is invalid because the problem has already been addressed.

Please stop posting in this thread.


My Arch Linux StuffForum EtiquetteCommunity Ethos - Arch is not for everyone

Offline

#57 2010-10-16 09:16:02

daneel971
Member
Registered: 2008-03-28
Posts: 197

Re: ObFilebrowser - a pipe-menu file browser for Openbox

I share my home directory between a 32bit and a 64bit arch installation - when using

obfilebrowser ~

in the 64bit env, i get

error: invalid executable wine

It' possible to ignore the error and output the usual menu anyway?

Offline

#58 2010-10-16 11:39:52

Xyne
Administrator/PM
Registered: 2008-08-03
Posts: 6,963
Website

Re: ObFilebrowser - a pipe-menu file browser for Openbox

Try obfilebrowser>=2010.10.16.1 and let me know if it works.


My Arch Linux StuffForum EtiquetteCommunity Ethos - Arch is not for everyone

Offline

#59 2010-10-16 14:06:06

daneel971
Member
Registered: 2008-03-28
Posts: 197

Re: ObFilebrowser - a pipe-menu file browser for Openbox

It doesn't work, but the output is:

error: apparently invalid executable wine
Traceback (most recent call last):
  File "/usr/bin/obfilebrowser", line 579, in <module>
    main()
  File "/usr/bin/obfilebrowser", line 573, in main
    getMenu(dpath)
  File "/usr/bin/obfilebrowser", line 360, in getMenu
    menu += getLauncherMenu(f[0], label=f[1])
  File "/usr/bin/obfilebrowser", line 232, in getLauncherMenu
    l = getLauncher( fpath, getDesktop(d) )
  File "/usr/bin/obfilebrowser", line 158, in getLauncher
    command = parse_exec_key(desktop['Exec'], [fpath])[0]
  File "/usr/bin/obfilebrowser", line 483, in parse_exec_key
    cmds.append(quote_command(args))
  File "/usr/bin/obfilebrowser", line 504, in quote_command
    return ' '.join( map(quote, args) )
  File "/usr/lib/python2.6/pipes.py", line 271, in quote
    for c in file:
TypeError: 'NoneType' object is not iterable

Offline

#60 2010-10-16 14:14:56

Xyne
Administrator/PM
Registered: 2008-08-03
Posts: 6,963
Website

Re: ObFilebrowser - a pipe-menu file browser for Openbox

Try obfilebrowser 2010.10.16.2


My Arch Linux StuffForum EtiquetteCommunity Ethos - Arch is not for everyone

Offline

#61 2010-10-16 19:53:15

daneel971
Member
Registered: 2008-03-28
Posts: 197

Re: ObFilebrowser - a pipe-menu file browser for Openbox

with 2010.10.16.2 I get

error: apparently invalid executable wine
Traceback (most recent call last):
  File "/usr/bin/obfilebrowser", line 581, in <module>
    main()
  File "/usr/bin/obfilebrowser", line 575, in main
    getMenu(dpath)
  File "/usr/bin/obfilebrowser", line 360, in getMenu
    menu += getLauncherMenu(f[0], label=f[1])
  File "/usr/bin/obfilebrowser", line 232, in getLauncherMenu
    l = getLauncher( fpath, getDesktop(d) )
  File "/usr/bin/obfilebrowser", line 158, in getLauncher
    command = parse_exec_key(desktop['Exec'], [fpath])[0]
IndexError: list index out of range

Offline

#62 2010-10-17 15:11:00

Xyne
Administrator/PM
Registered: 2008-08-03
Posts: 6,963
Website

Re: ObFilebrowser - a pipe-menu file browser for Openbox

I've uploaded a new version.


My Arch Linux StuffForum EtiquetteCommunity Ethos - Arch is not for everyone

Offline

#63 2010-10-17 15:45:20

daneel971
Member
Registered: 2008-03-28
Posts: 197

Re: ObFilebrowser - a pipe-menu file browser for Openbox

The menu is generated, but before the xml itself obfilebroser outputs a  lot of "error: apparently invalid executable wine" so no pipemenu is created (I saw the output in a terminal)

EDIT: I really appreciate your interest in this smile but I don't absolutely want to drive you crazy...

Last edited by daneel971 (2010-10-17 15:47:08)

Offline

#64 2010-10-17 16:49:31

Xyne
Administrator/PM
Registered: 2008-08-03
Posts: 6,963
Website

Re: ObFilebrowser - a pipe-menu file browser for Openbox

Don't worry, I don't actually mind that much. I should have just taken the time to reproduce it by creating a .desktop file with an invalid Exec field, but I thought the trial & error approach would have been simpler.

I've redirected all warnings to STDERR so they should not interfere with the menus now. That should be it.


My Arch Linux StuffForum EtiquetteCommunity Ethos - Arch is not for everyone

Offline

#65 2010-10-18 13:51:43

daneel971
Member
Registered: 2008-03-28
Posts: 197

Re: ObFilebrowser - a pipe-menu file browser for Openbox

It works perfectly now, thank you.

Offline

#66 2010-12-28 13:57:04

Artaserse
Member
Registered: 2010-04-04
Posts: 19

Re: ObFilebrowser - a pipe-menu file browser for Openbox

@xyne
When i open a folder from this menu with thunar, it opens twice. The same happens when i open a folder with nautilus. There's a way to fix it?

Offline

#67 2010-12-28 16:43:34

Xyne
Administrator/PM
Registered: 2008-08-03
Posts: 6,963
Website

Re: ObFilebrowser - a pipe-menu file browser for Openbox

I've updated obfilebrowser. Try the latest version and let me know if it fixes the problem.


My Arch Linux StuffForum EtiquetteCommunity Ethos - Arch is not for everyone

Offline

#68 2010-12-28 16:58:26

Artaserse
Member
Registered: 2010-04-04
Posts: 19

Re: ObFilebrowser - a pipe-menu file browser for Openbox

Wow! You're really fast!  yikes
The problem is solved now, thank you! smile

Offline

#69 2011-02-02 04:32:50

Xyne
Administrator/PM
Registered: 2008-08-03
Posts: 6,963
Website

Re: ObFilebrowser - a pipe-menu file browser for Openbox

In reply to this post:

memeplex wrote:

It would be nice if obfilebrowser lauched apps having "Terminal=true" in a CLI-configurable terminal emulator.

Update to the latest version and let me know if it works. If not, post the output of

mimeo -a /path/to/file
mimeo -c /path/to/file

Post the desktop file too.



@anyone wondering why Mimeo is now a dependency of ObFilebrowser:
Mimeo was created using the code that I wrote for the launcher menu in ObFilebrowser. Being lazy at the time, I simply copied the code over to Mimeo instead of modularizing it. As Mimeo was updated in response to feedback, I tried to keep ObFilebrowser's corresponding code synchronized with the changes in Mimeo, but the code diverged.

I have finally create a separate class to hold the common code and created a module in the "mimeo" package. That module is now imported by ObFilebrowser.


My Arch Linux StuffForum EtiquetteCommunity Ethos - Arch is not for everyone

Offline

#70 2011-02-02 07:50:44

memeplex
Member
Registered: 2008-11-10
Posts: 33

Re: ObFilebrowser - a pipe-menu file browser for Openbox

Unfortunately it didn't work. Here is the mimeo output:

[carlos@carlos ~]$ mimeo -a work/factor/amicable/amicable.factor 

Traceback (most recent call last):
  File "/usr/bin/mimeo", line 5, in <module>
    Mimeo.main()
  File "/usr/lib/python2.7/site-packages/Mimeo.py", line 524, in main
    sys.stderr.write("error: no path given")
NameError: global name 'sys' is not defined

[carlos@carlos ~]$ mimeo -c work/factor/amicable/amicable.factor 

/bin/sh -c '/usr/bin/vim /home/carlos/work/factor/amicable/amicable.factor'

And here follows the content of my desktop file:

[carlos@carlos ~]$ cat .local/share/applications/vim.desktop 

[Desktop Entry]
Type=Application
Name=vim
Exec=vim %f
NoDisplay=true
Terminal=true

Last edited by memeplex (2011-02-02 07:53:39)

Offline

#71 2011-02-02 13:21:50

Xyne
Administrator/PM
Registered: 2008-08-03
Posts: 6,963
Website

Re: ObFilebrowser - a pipe-menu file browser for Openbox

I've fixed some bugs and added a new option to ObFilebrowser: --term
You can use that to set your terminal, e.g.

obfilebrowser --term 'urxvtc -e %s' /path/to/dir

Update obfilebrowser and mimeo, then edit your openbox menu to include the proper option.


I might make this configurable later via an environment variable or the mimeo configuration file.


My Arch Linux StuffForum EtiquetteCommunity Ethos - Arch is not for everyone

Offline

#72 2011-02-02 13:57:00

memeplex
Member
Registered: 2008-11-10
Posts: 33

Re: ObFilebrowser - a pipe-menu file browser for Openbox

Almost working, but there remain a couple of issues yet:

1) /usr/bin/urxvtc -e '/usr/bin/vim /home/carlos/notes/arch.txt' . The command shouldn't be between quotes. The auto-quoting isn't only unnecessary but it's also a bug.

2) This one is unrelated to the terminal stuff. You read mimeinfo.cache both from XDG_DATA_HOME and XDG_DATA_DIRS. Some applications (like pcmanfm) use XDG_DATA_HOME/mimeapps.list instead of XDG_DATA_HOME/mimeinfo.cache. I'm not an expert here so I'm not sure whether both files should be supported or only mimeapps.list is allowed in the home directory.

Offline

#73 2011-02-02 14:19:44

Xyne
Administrator/PM
Registered: 2008-08-03
Posts: 6,963
Website

Re: ObFilebrowser - a pipe-menu file browser for Openbox

memeplex wrote:

1) /usr/bin/urxvtc -e '/usr/bin/vim /home/carlos/notes/arch.txt' . The command shouldn't be between quotes. The auto-quoting isn't only unnecessary but it's also a bug.

Fixed.


memeplex wrote:

2) This one is unrelated to the terminal stuff. You read mimeinfo.cache both from XDG_DATA_HOME and XDG_DATA_DIRS. Some applications (like pcmanfm) use XDG_DATA_HOME/mimeapps.list instead of XDG_DATA_HOME/mimeinfo.cache. I'm not an expert here so I'm not sure whether both files should be supported or only mimeapps.list is allowed in the home directory.

I don't know either. mimeapps.list has the same format as mimeinfo.cache,  so I've included it in the loader for now. Presumably the user will want all custom associations to be made available. If someone points me to an accepted standard specification then I will update Mimeo to be compliant, but I won't go looking for it myself any time soon.


p.s. Thanks for the feedback.

Last edited by Xyne (2011-02-02 14:20:10)


My Arch Linux StuffForum EtiquetteCommunity Ethos - Arch is not for everyone

Offline

#74 2011-02-02 14:32:24

memeplex
Member
Registered: 2008-11-10
Posts: 33

Re: ObFilebrowser - a pipe-menu file browser for Openbox

Works like a charm now! I notice that, now that both mimeinfo.cache and mimeapps.list are loaded, some duplicate entries appear between the launchers, say [ gvim, vim, vim]. I could just remove one of the files (indeed I've both just in case) but maybe a duplicate removal phase can be added at the end of load_mime_cache.

p.s. Thank you for your work.

Offline

#75 2011-02-02 14:55:07

Xyne
Administrator/PM
Registered: 2008-08-03
Posts: 6,963
Website

Re: ObFilebrowser - a pipe-menu file browser for Openbox

load_mime_cache should now avoid duplicates


My Arch Linux StuffForum EtiquetteCommunity Ethos - Arch is not for everyone

Offline

Board footer

Powered by FluxBB