You are not logged in.

#2101 2018-02-02 23:18:55

Ronan Bell
Member
Registered: 2018-02-02
Posts: 2

Re: Ranger, a textbased filemanager

hut wrote:

Hey people, I just wanted to let you know that v1.9.0 finally out: https://github.com/ranger/ranger/releases/tag/v1.9.0

Changelog: https://github.com/ranger/ranger/blob/m … ANGELOG.md

Thanks for all the great work.

I have a little problem with the latest version. I have some keybindings for console commands that end with a space (e.g.  map r console rename<space> ) but now the space no longer registers and I have to press the spacebar manually every time before I can start typing. What can I do?

Offline

#2102 2018-03-31 19:28:11

bartekb81
Member
From: Stuttgart/Ostfildern, Germany
Registered: 2018-03-31
Posts: 1

Re: Ranger, a textbased filemanager

Ronan Bell wrote:

I have a little problem with the latest version. I have some keybindings for console commands that end with a space (e.g.  map r console rename<space> ) but now the space no longer registers and I have to press the spacebar manually every time before I can start typing. What can I do?

Replace the <space> with %space string, i.e.:

map r console rename%space

Offline

#2103 2018-03-31 23:14:08

Ronan Bell
Member
Registered: 2018-02-02
Posts: 2

Re: Ranger, a textbased filemanager

bartekb81 wrote:

Replace the <space> with %space string, i.e.:

map r console rename%space

It worked, thanks!

Offline

#2104 2018-09-20 02:18:21

bilabila
Member
Registered: 2018-08-07
Posts: 26
Website

Re: Ranger, a textbased filemanager

Hi, I have a question
I use the script from wiki to avoid nesting

function r
	if test -z $RANGER_LEVEL
        ranger $argv
    else
        exit
    end
end

However, if I change dir in the nest shell then enter r to return, the ranger dir is still.
Without this workaround, the ranger dir is current shell dir.
Is there any better workaround or hack?

Offline

#2105 2018-09-20 02:22:50

bulletmark
Member
From: Brisbane, Australia
Registered: 2013-10-22
Posts: 675

Re: Ranger, a textbased filemanager

bilabila wrote:

s there any better workaround or hack?

Seems like your other thread about this has been closed so I will repost my answer here.

Different approach but I think it does what you want. I have the following in my ~/.bashrc:

if type ranger &>/dev/null; then
    if [[ -f /usr/share/doc/ranger/examples/bash_automatic_cd.sh ]] ;then
        source /usr/share/doc/ranger/examples/bash_automatic_cd.sh
        alias r='ranger-cd'
    else
        alias r='ranger'
    fi
fi

So I always start ranger with `r` as you do. Then just type `q` to quit ranger instead of `S` and you will be in the last dir selected by ranger. Then just `r` to start ranger again in that dir or wherever you have cd to.

Last edited by bulletmark (2018-09-20 02:35:26)

Offline

#2106 2018-09-20 03:24:15

bilabila
Member
Registered: 2018-08-07
Posts: 26
Website

Re: Ranger, a textbased filemanager

bulletmark wrote:

So I always start ranger with `r` as you do. Then just type `q` to quit ranger instead of `S` and you will be in the last dir selected by ranger. Then just `r` to start ranger again in that dir or wherever you have cd to.

Sorry for delete and repost
Thanks, this method fit my need but has one drawback, toggle from shell to ranger need more time then `exit`

Offline

#2107 2018-09-20 04:27:19

bulletmark
Member
From: Brisbane, Australia
Registered: 2013-10-22
Posts: 675

Re: Ranger, a textbased filemanager

bilabila wrote:

Thanks, this method fit my need but has one drawback, toggle from shell to ranger need more time then `exit`

You really notice a difference?!

In theory you are correct of course but in practice ranger starts so quickly I can't see it being a valid concern.

Offline

#2108 2018-09-20 05:47:32

bilabila
Member
Registered: 2018-08-07
Posts: 26
Website

Re: Ranger, a textbased filemanager

bulletmark wrote:

You really notice a difference?!

