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

Show child tasks if the issue is a parent task or contains child tasks #8

Open
jackyliang opened this issue Feb 25, 2015 · 7 comments

Comments

@jackyliang
Copy link

Currently if you use redmine issue [some task number] on a parent task, it only shows the title of the parent task.

Develop a feature where if the issue contains child tasks, display all child tasks as well.

For example:

jackyliang:directory-name loop$ redmine issue 7904
[Project Name] This Project's Parent Task
@yanjost
Copy link
Owner

yanjost commented Feb 25, 2015

Good idea ! I suggest also that the child issues are indented and/or shown as a tree

@allan-simon
Copy link
Contributor

i will look into that, there's certainly some nice python library to display "termina-based tree"

@jackyliang
Copy link
Author

Yes, precisely. This is what I had in mind: http://www.computerhope.com/unix/tree.htm

.
├── config.dat
├── data
│ ├── data1.bin
│ ├── data2.sql
│ └── data3.inf
├── images
│ ├── background.jpg
│ ├── icon.gif
│ └── logo.jpg
├── program.exe
└── readme.txt

@yanjost
Copy link
Owner

yanjost commented Feb 25, 2015

I have found this module : https://pypi.python.org/pypi/asciitree/ but I don't known if it is worth integrating it

@jackyliang
Copy link
Author

That looks good. The things I think to consider on a user experience level is:

  1. What would you do if the parent task has like 200+ tasks with multiple childs within childs? I think at that point, if all 200 tasks are printed and nested, it might as well be as useless as not being printed, since that's too much both vertically and horizontally.
  2. What info do you plan to print per issue? The existing format of the title? In my opinion something like #[Task Number] [Title] would be the best

Thanks a lot =D

Update: Nevermind, Allan is suggesting you could use redmine issue [task number] | less to paginate vertically and horizontally on the CLI, which would keep it simple, stupid (KISS).

@yanjost
Copy link
Owner

yanjost commented Feb 26, 2015

  1. maybe set a default limit ?
  2. We have to think of a default format for all outputs

@allan-simon
Copy link
Contributor

issue a PR #9 ,

I don't it makes sense to put a limit because it becomes easily tricky to define what does the limit , limit for the tree view , and anyway you "got them all" from the api response, and adding a default limit needs to have a option to display more etc.

at the opposite displaying everything does not cost more, because well you already got everything in the API response anyway, and in terminal i think it's really the job of a pager ( more / less / most ) to paginate (or tail/head )

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

No branches or pull requests

3 participants