Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add mode, user and group info parameters #1799

Merged
merged 3 commits into from
Sep 13, 2024

Conversation

owallb
Copy link
Contributor

@owallb owallb commented Sep 13, 2024

Closes #1554

Copy link
Collaborator

@joelim-work joelim-work left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for submitting this. I have some minor comments, but overall I think the changes are good and can be merged soon.

doc.md Outdated
@@ -811,7 +811,7 @@ Apply filter pattern after each keystroke during filtering.
## info ([]string) (default ``)

A list of information that is shown for directory items at the right side of the pane.
Currently supported information types are `size`, `time`, `atime`, and `ctime`.
Currently supported information types are `size`, `time`, `atime`, `ctime`, `mode`, `user` and `group`.
Copy link
Collaborator

@joelim-work joelim-work Sep 13, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just wondering, do you think instead of using mode, something like perm or permissions is more intuitive as the name here? Might be a good idea to check what other file managers are using.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah I agree, I will change it to perm.

ui.go Outdated
@@ -519,6 +542,26 @@ func (win *win) printDir(ui *ui, dir *dir, context *dirContext, dirStyle *dirSty
}
}

func getGroupWidth(dir *dir, beg int, end int) int {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You mixed up the function names:

Suggested change
func getGroupWidth(dir *dir, beg int, end int) int {
func getUserWidth(dir *dir, beg int, end int) int {

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oops! Nice catch.

ui.go Outdated
return maxw
}

func getUserWidth(dir *dir, beg int, end int) int {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here:

Suggested change
func getUserWidth(dir *dir, beg int, end int) int {
func getGroupWidth(dir *dir, beg int, end int) int {

@joelim-work joelim-work added the new Pull requests that add new behavior label Sep 13, 2024
@joelim-work joelim-work added this to the r33 milestone Sep 13, 2024
Copy link
Collaborator

@joelim-work joelim-work left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks once again for the changes 🎉

@joelim-work joelim-work merged commit 1c56620 into gokcehan:master Sep 13, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
new Pull requests that add new behavior
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Feature request: Add file permissions and owner to "info" option
2 participants