In theory you are correct of course but in practice ranger starts so quickly I can't see it being a valid concern.

Yes, there is a little but noticable difference to me.
BTW, I figure it out using

map s chain shell $SHELL; eval fm.cd(open('/tmp/rangerdir').readline().strip())

and alias

function r
	if test -z $RANGER_LEVEL
        ranger $argv
    else
        echo (pwd) > /tmp/rangerdir
        exit
    end
end

Last edited by bilabila (2018-09-20 05:47:53)

Offline

#2109 2019-04-01 18:59:28

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

Re: Ranger, a textbased filemanager

After tirelessly working on designing a new concept for ranger, I am proud to announce that we have finalized the new default ranger color scheme!  The vaporwave-inspired color scheme "aesthetic":

https://raw.githubusercontent.com/range … thetic.png

Best served with cold Arizona Ice Tea, Kung Fury playing from a VHS on a flickering CRT, with the volume cranked up to 11. Just upgrade ranger from github and enjoy.


moderator edit -- replaced oversized image with link.
Pasting pictures and code

Last edited by 2ManyDogs (2019-04-01 19:07:54)


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

Offline

#2110 2019-05-01 17:09:56

brwnoman
Member
Registered: 2017-11-01
Posts: 1

Re: Ranger, a textbased filemanager

ISSUE
I would like to open vim via ranger and, if necessary, to be able to suspend vim with CTRL+Z and go back to ranger.
However, what actually happens is that either:
1. if vim was opened with ranger's ':shell vim' command, CTRL+Z sends me to terminal that is itself suspended, so that all I can do is open another terminal window and do 'kill -18 vim';
2. or, if vim was opened via a terminal opened with ranger's 'S' keybinding, CTRL+Z leads me to that same terminal, from which I cannot quit because vim is backgrounded.
Is there a way to obtain the desired behaviour of comming to-and-from between vim and ranger?

Offline

#2111 2019-10-31 16:48:12

walteweiss
Member
Registered: 2019-09-07
Posts: 33

Re: Ranger, a textbased filemanager

Hello everyone,

I have found a great use-case for ranger recently: managing my notes! I have been struggling to find my ideal note-taking software for years, but had no luck with it. Recently I realized that vim and plain text files is enough for me, really. Ranger takes it to the new level, as it’s a joy to use it as my file manager! I simply organize my notes with the logic I want, and that’s enough!

But I would also like to encrypt the text files. I’ve tried to make a gpg-file, but it doesn’t behave like I want it to. I would like to enter my password once per session, or every N minutes, and be able to access the entire tree of files, otherwise the files should be encrypted. I want this only because I’m considering syncing to 3rd party servers (either via git with GitLab, or maybe even via Dropbox). At this point I use ResilioSync, but I think Git could be better for this.

I’m very new to ranger, so it may be even obvious to some of you. Also I’m new to encryption, so I may not understand some concepts.

Please point me in the right direction, if you know.

Thanks.

P.S. As an alternative scenario I think I can start a git-server on my homelab, with encrypted file-system. Will it excuse unencrypted plain text files then? Not that I keep top-secrets there, just an average Joe’s notes, like ‘took my dog to vet clinic today,’ but I would like to implement good habits from the start.


Russia is committing genocide on Ukraine right now (2022—2024), please help Ukraine as much as you can. That’s the turning point of the democracy vs tyranny war, and if Ukraine loses, everyone in the democracy world will. You can donate to Ukraine here: savelife.in.ua/en/donate or help with spreading the information about the ongoing events. Thank you.

Offline

#2112 2019-10-31 17:01:32

walteweiss
Member
Registered: 2019-09-07
Posts: 33

Re: Ranger, a textbased filemanager

Also, I have another type of a question. There is a file preview on the very right. Can I make it break lines for me, on a text-based files? I mean when I have a long line, I want it to be readable via preview, not opening them, because it’s more useful for short files. Is it possible? I couldn’t find anything relevant in the settings, and I don’t know whether I should keep looking (say, it is achievable via a plug-in), or it’s something that won’t work because of something I don’t understand.

