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

log section improvements #53

Closed
bugzpodder opened this issue Jul 1, 2019 · 5 comments
Closed

log section improvements #53

bugzpodder opened this issue Jul 1, 2019 · 5 comments
Labels
enhancement New feature or request

Comments

@bugzpodder
Copy link

bugzpodder commented Jul 1, 2019

Love the tool!

I'd like to propose some potential small enhancements to the logs section:

  1. filter by time (30s/5m/1hr) [maybe not that useful]
  2. color coding [not too sure how to decide what needs to be color coded, perhaps part of config using regex]
  3. Don't allow scroll pass the end of logs
  4. regex search [this will be super useful i think]
@bugzpodder bugzpodder added the enhancement New feature or request label Jul 1, 2019
@nicholascloud
Copy link

Ditto about loving the tool -- I would like to request an option to wrap long log lines.

@jesseduffield
Copy link
Owner

wrapping logs is possible via:

gui:
  wrapMainPanel: true

Filtering logs is also possible by overriding with:

commandTemplates:
  serviceLogs: '{{ .DockerCompose }} logs --since=60m --follow {{ .Service.Name }}'
  containerLogs: docker logs --follow --since=60m {{ .Container.ID }}
  allLogs: '{{ .DockerCompose }} logs --tail=300 --follow'

Not scrolling past the end of logs is covered here: #31

color coding sounds tricky, could you raise a separate issue for that?

searching is covered by #33

I think that covers everything :)

@bugzpodder
Copy link
Author

wow, thats amazing. Thank you!

@nicholascloud
Copy link

@jesseduffield Ah, awesome. Thanks for the reply!

Dropping this bit from the config doc here just in case someone doesn't know how to edit their config.yml:

You can open your config file by going to the status panel (using left-arrow) and pressing 'o'.

@thibault-ketterer
Copy link

thibault-ketterer commented Oct 8, 2021

works for colors but a bit slowish (install ccze first)

commandTemplates:  
  serviceLogs: '{{ .DockerCompose }} logs --since=60m --follow {{ .Service.Name }} | ccze -A'
  containerLogs: docker logs --follow --since=60m {{ .Container.ID }} | ccze -A                     
  allLogs: '{{ .DockerCompose }} logs --tail=300 --follow | ccze -A'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants