Skip to content

Commit

Permalink
adding controls on top of view
Browse files Browse the repository at this point in the history
  • Loading branch information
Guillermo Fernández committed Jan 16, 2024
1 parent 501931e commit 2402b66
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
5 changes: 4 additions & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,10 @@ func (m model) View() string {
return "Reading files..."
}

viewString := fmt.Sprintf("Current directory: %q\n", m.currentDir)
viewString := "Controls:\n"
viewString += "d: delete dir/file\nh,left arrow: go up a directory\nl, right arrow, enter: go down selected dir\n"
viewString += "j,down arrow: move down\nk,up arrow: move up\n"
viewString += fmt.Sprintf("\nCurrent directory: %q\n", m.currentDir)
viewString += baseStyle.Render(m.table.View()) + "\n"

return viewString
Expand Down
7 changes: 3 additions & 4 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

## TODO

- [ ] improve filetree traversing
- [ ] add instructions at the top
- [ ] add error message
- [ ] use human readable format for byte count
- add error message
- use human readable format for byte count
- add toggle to show/hide controls

0 comments on commit 2402b66

Please sign in to comment.