A visual example of what I mean, the first line is cut, but I want it to be shown as the next lines, like any terminal-based text fills the space, regardless of the column size.


Russia is committing genocide on Ukraine right now (2022—2024), please help Ukraine as much as you can. That’s the turning point of the democracy vs tyranny war, and if Ukraine loses, everyone in the democracy world will. You can donate to Ukraine here: savelife.in.ua/en/donate or help with spreading the information about the ongoing events. Thank you.

Offline

#2113 2019-10-31 19:13:29

firecat53
Member
From: Lake Stevens, WA, USA
Registered: 2007-05-14
Posts: 1,542
Website

Re: Ranger, a textbased filemanager

Here's a similar solution to edit an encrypted file when working ansible vault. Because the file is gpg encrypted and I use gpg-agent, I only get asked my password once until it times out (depending on the setting in ~/.gnupg/gpg-agent.conf. I added this class to ~/.config/commands.py:

class ave(Command):
    """:ave

    Edit the current selection with ansible-vault edit
    """
    def execute(self):
        action = ["ansible-vault", "edit","--vault-password-file="
                    "/usr/local/bin/ansible_vault_password.py",
                    self.fm.thistab.get_selection()[0].path]
        self.fm.execute_command(action)

Then just typing `:ave` with the current file highlighted will launch the editor to edit the decrypted file. The script 'ansible_vault_password.py' decrypts the password file and provides it to the vault command. Same principle as you want, but different commands to decrypt your note file. Another command `:avv` decrypts and views the file in the default pager without opening it for editing.

I can't answer your second questions about wrapping the preview lines.

Offline

#2114 2019-11-03 15:15:47

Docbroke
Member
From: India
Registered: 2015-06-13
Posts: 1,437

Re: Ranger, a textbased filemanager

walteweiss wrote:

...
But I would also like to encrypt the text files. I’ve tried to make a gpg-file, but it doesn’t behave like I want it to. I would like to enter my password once per session, or every N minutes, and be able to access the entire tree of files, otherwise the files should be encrypted. I want this only because I’m considering syncing to 3rd party servers (either via git with GitLab, or maybe even via Dropbox). At this point I use ResilioSync, but I think Git could be better for this.

I use "pass" to manage my passwords and password protected notes with a bash wrapper script to simplify it, you may find it here https://github.com/Docbroke/pass_rofi/b … /pass_rofi

Last edited by Docbroke (2019-11-03 15:17:47)

Offline

#2115 2020-01-16 17:54:36

walteweiss
Member
Registered: 2019-09-07
Posts: 33

Re: Ranger, a textbased filemanager

Hello, excuse me for not replying on here, I left this task for later, till the point I have more understanding to ask less obvious questions. Not sure I did that, as my questions are still the same.

Docbroke wrote:

I use "pass" to manage my passwords and password protected notes with a bash wrapper script to simplify it, you may find it here https://github.com/Docbroke/pass_rofi/b … /pass_rofi

Thank you, I use pass/gopass as well and I really like it. I use both, because I like different features they have. But I don’t want to use notes using pass, because their structure is going to be more complicated. Though I would like to achieve similar functionality on here and use my notes the same way: I would like them to be gpg-encrypted and decrypt them to work with all my notes (all of them, if possible) for some time, usually I need an hour or two, but I don’t mind entering my password every 10 or 15 minutes to decrypt them again, if the hour or two is somewhat complicated or is not recommended, security wise.

firecat53 wrote:

Here's a similar solution to edit an encrypted file when working ansible vault. Because the file is gpg encrypted and I use gpg-agent, I only get asked my password once until it times out (depending on the setting in ~/.gnupg/gpg-agent.conf.

I have three questions here:
1. Is it possible to set different time-outs for my pass and my notes vaults? I don’t mind using different gpg-keys for that, if needed.
2. Do I need to learn ansible first, to use this ansible vault? I have never used ansible, but I’m aware of what that is, and have plans to learn it.
3. Is it possible to have all my notes encrypted, but search them as regular files while decrypted? (At this point my notes are just regular plaintext files. I would like them to be encrypted, but I want the architecture of it to be as simple as possible.)

