```
$ tea issue 230
#230 issue/pull details: show reactions (open)
@6543 created 2020-10-22 16:39
since reactions are utf8 now and most terminals too, we can display them nicely :)
https://gitea.com/api/v1/repos/gitea/tea/issues/230/reactions
--------
1x 🎉 | 1x 👀 | 1x | 1x 👍 | 1x 👎 | 1x 😆 | 1x 😕 | 1x ❤️
```
caveats:
- reactions are not returned as UTF8 (as was claimed in #230), so they need to be parsed. the library I use doesn't (and can't → ) support all reactions available in gitea
- currently only for issues, as reactions for comments mean an additional API request for each comment..
fixes#230
Co-authored-by: Norwin <git@nroo.de>
Reviewed-on: https://gitea.com/gitea/tea/pulls/421
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
Reviewed-by: techknowlogick <techknowlogick@gitea.io>
Co-authored-by: Norwin <noerw@noreply.gitea.io>
Co-committed-by: Norwin <noerw@noreply.gitea.io>
show comments of PR
TODO: there needs to be a way to force running non-interactively
add `tea comment` to post a comment
add --comments flag, prompt only if necessary
don't prompt if --comments is provided, or output is piped
show comments for issues, add --comments flag
tea comment: print resulting comment
Merge branch 'master' into issue-172-comments
remove debug print statement
unrelated, but better than opening another PR for this ;)
Merge remote-tracking branch 'upstream/master' into issue-172-comments
ret err
fix lint
Co-authored-by: Norwin Roosen <git@nroo.de>
Co-authored-by: 6543 <6543@obermui.de>
Reviewed-on: https://gitea.com/gitea/tea/pulls/313
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
Reviewed-by: 6543 <6543@obermui.de>
Co-Authored-By: Norwin <noerw@noreply.gitea.io>
Co-Committed-By: Norwin <noerw@noreply.gitea.io>
add cli.AppHelpTemplate for customization
customize tea help view
tea --version : improve parseability
Rework README to include tea help output
It's an antipattern to have different help texts aimed at the same
users. So now that we have a good cli help text, lets use it here.
This eases maintenance, and at the same time gives an honest impression
on what we have to offer, while also encouraging to improve the internal
help text in the future.
I feel a bit sad for the GIF, but it was becoming outdated anyway..
group commands by category
add new demo gif
shows the (probably) most useful workflow
readme improvement
Merge branch 'master' into improve-app-help
code review
Merge branch 'master' into improve-app-help
restructure installation section
Co-authored-by: Norwin Roosen <git@nroo.de>
Reviewed-on: https://gitea.com/gitea/tea/pulls/311
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
Reviewed-by: khmarbaise <khmarbaise@noreply.gitea.io>
Co-Authored-By: Norwin <noerw@noreply.gitea.io>
Co-Committed-By: Norwin <noerw@noreply.gitea.io>
introduce TeaContext
clean up InitCommand
move GetListOptions to TeaContext
ensure context for each command
so we fail early with a good error message instead of "Error: 404" etc
make linter happy
Merge branch 'master' into refactor-global-flags
move TeaContext & InitCommand to modules/context
Merge branch 'master' into refactor-global-flags
CI.restart()
Merge branch 'master' into refactor-global-flags
Merge branch 'master' into refactor-global-flags
Co-authored-by: Norwin Roosen <git@nroo.de>
Co-authored-by: 6543 <6543@obermui.de>
Reviewed-on: https://gitea.com/gitea/tea/pulls/291
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
Reviewed-by: khmarbaise <khmarbaise@noreply.gitea.io>
Reviewed-by: 6543 <6543@obermui.de>
Co-Authored-By: Norwin <noerw@noreply.gitea.io>
Co-Committed-By: Norwin <noerw@noreply.gitea.io>
drop tea mile alias
document command schema in CONTRIBUTING.md
and update this file, its a plain copy from gitea
add "list" as alias for "ls" subcommand
add singular command aliases
Co-authored-by: Norwin Roosen <git@nroo.de>
Reviewed-on: https://gitea.com/gitea/tea/pulls/208
Reviewed-by: 6543 <6543@noreply.gitea.io>
Reviewed-by: techknowlogick <techknowlogick@gitea.io>
fix lint
fix lint
Move print TrackedTimesList to print package
Move AbsPathWithExpansion to utils/path.go
rename module intern to config
Move Subcomands into it's own Packages
Split times subcomands into own sourcefiles
Split repos subcomands into own sourcefiles
Split releases subcomands into own sourcefiles
Split pulls subcomands into own sourcefiles
Split milestones subcomands into own sourcefiles
Split login subcomands into own sourcefiles
Split labels subcomands into own sourcefiles
split issues subcomands into own sourcefiles
mv
Move Interactive Login Creation to interact package
Move Add Login function to intern/login.go
apply from review
lint: add description to exported func
smal nits
Move DetailViews stdout print func to print package
Refactor:
* Move Config & Login routines into intern package
* rename global var in cmd
* Move help func to utils
Co-authored-by: 6543 <6543@obermui.de>
Reviewed-on: https://gitea.com/gitea/tea/pulls/206
Reviewed-by: Norwin <noerw@noreply.gitea.io>
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
Merge branch 'master' into pr-details
make issues & pulls subcommands consistent
- by default list open items
- show detail when argument is provided
- expose listing as ls subcommand
- accept --state flag on command and ls subcommand
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: Norwin Roosen <git@nroo.de>
Reviewed-on: https://gitea.com/gitea/tea/pulls/188
Reviewed-by: 6543 <6543@noreply.gitea.io>
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
Merge branch 'master' into issue-97/pulls-clean
vendor terminal dependency
pull/push: provide authentication method
automatically select an AuthMethod according to the
remote url type. If required, credentials are prompted for
login: store username & optional keyfile
refactor
refactor GetRemote
Merge branch 'master' into issue-97/pulls-clean
adress code review
add --ignore-sha flag
When set, the local branch is not matched against the remote sha,
but the remote branch name. This makes the command more flexible
with diverging branches.
add missing error check
fix branch-not-found case
Merge branch 'master' into issue-97/pulls-clean
use directory namespaces for branches & remotes
fix TeaCreateBranch()
improve method of TeaFindBranch()
now only checking .git/refs instead of looking up .git/config which may
not list the branch
add `tea pulls clean`
fixes#97
add copyright to new files
make linter happy
refactor: use new git functions for old code
add `tea pulls checkout`
Co-authored-by: Norwin Roosen <git@nroo.de>
Co-authored-by: Norwin <git@nroo.de>
Reviewed-on: https://gitea.com/gitea/tea/pulls/105
Reviewed-by: 6543 <6543@noreply.gitea.io>
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
Merge branch 'master' into 50-cmd-times
labels: fix refactor bug
fixup! use version check implemented in SDK instead
add subcmds: `tea times (delete|reset)`
fixes#87fixes#88
times: reword help
use version check implemented in SDK instead
make fmt
Check gitea server version for times endpoint
refactor times.go
dont print TrackedTime ID
print username & issue index instead of IDs
switch to urface/cli/v2
vendor araddon/dateparse
use araddon/dateparse for arbitrary date inputs
add --from, --until flags
allow filtering by issue index
make app name lower case
to make the help texts consistent with the binary name
add --total flag
implement `tea times add`
add `tea times` subcommand
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: Norwin Roosen <git@nroo.de>
Reviewed-on: https://gitea.com/gitea/tea/pulls/54
Reviewed-by: 6543 <6543@noreply.gitea.io>
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>