You are not logged in.

#176 2010-04-08 23:58:21

JohannesSM64
Member
From: Norway
Registered: 2009-10-11
Posts: 623
Website

Re: Ranger, a textbased filemanager

The first file does indeed get copied. It fails when trying to chmod(), and then quits the operation.

Traceback (most recent call last):
  File "/usr/bin/ranger", line 54, in <module>
    main()
  File "/usr/share/ranger/ranger/__main__.py", line 123, in main
    my_fm.loop()
  File "/usr/share/ranger/ranger/core/fm.py", line 133, in loop
    loader.work()
  File "/usr/share/ranger/ranger/fsobject/loader.py", line 123, in work
    self.fm.notify(err)
  File "/usr/share/ranger/ranger/fsobject/loader.py", line 118, in work
    next(item.load_generator)
  File "/usr/share/ranger/ranger/core/actions.py", line 576, in generate
    overwrite=overwrite):
  File "/usr/share/ranger/ranger/ext/shutil_generatorized.py", line 130, in copy2
    copystat(src, dst)
  File "/usr/share/ranger/ranger/ext/shutil_generatorized.py", line 95, in copystat
    os.chmod(dst, mode)
OSError: [Errno 1] Operation not permitted: '/media/KINGSTON/DDDSKIP0STAR4.m64'

Which makes sense since FAT32 doesn't support ext* permissons. But cp doesn't have this issue, and instead drops the permissions.

Last edited by JohannesSM64 (2010-04-09 00:01:14)

Offline

#177 2010-04-09 00:04:03

hut
Member
From: Hanover, Germany
Registered: 2010-03-12
Posts: 561
Website

Re: Ranger, a textbased filemanager

Heh. I guess that error can be silently ignored. Thanks for reporting.

EDIT:
I think I fixed it, can you confirm it please?

EDIT2:
Confirmed.

Last edited by hut (2010-04-09 01:03:53)


"hut_" or "h00th00t" in irc.freenode.net #archlinux
Ranger Mailing List: https://lists.nongnu.org/mailman/listinfo/ranger-users

Offline

#178 2010-04-09 08:32:17

JackH79
Member
From: Australia
Registered: 2009-06-18
Posts: 663
Website

Re: Ranger, a textbased filemanager

Simply awesome!
Been running ranger for a few days now and loving it. At first I thought: "Hmm, nice. Looks like a nice contender to vifm." Now I think: "Hmm, nice. Vifm: looks like a nice contender to ranger." --- if you get my drift.
Everything's just so usable, with hardly any setup fiddeling. Not even missing the double panes any more. Tabs can handle that quite nicely.

However, I have one question:

I still have to use openoffice for compatibility reasons, but am running a dark GTK theme. Usually I open office documents with:

env GTK2_RC_FILES=/usr/share/themes/Clearlooks/gtk-2.0/gtkrc soffice -writer

to get a light theme for that app.

Now, I put these lines into apps.py.

...
if f.extension in ('odt', 'doc'):
return self.app_soffice(c)

...

@depends_on('soffice')
def app_soffice(self,c):
return tup("env GTK2_RC_FILES=/usr/share/themes/Clearlooks/gtk-2.0/gtkrc soffice -writer", *c)

but I only get an error message, saying: "Failed to open blah-blah-blah "
When I leave out the "env GTK2_RC_FILES... " stuff, it works fine. But due to openoffice's inability to handle dark themes, it's rather useless. Is there a way to get it to work?
Could well be I'm doing something wrong as I have no clue about python.

Thanks in advance. Oh, and thanks a bunch for this great app, hut!
Jack

Offline

#179 2010-04-09 11:33:46

hut
Member
From: Hanover, Germany
Registered: 2010-03-12
Posts: 561
Website

Re: Ranger, a textbased filemanager

Each argument has to be a single string in the tuple.
So, to run "soffice -writer" you'd have to write tup("soffice", "-writer", *c)
Note the ", " in between.
Apply this to your command, and you get:
return tup("env", "GTK2_RC_FILES=/usr/share/themes/Clearlooks/gtk-2.0/gtkrc", "soffice", "-writer", *c)

If this doesn't work, try:
os.environ["GTK2_RC_FILES"] = "/usr/share/themes/Clearlooks/gtk-2.0/gtkrc"
return tup("soffice", "-writer", *c)


Edit:
Oh, and you should add this before the return-line:
c.flags += 'd'
so the process will run detached and ranger is not locked out.

Last edited by hut (2010-04-09 12:50:03)


"hut_" or "h00th00t" in irc.freenode.net #archlinux
Ranger Mailing List: https://lists.nongnu.org/mailman/listinfo/ranger-users

Offline

#180 2010-04-10 10:29:01

litemotiv
Forum Fellow
Registered: 2008-08-01
Posts: 5,026

Re: Ranger, a textbased filemanager

small bug, when renaming files with a space in the name, the complete name gets appended. example:

[PW 05] ABCD

:rename [PW <tab> 

:rename [PW [PW 05] ABCD

ᶘ ᵒᴥᵒᶅ

Offline

#181 2010-04-11 02:20:37

corsakh
Member
Registered: 2009-11-08
Posts: 104

Re: Ranger, a textbased filemanager

Just wanted to say that I installed ranger under the latest kdemod. Used for a little then forgot about it for a few days. Once opened system monitor and found 100% load on cpu1, everything coming from ranger. Promptly uninstalled, everything back to normal. Not sure what the cause was, I did multiple log outs and probably a reboot during those two days.

Offline

#182 2010-04-11 09:42:50

hut
Member
From: Hanover, Germany
Registered: 2010-03-12
Posts: 561
Website

Re: Ranger, a textbased filemanager

corsakh wrote:

Just wanted to say that I installed ranger under the latest kdemod. Used for a little then forgot about it for a few days. Once opened system monitor and found 100% load on cpu1, everything coming from ranger. Promptly uninstalled, everything back to normal. Not sure what the cause was, I did multiple log outs and probably a reboot during those two days.

It would be great if you could try to reproduce that behaviour and tell me how it happened.


"hut_" or "h00th00t" in irc.freenode.net #archlinux
Ranger Mailing List: https://lists.nongnu.org/mailman/listinfo/ranger-users

Offline

#183 2010-04-11 11:09:46

litemotiv
Forum Fellow
Registered: 2008-08-01
Posts: 5,026

Re: Ranger, a textbased filemanager

i have a feeling that ranger is doing a bit much (unneeded) i/o when walking the file tree. i have a NAS for instance for which i disable file/dir sizes and preview column in ranger, then when i enter a directory with about 10 subdirectories (all containing many more subdirs), it takes about 3-4 seconds to load the initial view (lots of rattling in the background). when i compare this with pcmanfm, the latter takes about 1 second, producing little audible sound. the produced output on screen for both programs is comparable, so perhaps ranger is indexing information that isn't actually needed for display?

small other thing: not sure what happened, but this is when i switched tab from one remote location to another:

  File "/usr/bin/ranger", line 54, in <module>
    main()
  File "/usr/share/ranger/ranger/__main__.py", line 123, in main
    my_fm.loop()
  File "/usr/share/ranger/ranger/core/fm.py", line 140, in loop
    ui.redraw()
  File "/usr/share/ranger/ranger/gui/ui.py", line 184, in redraw
    self.draw()
  File "/usr/share/ranger/ranger/gui/ui.py", line 205, in draw
    DisplayableContainer.draw(self)
  File "/usr/share/ranger/ranger/gui/displayable.py", line 270, in draw
    displayable.draw()
  File "/usr/share/ranger/ranger/gui/widgets/statusbar.py", line 104, in draw
    self._calc_bar()
  File "/usr/share/ranger/ranger/gui/widgets/statusbar.py", line 110, in _calc_bar
    self._get_right_part(bar)
  File "/usr/share/ranger/ranger/gui/widgets/statusbar.py", line 215, in _get_right_part
    max_pos = len(target) - self.column.hei
  File "/usr/share/ranger/ranger/fsobject/directory.py", line 406, in __len__
    return len(self.files)
TypeError: object of type 'NoneType' has no len()

(happened only once so far)


ᶘ ᵒᴥᵒᶅ

Offline

#184 2010-04-11 11:20:12

hut
Member
From: Hanover, Germany
Registered: 2010-03-12
Posts: 561
Website

Re: Ranger, a textbased filemanager

litemotiv wrote:

i have a feeling that ranger is doing a bit much (unneeded) i/o when walking the file tree. i have a NAS for instance for which i disable file/dir sizes and preview column in ranger, then when i enter a directory with about 10 subdirectories (all containing many more subdirs), it takes about 3-4 seconds to load the initial view (lots of rattling in the background). when i compare this with pcmanfm, the latter takes about 1 second, producing little audible sound. the produced output on screen for both programs is comparable, so perhaps ranger is indexing information that isn't actually needed for display?

Yesh, ranger is doing unnecessary IO sometimes. I'll start to optimize things after I'm done with the key parser and a few other things.

litemotiv wrote:

small other thing: not sure what happened, but this is when i switched tab from one remote location to another:

  File "/usr/bin/ranger", line 54, in <module>
    main()
  File "/usr/share/ranger/ranger/__main__.py", line 123, in main
    my_fm.loop()
  File "/usr/share/ranger/ranger/core/fm.py", line 140, in loop
    ui.redraw()
  File "/usr/share/ranger/ranger/gui/ui.py", line 184, in redraw
    self.draw()
  File "/usr/share/ranger/ranger/gui/ui.py", line 205, in draw
    DisplayableContainer.draw(self)
  File "/usr/share/ranger/ranger/gui/displayable.py", line 270, in draw
    displayable.draw()
  File "/usr/share/ranger/ranger/gui/widgets/statusbar.py", line 104, in draw
    self._calc_bar()
  File "/usr/share/ranger/ranger/gui/widgets/statusbar.py", line 110, in _calc_bar
    self._get_right_part(bar)
  File "/usr/share/ranger/ranger/gui/widgets/statusbar.py", line 215, in _get_right_part
    max_pos = len(target) - self.column.hei
  File "/usr/share/ranger/ranger/fsobject/directory.py", line 406, in __len__
    return len(self.files)
TypeError: object of type 'NoneType' has no len()

(happened only once so far)

I'm aware of that problem. Its most likely a flaw in my garbage collection method, gonna fix that soon


Edit:

litemotiv wrote:

small bug, when renaming files with a space in the name, the complete name gets appended.

fixed

Last edited by hut (2010-04-11 20:33:23)


"hut_" or "h00th00t" in irc.freenode.net #archlinux
Ranger Mailing List: https://lists.nongnu.org/mailman/listinfo/ranger-users

Offline

#185 2010-04-12 00:34:58

JackH79
Member
From: Australia
Registered: 2009-06-18
Posts: 663
Website

Re: Ranger, a textbased filemanager

Thanks very much for your reply, hut.

I had tried this one before, but it doesn't work:

hut wrote:

return tup("env", "GTK2_RC_FILES=/usr/share/themes/Clearlooks/gtk-2.0/gtkrc", "soffice", "-writer", *c)

This one however works swell:

hut wrote:

os.environ["GTK2_RC_FILES"] = "/usr/share/themes/Clearlooks/gtk-2.0/gtkrc"
return tup("soffice", "-writer", *c)

Thanks very much!!!

Now it's just PERFECT.

Cheers
Jack

Offline

#186 2010-04-12 01:02:16

yvonney
Member
Registered: 2008-06-11
Posts: 671

Re: Ranger, a textbased filemanager

My incredulity here for how nicely vifm and mc uninstalled a few days back.
(my 'day one' with Ranger I recall)
With great respect to them of course.
Ranger just suits me. And learning/applying the tabs feature will be great fun!

Last edited by yvonney (2010-04-12 01:38:41)

Offline

#187 2010-04-12 16:43:30

hut
Member
From: Hanover, Germany
Registered: 2010-03-12
Posts: 561
Website

Re: Ranger, a textbased filemanager

Thanks.

And guys, I'm working on that key parser so I want to make it clear that upcoming changes will make old key configuration files incompatible.
This is the prototype for the new keyboard configuration file:
http://git.savannah.gnu.org/cgit/ranger … y?h=newkey

Though it's not final yet. Subscribe to the mailing list, throw in suggestions.

The first thing is, should I change the notation for Alt keys from <A-key> to <M-key>?
Edit: Nevermind, vim uses <A-key>, so I'll stick with that

Last edited by hut (2010-04-12 16:57:25)


"hut_" or "h00th00t" in irc.freenode.net #archlinux
Ranger Mailing List: https://lists.nongnu.org/mailman/listinfo/ranger-users

Offline

#188 2010-04-12 18:40:34

Sirsurthur
Member
Registered: 2009-02-02
Posts: 114

Re: Ranger, a textbased filemanager

Traceback (most recent call last):
  File "/usr/bin/ranger", line 54, in <module>
    main()
  File "/usr/share/ranger/ranger/__main__.py", line 122, in main
    my_ui.initialize()
  File "/usr/share/ranger/ranger/gui/ui.py", line 90, in initialize
    self.setup()
  File "/usr/share/ranger/ranger/gui/defaultui.py", line 23, in setup
    from ranger.gui.widgets.console import Console
  File "/usr/share/ranger/ranger/gui/widgets/console.py", line 31, in <module>
    from ranger.ext.direction import Direction
ImportError: No module named direction
--------------------------------------------------------------------------------------------
I got a little bug since last git update ! Hope it helps.

Offline

#189 2010-04-12 18:46:31

yvonney
Member
Registered: 2008-06-11
Posts: 671

Re: Ranger, a textbased filemanager

Hi, sometimes 2 or 3 times a day I do a makepkg in my ranger-git folder. Today I messed something up after the make.
There seemed to be lots of changes when RANGER was building.
Found it interesting as usual. Also, interested in getting RANGER running again so puzzling on what I did, or what I can do. :)
Took a look at the new configuration file and the key command. great!

Traceback (most recent call last):
  File "/usr/bin/ranger", line 54, in <module>
    main()
  File "/usr/share/ranger/ranger/__main__.py", line 122, in main
    my_ui.initialize()
  File "/usr/share/ranger/ranger/gui/ui.py", line 90, in initialize
    self.setup()
  File "/usr/share/ranger/ranger/gui/defaultui.py", line 23, in setup
    from ranger.gui.widgets.console import Console
  File "/usr/share/ranger/ranger/gui/widgets/console.py", line 31, in <module>
    from ranger.ext.direction import Direction
ImportError: No module named direction

Last edited by yvonney (2010-04-12 18:47:29)

Offline

#190 2010-04-12 18:50:52

hut
Member
From: Hanover, Germany
Registered: 2010-03-12
Posts: 561
Website

Re: Ranger, a textbased filemanager

It's fixed, sorry^^.

(I'm working on multiple branches and something got mixed up)

Last edited by hut (2010-04-12 18:52:34)


"hut_" or "h00th00t" in irc.freenode.net #archlinux
Ranger Mailing List: https://lists.nongnu.org/mailman/listinfo/ranger-users

Offline

#191 2010-04-12 18:50:57

yvonney
Member
Registered: 2008-06-11
Posts: 671

Re: Ranger, a textbased filemanager

SOLVED: I did redownload the AUR files though my solution was probably just deleting the folders in the ranger-git build folder and starting fresh. GREAT!

EDIT: hehehe, there's a great experience/reminder to stay non-assuming for me again.  Me thinking it was my resolving though it was you. incredibly good to never assume, generally.

Last edited by yvonney (2010-04-12 18:53:27)

Offline

#192 2010-04-14 05:51:19

Sirsurthur
Member
Registered: 2009-02-02
Posts: 114

Re: Ranger, a textbased filemanager

Hello !

Since last update (commit    ab5d63be742a6d6ca10443c12d561b0a1c861474), I get the following error :

Thanks for this great file manager.
----

Traceback (most recent call last):
  File "/usr/bin/ranger", line 54, in <module>
    main()
  File "/usr/share/ranger/ranger/__main__.py", line 76, in main
    from ranger.core.fm import FM
  File "/usr/share/ranger/ranger/core/fm.py", line 27, in <module>
    from ranger.core.actions import Actions
  File "/usr/share/ranger/ranger/core/actions.py", line 24, in <module>
    from ranger.ext.direction import Direction
ImportError: No module named direction

Offline

#193 2010-04-14 09:34:11

hut
Member
From: Hanover, Germany
Registered: 2010-03-12
Posts: 561
Website

Re: Ranger, a textbased filemanager

Again? Argh, sorry. I never realize that because I have the file ranger/ext/direction.pyc which avoids the error but only for me, not for you.

Update again please.


"hut_" or "h00th00t" in irc.freenode.net #archlinux
Ranger Mailing List: https://lists.nongnu.org/mailman/listinfo/ranger-users

Offline

#194 2010-04-14 22:29:46

yvonney
Member
Registered: 2008-06-11
Posts: 671

Re: Ranger, a textbased filemanager

Interested to know if typing 's' and getting a term to open in the same folder RANGER was in has changed.

I use urxvtc and zsh and can imaging that I may have some issue with my dotfiles quite possibly.
As of the latest version it's kinda cool as it opens up a regular prompt right at the bottom of the screen
instead of opening up a term instance in place of the running RANGER, i think.

So, the thing is from this prompt at the bottom of the screen I can't do CTRL-R to get the zsh backwards history search.
Again, um, certainly my system and moreso, me, that's the cause, and I do recall hearing of new commands coming up.
Read the brilliant help files though didn't see any new commands. They are the same I think. That's: '!' or 's'.

Last edited by yvonney (2010-04-14 22:30:23)

Offline

#195 2010-04-14 22:42:15

hut
Member
From: Hanover, Germany
Registered: 2010-03-12
Posts: 561
Website

Re: Ranger, a textbased filemanager

Hi, thanks for the feedback. I'm experimenting a bit:
1. I changed the key for opening a shell from "s" to "S"
2. "s" now does the same as "!": running one shell command
3. the prompt for the "!" and "s" key has changed to a shell-like prompt to make it obvious that you're about to use a shell command

Some people have already been complaining =P. I might change it back to the way it was, or at least change the prompt to "$" to not confuse the user into thinking that an actual shell instance has been started.

And of course the documentation has to be updated >_< thanks

Last edited by hut (2010-04-14 22:44:41)


"hut_" or "h00th00t" in irc.freenode.net #archlinux
Ranger Mailing List: https://lists.nongnu.org/mailman/listinfo/ranger-users

Offline

#196 2010-04-15 06:34:08

yvonney
Member
Registered: 2008-06-11
Posts: 671

Re: Ranger, a textbased filemanager

It just ALL so great 'hut' ... appreciate the clarification. Myself, don't mind what key's what. Whatever you and the gurus who comment wish will
be perfect. You, and the helpful bunch have filled a HUGE gap in productivity, understanding and plain enjoyment. um, as mentioned previously.
I am absolutely looking forward to learning more about RANGER and cli generally. [no reply need to this late night 'woohoo', of course]

Last edited by yvonney (2010-04-15 06:34:54)

Offline

#197 2010-04-15 07:23:47

lymphatik
Member
From: Somewhere else
Registered: 2009-03-07
Posts: 119

Re: Ranger, a textbased filemanager

Hi.

I do not know if it's the right time to ask for some new feature in your development process. But could you add a way to cycle through folders and files list.

Let me explain, for example if you have a list of files, you can only go down when you are at the top of the list with j or the direction pad. But it would be nice to go directly at the bottom by using k or up on the direction pad when you are at the top of the list. I do not know if it is a lot of work otherwise I will just use shift+g

Thanks

Last edited by lymphatik (2010-04-15 11:02:10)

Offline

#198 2010-04-15 08:13:46

litemotiv
Forum Fellow
Registered: 2008-08-01
Posts: 5,026

Re: Ranger, a textbased filemanager

lymphatik: press 1? for the basic movement keys


ᶘ ᵒᴥᵒᶅ

Offline

#199 2010-04-15 11:06:15

lymphatik
Member
From: Somewhere else
Registered: 2009-03-07
Posts: 119

Re: Ranger, a textbased filemanager

litemotiv I already know that you can go at the bottom with shift+g

But when you enter a folder with a list of files it is quite convenient to just press 'up' or 'k' and cycle to the bottom of the list, like it is already done in zsh.

Offline

#200 2010-04-15 12:25:30

litemotiv
Forum Fellow
Registered: 2008-08-01
Posts: 5,026

Re: Ranger, a textbased filemanager

lymphatik wrote:

litemotiv I already know that you can go at the bottom with shift+g

But when you enter a folder with a list of files it is quite convenient to just press 'up' or 'k' and cycle to the bottom of the list, like it is already done in zsh.

oh is that what you mean, sorry i didn't catch that. i would personally not really like that feature, sometimes i mistype j/k when i enter a folder and then i would end up on the bottom of the list. bit too confusing for me..


ᶘ ᵒᴥᵒᶅ

Offline

Board footer

Powered by FluxBB