Thank you.


Russia is committing genocide on Ukraine right now (2022—2024), please help Ukraine as much as you can. That’s the turning point of the democracy vs tyranny war, and if Ukraine loses, everyone in the democracy world will. You can donate to Ukraine here: savelife.in.ua/en/donate or help with spreading the information about the ongoing events. Thank you.

Offline

#2116 2020-04-14 00:29:18

buttcake
Member
Registered: 2016-10-16
Posts: 37

Re: Ranger, a textbased filemanager

Has anyone here tried creating a rifle aur package ?
I'm thinking of just modifying the default ranger package and just add a few lines in package() that delete all files which don't have "rifle" in their name.

Offline

#2117 2021-09-28 12:19:34

anti3d
Member
Registered: 2021-09-28
Posts: 1

Re: Ranger, a textbased filemanager

Maybe possible to do horizontal list and scrolling of files? Or horizontal list of files, and last column scrolling down...
It is very inconvenient to scroll through long lists of files, and have so much space on monitor.
Thanks.

Last edited by anti3d (2021-09-28 12:29:44)

Offline

#2118 2021-10-02 02:17:18

Mizho
Member
Registered: 2021-06-23
Posts: 14

Re: Ranger, a textbased filemanager

anti3d wrote:

Maybe possible to do horizontal list and scrolling of files? Or horizontal list of files, and last column scrolling down...
It is very inconvenient to scroll through long lists of files, and have so much space on monitor.
Thanks.

Not sure if this available but you may customize ranger (don't know if could be achieved by custom `linemode`).

However, as a TUI file manager in contrast to GUI ones it has lots of powerful functionalities which you might consider instead of GUI approach. One is 'filters' in ranger (`zf`) or various command line based search/regex and sorts to quickly trim down the list to target options e.g. scout, etc. One main reason to use ranger instead of GUI alternatives is this functionalities at the first place, trying to mimic what is in GUI in TUI might be counter productive, as I see it.

Offline

#2119 2022-03-19 08:21:20

ngoonee
Forum Fellow
From: Between Thailand and Singapore
Registered: 2009-03-17
Posts: 7,358

Re: Ranger, a textbased filemanager

Anyone experiencing pandoc issues? https://bugs.archlinux.org/task/74162


Allan-Volunteer on the (topic being discussed) mailn lists. You never get the people who matters attention on the forums.
jasonwryan-Installing Arch is a measure of your literacy. Maintaining Arch is a measure of your diligence. Contributing to Arch is a measure of your competence.
Griemak-Bleeding edge, not bleeding flat. Edge denotes falls will occur from time to time. Bring your own parachute.

Offline

#2120 2022-03-19 13:48:09

Alad
Wiki Admin/IRC Op
From: Bagelstan
Registered: 2014-05-04
Posts: 2,418
Website

Re: Ranger, a textbased filemanager

ngoonee wrote:

Anyone experiencing pandoc issues? https://bugs.archlinux.org/task/74162

Can you replicate it with aur/pandoc-bin?


Mods are just community members who have the occasionally necessary option to move threads around and edit posts. -- Trilby

Offline

#2121 2022-03-19 22:25:33

ngoonee
Forum Fellow
From: Between Thailand and Singapore
Registered: 2009-03-17
Posts: 7,358

Re: Ranger, a textbased filemanager

Alad wrote:
ngoonee wrote:

Anyone experiencing pandoc issues? https://bugs.archlinux.org/task/74162

Can you replicate it with aur/pandoc-bin?

progandy has replicated it in the bug report. I have just verified that myself. Upstream bug report it is.


Allan-Volunteer on the (topic being discussed) mailn lists. You never get the people who matters attention on the forums.
jasonwryan-Installing Arch is a measure of your literacy. Maintaining Arch is a measure of your diligence. Contributing to Arch is a measure of your competence.
Griemak-Bleeding edge, not bleeding flat. Edge denotes falls will occur from time to time. Bring your own parachute.

Offline

Board footer

Powered by FluxBB