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

feature request: any appetite for supporting dynamic text? #167

Open
davidxia opened this issue Nov 11, 2021 · 2 comments · May be fixed by #166
Open

feature request: any appetite for supporting dynamic text? #167

davidxia opened this issue Nov 11, 2021 · 2 comments · May be fixed by #166

Comments

@davidxia
Copy link

Description

I'd like the text to be dynamic, e.g. an updating timestamp or time since something happened.
I have a prototype here where users can make text a function instead of a static string.

with Halo(text=lambda: f'date {datetime.datetime.now()}'):
    time.sleep(100)

Any appetite for supporting this? If so, any feedback on my PR would be great. I still have to add tests.

@davidxia davidxia linked a pull request Nov 11, 2021 that will close this issue
3 tasks
@Nbelles
Copy link

Nbelles commented Feb 24, 2022

I have just attempted the changes that were recommended on my local machine and they seem to work well. Thanks for putting in the work! @davidxia

@davidxia
Copy link
Author

@Nbelles thanks, hoping the maintainer(s) notice and reply :)

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

Successfully merging a pull request may close this issue.

2 participants