Giter Club home page Giter Club logo

ls-go's Issues

Permissions display incomplete (on Linux)

It appears neither sticky bit nor ACL "+" get shown when doing a directory listing:

# ls-go -l .
 d rwx rwx r-x  www-data www-data   4.00K 31.Jul'20 07:34  default

Comparing to regular ls:

# ls -l .
drwsrwsr-x+ 10 www-data www-data 4096 Jul 31 07:34 default

Not sure if ACL is possible to add. But sticky bit is pretty essential. :)

panic: user: unknown userid

Panics when encountering a file or directory where there is no user mapping. Presumably the same will happen for non-mapped groups.

uname -a
Linux laptop 4.9.0-3-amd64 #1 SMP Debian 4.9.30-2+deb9u5 (2017-09-19) x86_64 GNU/Linux
go version
go version go1.9 linux/amd64
v0.0.2 
nicolaw@laptop: ~/go/src/github.com/acarl005/ls-go $ git rev-parse HEAD 
187bc787f33b3c1a82f68d3b3de205f3a26e79b9
panic: user: unknown userid 999

goroutine 1 [running]:
main.check(0x74c0e0, 0xc420390508)
	/home/nicolaw/go/src/github.com/acarl005/ls-go/ls-go.go:603 +0x4a
main.getOwnerAndGroup(0xc42004f9d8, 0xc420019304, 0x7, 0xc4203904f0, 0x7)
	/home/nicolaw/go/src/github.com/acarl005/ls-go/ls-unix.go:22 +0x18e
main.listFiles(0xc42038e640, 0x15, 0xc42004fbe8, 0x0)
	/home/nicolaw/go/src/github.com/acarl005/ls-go/ls-go.go:147 +0x1a8
main.listDir(0xc42038e640, 0x15)
	/home/nicolaw/go/src/github.com/acarl005/ls-go/ls-go.go:121 +0x31e
main.listDir(0xc4204c45c0, 0xb)
	/home/nicolaw/go/src/github.com/acarl005/ls-go/ls-go.go:128 +0x2d9
main.listDir(0x631b44, 0x1)
	/home/nicolaw/go/src/github.com/acarl005/ls-go/ls-go.go:128 +0x2d9
main.main()
	/home/nicolaw/go/src/github.com/acarl005/ls-go/ls-go.go:86 +0x4ac

Wrong colors

Is it possible to use the default terminal colors instead of custom ones?
I have a tad different palette configured, e.g.:

  • exa

exa

  • ls-go

ls-go

License?

I know this may be obvious, but is there any license to go with this?

ls with wrong argument panics

if i'm in a directory with a file named bar
if I run ls-go baz I get a panic.

panic: stat baz: no such file or directory

goroutine 1 [running]:
main.check(0x74eb40, 0xc4200112c0)
	/home/bugless/src/github.com/acarl005/ls-go/ls-go.go:478 +0x4a
main.main()
	/home/bugless/src/github.com/acarl005/ls-go/ls-go.go:59 +0x1dd

ls-go painic when file group is unkonwn

When the group is unknown, ls-go will show the error below, then panic

panic: group: unknown groupid 1000

goroutine 1 [running]:
main.check(0x63fa20, 0xc42007e830)
        /home/jiasui/repos/ls-go/src/github.com/acarl005/ls-go/ls-go.go:603 +0x4a
main.getOwnerAndGroup(0xc4200ddc30, 0x1a4, 0x0, 0x0, 0x1)
        /home/jiasui/repos/ls-go/src/github.com/acarl005/ls-go/ls-unix.go:24 +0x1b4
main.listFiles(0x619564, 0x1, 0xc4200dde38, 0x0)
        /home/jiasui/repos/ls-go/src/github.com/acarl005/ls-go/ls-go.go:189 +0x59f
main.listDir(0x619564, 0x1)
        /home/jiasui/repos/ls-go/src/github.com/acarl005/ls-go/ls-go.go:121 +0x2e8
main.main()
        /home/jiasui/repos/ls-go/src/github.com/acarl005/ls-go/ls-go.go:86 +0x45d

Reproduce step:

  1. touch 123
  2. chown jiasui:1000 123
  3. Run ls-go

suggestion - add reverse sort order option

I often use the reverse sorting option with ls, particularly when sorting by time. I am not sure what flags would be appropriate here since -r and -R are already in use.

Feature requests

Hello, I really love this tool, but there are a couple of things that would increase my pleasure even more!

  1. Is it possible, when using the --nerd-font, to optionally specify that an extra space be displayed between the nerdchar and the file/folder name?
  2. Is it possible to specify a hidden files ONLY option?

It may be that ls-go already supports these options and I just haven't found them yet.
Alternatively, I guess I could just fork the Golang code. Hmm... there's an idea!

Build Issues on Windows

When trying to build on Windows, I get these errors:

# github.com/acarl005/ls-go
..\..\..\..\acarl005\ls-go\ls-windows.go:59:10: undefined: syscall.Stat_t
..\..\..\..\acarl005\ls-go\ls-windows.go:60:9: undefined: syscall.Stat
..\..\..\..\acarl005\ls-go\ls-windows.go:62:35: undefined: "golang.org/x/sys/windows".Major
..\..\..\..\acarl005\ls-go\ls-windows.go:63:35: undefined: "golang.org/x/sys/windows".Minor

It seems that syscall.Stat_t is only available on Linux systems, and I'm not sure when windows.Major/Minor was deprecated...

Runtime errors

macOS 10.13.6
Golang 1.10.3
Git 2.13.0

Hello. I've just tried running ls-go.go with vgo run ls-go.go, but I get a bunch of errors:

# command-line-arguments
./ls-go.go:54:2: undefined: argsPostParse
./ls-go.go:59:27: undefined: args
./ls-go.go:103:10: undefined: args
./ls-go.go:106:31: undefined: args
./ls-go.go:115:12: undefined: args
./ls-go.go:116:10: undefined: args
./ls-go.go:124:6: undefined: args
./ls-go.go:126:50: undefined: args
./ls-go.go:145:6: undefined: args
./ls-go.go:147:20: undefined: getOwnerAndGroup
./ls-go.go:147:20: too many errors

What am I doing wrong? Thanks!

autocomplete dirs in warp

It seems that in Warp terminal I cant autocomplete tabs through TAB button. Maybe I shoud add something to my configuration?

Would like to embedd this in my project

Basically i am working on small modifications to my fork of Gosh
and i want to implement this into my project

I am looking for a half decent implementation of ls and other directory management utilities in go, and this one fits the bill for the most part

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.