You are not logged in.

#1151 2011-10-19 22:03:10

anon27
Member
Registered: 2010-11-10
Posts: 18

Re: Ranger, a textbased filemanager

anon27 wrote:

I'm unable to type numbers into the console with the latest version. They get displayed in the top right corner of the screen instead. Any idea what could be wrong?

If anyone has the same problem you need to add "cmap <allow_quantifiers> false" to your rc.conf.

Offline

#1152 2011-10-21 11:01:37

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

Re: Ranger, a textbased filemanager

igndenok wrote:

hut, I notice that I can't use auto completion when using shell (console shell, when you press s). Is this removed by default or there is a way to enable it ?

Fixed this. You will need to update commands.py if you used --copy-config=commands before.

satvikc wrote:

Is there any thing similar to autojump  in ranger

No, but we need it! Someone code it please :3


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

Offline

#1153 2011-10-22 03:08:44

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

Re: Ranger, a textbased filemanager

hut wrote:
sant527 wrote:

Also I want ranger to show the size of the directories ( not the number of files) but the size in MB or GB. And I want to sort  as per this size.

That is currently not supported

It is supported now. Select your files (with space or v) and type "dc" to calculate cumulative sizes for them.
You can then sort by size with "os".

Since the operation is expensive, the sizes are not updated automatically, but you can turn this on by enabling the option "autoupdate_cumulative_size" (e.g. by typing "zu")


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

Offline

#1154 2011-10-23 11:28:08

bjartur
Member
Registered: 2011-10-23
Posts: 1

Re: Ranger, a textbased filemanager

Could type information be cached in xattrs (where available)?

Offline

#1155 2011-10-23 15:10:33

jimenezrick
Member
From: London, UK
Registered: 2011-06-17
Posts: 8
Website

Re: Ranger, a textbased filemanager

I can't get PDF previews. I tried copying scope.sh to my ~/.config/ranger/. I have in my rc.conf:

set preview_files=True
set use_preview_script=True

I also tried with:

set preview_script=/usr/lib/python3.2/site-packages/ranger/data/scope.sh

Any suggestion?

Last edited by jimenezrick (2011-10-23 15:11:54)

Offline

#1156 2011-10-23 15:18:36

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

Re: Ranger, a textbased filemanager

jimenezrick wrote:

I can't get PDF previews. I tried copying scope.sh to my ~/.config/ranger/. I have in my rc.conf:

set preview_files=True
set use_preview_script=True

I also tried with:

set preview_script=/usr/lib/python3.2/site-packages/ranger/data/scope.sh

Any suggestion?

install pdftotext? smile
I think it's part of another package though and I don't know which.

EDIT: pdftotext, not pdftotxt, sorry. If you open scope.sh in an editor, you'll see all the supported tools.


bjartur wrote:

Could type information be cached in xattrs (where available)?

Wanna code it? I'm not convinced that it would lead to significant performance improvements.

Last edited by hut (2011-10-23 15:26:14)


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

Offline

#1157 2011-10-23 15:24:28

jimenezrick
Member
From: London, UK
Registered: 2011-06-17
Posts: 8
Website

Re: Ranger, a textbased filemanager

Sorry, I forgot to mention that I have pdftotext installed, I made sure I have installed  poppler package. So, I don't know why PDF preview doesn't work hmm

hut wrote:

install pdftotxt? smile
I think it's part of another package though and I don't know which.

Offline

#1158 2011-10-23 15:51:37

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

Re: Ranger, a textbased filemanager

jimenezrick wrote:

Sorry, I forgot to mention that I have pdftotext installed, I made sure I have installed  poppler package. So, I don't know why PDF preview doesn't work hmm

hut wrote:

install pdftotxt? smile
I think it's part of another package though and I don't know which.

Does it work if you turn off collapse_preview? E.g. with the key "zc". Make sure the preview column has full width when you move the cursor to the pdf file.

If it doesn't, what's the output of this?

~/.config/ranger/scope.sh <your pdf file> 80 24

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

Offline

#1159 2011-10-23 16:11:54

jimenezrick
Member
From: London, UK
Registered: 2011-06-17
Posts: 8
Website

Re: Ranger, a textbased filemanager

Well, it seems that the problem are some heavy PDFs which cause troubles to pdftotext.

With the next command, the PDF is converted correctly to plain text, so it works as expected:

~/.config/ranger/scope.sh <your pdf file> 80 24

Anyway, ranger works great and most of the PDFs are shown big_smile, I love it!

Offline

#1160 2011-10-28 15:46:29

sarbash
Member
From: Russia, Naberezhnye Chelny
Registered: 2011-03-15
Posts: 32

Re: Ranger, a textbased filemanager

Hello, All.

Where to place modified color-scheme? The same dir near by anothers?

Thanks in advance.

Offline

#1161 2011-10-28 19:20:59

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

Re: Ranger, a textbased filemanager

sarbash wrote:

Hello, All.

Where to place modified color-scheme? The same dir near by anothers?

Thanks in advance.

Things like these are documented in the man page. You can open it by typing "man ranger" and press "/" to search for particular words.
To answer your question: ~/.config/ranger/colorschemes/.


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

Offline

#1162 2011-10-28 20:09:25

Yuukan
Member
Registered: 2011-07-08
Posts: 13

Re: Ranger, a textbased filemanager

I really like Ranger, it makes my life easier. Thanks for developping such an amazing tool!

Offline

#1163 2011-10-29 09:57:27

sarbash
Member
From: Russia, Naberezhnye Chelny
Registered: 2011-03-15
Posts: 32

Re: Ranger, a textbased filemanager

hut wrote:

Things like these are documented in the man page. You can open it by typing "man ranger" and press "/" to search for particular words.
To answer your question: ~/.config/ranger/colorschemes/.

Thank you and sorry for such stupid question. Obviously, I had been oblivious reading the man (sure, I knew man, vim, shortcuts etc.). Sorry again.

Last edited by sarbash (2011-10-29 10:00:43)

Offline

#1164 2011-10-29 18:59:37

gwash
Member
From: Cairo, Egypt
Registered: 2008-07-15
Posts: 27

Re: Ranger, a textbased filemanager

I used to be able to do this, with some variation:

@depends_on('archmage')
def app_archmage(self, c):
   from ranger.ext.shell_escape import shell_quote
   cmd = 'archmage -d %s | elinks' % shell_quote(c.file.basename)
   return cmd

But now i can't, for some reason. can somebody shed a light?

I'm using the latest git.

Offline

#1165 2011-10-29 19:24:17

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

Re: Ranger, a textbased filemanager

gwash wrote:

I used to be able to do this, with some variation:

@depends_on('archmage')
def app_archmage(self, c):
   from ranger.ext.shell_escape import shell_quote
   cmd = 'archmage -d %s | elinks' % shell_quote(c.file.basename)
   return cmd

But now i can't, for some reason. can somebody shed a light?

I'm using the latest git.

Fixed, thank you.


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

Offline

#1166 2011-10-29 19:59:29

gwash
Member
From: Cairo, Egypt
Registered: 2008-07-15
Posts: 27

Re: Ranger, a textbased filemanager

Hi hut, thanks for a speedy fix, now that I got your attention, I want to discuss why we need run 'flags' to be hardcoded, I want to use my own flags, for example 't' to run the command in an external terminal, 'r' to run the command as root, 'g' to use a graphical alternative (...that takes the same arguments, e.g. gvim or gnome-mplayer), etc...

Also, can the 'execute.before' signal be moved to just before running Popen, where it could actually be useful?

Thanks

EDIT:
Actually, 'execute.before' is still pretty useful the way it is, I meant could we have another one just before running Popen? this way the 'flags' thing could be implemented without having to replace Runner's __call__ method.

Last edited by gwash (2011-10-29 20:10:29)

Offline

#1167 2011-10-29 20:15:46

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

Re: Ranger, a textbased filemanager

gwash wrote:

Hi hut, thanks for a speedy fix, now that I got your attention, I want to discuss why we need run 'flags' to be hardcoded, I want to use my own flags, for example 't' to run the command in an external terminal, 'r' to run the command as root, 'g' to use a graphical alternative (...that takes the same arguments, e.g. gvim or gnome-mplayer), etc...

Also, can the 'execute.before' signal be moved to just before running Popen, where it could actually be useful?

Thanks.

How would you implement custom flags? It's not trivial, since flags affect different parts of the code, and some are mutually exclusive.

And I agree that execute.before should be moved before calling Popen.

Edit: Maybe we should discuss it in IRC?

Last edited by hut (2011-10-29 20:32:10)


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

Offline

#1168 2011-10-30 15:35:20

Army
Member
Registered: 2007-12-07
Posts: 1,784

Re: Ranger, a textbased filemanager

I just learned that theres cython which can translate python code into C code. Did anybody ever try to compile ranger with it? Is it even possible? Maybe this way ranger could be even faster smile

Offline

#1169 2011-10-30 17:29:04

Veedrac
Member
Registered: 2011-07-19
Posts: 81

Re: Ranger, a textbased filemanager

Eh. Do you find ranger slow?
Cython won't help with start-up, the speed of ncurses or any other rendering stuff, and especially not file-system io - the main bottleneck - so I don't really see the advantage. That said, I bet two pennies that it'll compile really easily. I just wouldn't bother.

...By which I mean you don't need to bother, but I find the idea mildly fascinating and might get 'round to it in the next few days if I get some free minutes.

Last edited by Veedrac (2011-11-03 10:54:15)

Offline

#1170 2011-10-31 20:13:03

Army
Member
Registered: 2007-12-07
Posts: 1,784

Re: Ranger, a textbased filemanager

No ranger isn't really slow, but e.g. hut mentioned some time ago that he would love to speed up ranger (e.g. because vifm is faster than ranger) but doesn't exactly know how. I think ranger got a lot faster in the last few weeks. It's just, I didn't know of cython, but when I saw it I thought, that it would be cool if it would help to make ranger faster.

Offline

#1171 2011-10-31 23:28:50

Veedrac
Member
Registered: 2011-07-19
Posts: 81

Re: Ranger, a textbased filemanager

Then this question is directed at hut:

What exactly is slower?

Offline

#1172 2011-11-01 07:13:46

Army
Member
Registered: 2007-12-07
Posts: 1,784

Re: Ranger, a textbased filemanager

Scrolling wasn't really fast back then and entering a directory with a lot of files would take much longer than e.g. in vifm.

edit: I decided to look through the thread and look for hut's comments I remember

https://bbs.archlinux.org/viewtopic.php … 81#p745681
https://bbs.archlinux.org/viewtopic.php … 64#p746164
https://bbs.archlinux.org/viewtopic.php … 99#p750599
https://bbs.archlinux.org/viewtopic.php … 53#p750653

Those should be enough.

Last edited by Army (2011-11-01 07:18:28)

Offline

#1173 2011-11-01 07:57:40

Army
Member
Registered: 2007-12-07
Posts: 1,784

Re: Ranger, a textbased filemanager

Something else, hence a new post:
The problem with mplayer being killed after ranger is being quit, although nohup is being used, which is described here
https://bbs.archlinux.org/viewtopic.php … 47#p917447
can be solved with this
https://bbs.archlinux.org/viewtopic.php … 35#p751935
Damn! It has always been there...
The line now should look like this

return tup('nohup', 'setsid', 'mplayer', *c)

(one setsid is enough)

AWESOME!

Last edited by Army (2011-11-01 07:58:01)

Offline

#1174 2011-11-01 18:46:04

Veedrac
Member
Registered: 2011-07-19
Posts: 81

Re: Ranger, a textbased filemanager

So, copying, start-up and large directories. I'll look into it once I've updated.
I know the problem with scrolling, but I've already sent in a patch that took care of at least 30% of the problem, and it's already a lot faster in the recent versions. It might be doing an unnecessary sort as well.
Heck - I'll get vifm while I'm at it.

Army wrote:

Something else, hence a new post:
The problem with mplayer being killed after ranger is being quit, although nohup is being used, which is described here
https://bbs.archlinux.org/viewtopic.php … 47#p917447
can be solved with this
https://bbs.archlinux.org/viewtopic.php … 35#p751935
Damn! It has always been there...
The line now should look like this

return tup('nohup', 'setsid', 'mplayer', *c)

(one setsid is enough)

AWESOME!

TYVM

Offline

#1175 2011-11-01 21:21:43

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

Re: Ranger, a textbased filemanager

Army wrote:

I just learned that theres cython which can translate python code into C code. Did anybody ever try to compile ranger with it? Is it even possible? Maybe this way ranger could be even faster smile

You can't compile ranger with cython, you would need to rewrite ranger (or parts of it) in a new language which is a mixture of python and C. I'll try it out some time.

Veedrac wrote:

So, copying, start-up and large directories. I'll look into it once I've updated.

Copying by itself isn't slow, since it's done by an instance of "cp". Ranger just becomes slow when copying or the HD is under a heavy load for some other reason.

The startup time heavily varies, depending on how much of the required filesystem data the kernel has already cached. On my machine (pretty old) I get these results when I put "quit" in the first line of ~/.config/ranger/rc.conf:

python2.7 -O ranger.py, all cached:          0.60s
python3.2 -O ranger.py, all cached:          0.75s
python2.7 and 3.2 -O ranger.py, empty cache: 4.8s to 7.1s

I dunno, many of you don't seem to have an issue with the startup time but I do. Less than 0.4s would be nice when all is cached.


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

Offline

Board footer

Powered by FluxBB