Giter Site home page Giter Site logo

filenav's Introduction

FileNav

A simple, TUI file dialog built with Python and the curses library.

Features

  • Navigate through directories using arrow keys
  • Display file sizes in human-readable format
  • Sort files by alphabet or type
  • Go to a specific path
  • Select files or directories

Requirements

  • Python 3.x
  • curses library (typically included in standard Python installations)

Installation

  1. Clone this repository or download the source code.
  2. Install the required dependencies:

Usage

To use FileNav in your Python project:

from filenav import GetPath

file_or_folder_path = "/home/user/"
selected_path = GetPath(file_or_folder_path)
if selected_path:
    print(f"Selected path: {selected_path}")
else:
    print("No path selected")

Controls

  • Arrow Up/Down: Move cursor
  • Enter/Right Arrow: Open directory or select file
  • Shift+Enter: Select current directory
  • Left Arrow/Backspace: Go to parent directory
  • 's': Toggle sort mode (by alphabet or type)
  • 'f': Go to a specific path
  • 'q': Quit the navigator

Note

This module is designed for use in terminal environments and relies on the curses library, which is typically pre-installed on Unix-like systems (Linux, macOS). Windows users may need to install a third-party curses library.

filenav's People

Watchers

lesserfield avatar

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.