GithubHelp home page GithubHelp logo

simple file viewer for text files about gdu HOT 5 CLOSED

dundee avatar dundee commented on June 3, 2024 1
simple file viewer for text files

from gdu.

Comments (5)

dundee avatar dundee commented on June 3, 2024 3

Thanks so much, @dundee

You welcome!

from gdu.

dundee avatar dundee commented on June 3, 2024 2

The xdg-open way can be implemented quite easily, but the rest is hard (maybe even impossible), because of the way how the terminal UI library works. But I am not sure if it's nice to open files from gdu (terminal app) into GUI apps. Internal file viewer would be probably better (but not easy to implement).

from gdu.

ouuan avatar ouuan commented on June 3, 2024

I think this is not what a du (disk usage analyzer) does. Usually, a du is used to find which file takes the most space, not to browse the files. And text files are usually not big.

Maybe you are looking for something like nnn?

from gdu.

admirabilis avatar admirabilis commented on June 3, 2024

I see the use case for this. When using a file manager like mc, I am generally browsing where I know mostly everything - whereas with gdu, I'm generally exploring new places. Many times, while using ncdu, I've had a "what's this file?" moment, and I had to copy the directory path and paste it into a new shell just to view what the supposed file contains.

I guess a simple option to implement would be a key to spawn $PAGER (which generally can be used for text or compressed text), and another key for running xdg-open (which will call a GUI for any file type).

Another key to run a shell in $PWD could be more troublesome to implement, the previous two keys should cover most use cases.

from gdu.

admirabilis avatar admirabilis commented on June 3, 2024

Thanks so much, @dundee

from gdu.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.