Skip to content

Smarthard/fowsh

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

36 Commits
 
 
 
 
 
 
 
 

Repository files navigation

fowsh

fowsh is a shell wrapper for instant opening files such as ascii text, images, movies, etc... It allows you to work with regular files without thinking what you need to open them.

What fowsh can do

It just opens file for you. Look, here some examples of using:

$ fow Projects/fowsh/fow.sh # opens fowsh's shell scipt in your EDITOR

AVI file opening demo:

demo mpv

Even ls output with changed opening command:

$ fow -o less `ls`

...or command pipelining:

$ ls | fow -o cat

Installation

Clone this repository, place fow.sh somewhere you want to:

git clone https://github.com/Smarthard/fowsh
mv fowsh/fow.sh DIR/

For fast access make an alias to fow.sh in your ~/.bashrc:

alias fow="DIR/fow.sh"

Also fowsh needs some specific environment variables to be set:

  • BROWSER - default web browser
  • EDITOR - default editor for text files
  • FOWSH_RIMAGE - default raster images viewer/editor
  • FOWSH_VIMAGE - default vector images viewer/editor
  • FOWSH_VIDEO - default multimedia viewer

Modify and copy these to your ~/.bashrc:

export BROWSER=firefox
export EDITOR=vim
export FOWSH_RIMAGE=gimp
export FOWSH_VIMAGE=$FOWSH_RIMAGE
export FOWSH_VIDEO=mpv

Source your updated ~/.bashrc

source ~/.bashrc

Now you ready to go!

TODO

  • Text files support
  • Raster images support
  • Vector images support
  • Movies, video
  • Links
  • Binaries?
  • ???
  • Logging
  • Script options
    • Forced opening with...
    • Ignore files by name
    • Ignore files by type
    • HELP!
    • Usage
  • Preventing to open too many files

About

File opener wrapper for shell

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages