Relates to #22, but adds in all the necessary flags. I tested it manually with some scripting and it works as intended.
Signed-off-by: Sienna Lloyd <sienna@linux.com>
Co-authored-by: techknowlogick <techknowlogick@gitea.com>
Reviewed-on: https://gitea.com/gitea/tea/pulls/587
Reviewed-by: techknowlogick <techknowlogick@noreply.gitea.com>
Co-authored-by: Sienna Lloyd <sienna@linux.com>
Co-committed-by: Sienna Lloyd <sienna@linux.com>
I went with a new subcommand instead of `tea repo create --template`, as the options are quite different (bool instead of values, partially different set)
fixes#362
Co-authored-by: Norwin <git@nroo.de>
Reviewed-on: https://gitea.com/gitea/tea/pulls/408
Reviewed-by: Andrew Thornton <art27@cantab.net>
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: Norwin <noerw@noreply.gitea.io>
Co-committed-by: Norwin <noerw@noreply.gitea.io>
Adds a new subcommand to fork repos.
To specify the repo to fork, use the `--repo` flag. This feels a bit weird, other tea commands would put this as the first argument.
I decided to follow the flag style, as this is what all other subcommands of `tea repo` do. We might want to reconsider and make the primary subject of such commands an argument, instead of an required flag.. see #430
Co-authored-by: Norwin <git@nroo.de>
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
Reviewed-on: https://gitea.com/gitea/tea/pulls/410
Reviewed-by: techknowlogick <techknowlogick@gitea.io>
Reviewed-by: Andrew Thornton <art27@cantab.net>
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>
split modules/config
login_tasks.go should probably be modules/task/login.go,
but i didn't do that, as it still depends on the global
`Config` variable from the config module, see
https://gitea.com/gitea/tea/issues/158
rework InitCommand()
- make it error tolerant if $PWD is not a git repo (#200)
- don't force default login when repo flag is set (#191)
remove InitCommandLoginOnly()
Merge branch 'master' into issue-200-initcommand
improve docs
Merge branch 'master' into issue-200-initcommand
move config func and config task func to right place
Co-authored-by: Norwin Roosen <git@nroo.de>
Co-authored-by: 6543 <6543@obermui.de>
Reviewed-on: https://gitea.com/gitea/tea/pulls/285
Reviewed-by: 6543 <6543@obermui.de>
Reviewed-by: khmarbaise <khmarbaise@noreply.gitea.io>
Co-Authored-By: Norwin <noerw@noreply.gitea.io>
Co-Committed-By: Norwin <noerw@noreply.gitea.io>
Merge branch 'master' into add-repo-search-improve-listing-closes-#210
Merge branch 'master' into add-repo-search-improve-listing-closes-#210
fixup! repos list: client side filtering for repo type
fix --private flag
repos list: client side filtering for repo type
repos list: listing of starred repos
repos search: rename --mode to --type
repo search: prioritize own user
UX tradeoff between usefulness & response speed
fix -O owner flag filter
rework repo list, add repo search
repo search is mostly the old behaviour of repo list
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: Norwin Roosen <git@nroo.de>
Reviewed-on: https://gitea.com/gitea/tea/pulls/215
Reviewed-by: 6543 <6543@noreply.gitea.io>
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
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>
simplify NormalizeURL
drop noisy log line
must have been introduced recently?
dont use PascalCase for default login names
...for readability.
🔥 opinionated commit
create GenerateLoginName()
fixes
fixup! Merge branch 'master' into refactor-loginMain
move GetOwnerAndRepo() to modules/utils/parse.go
Merge branch 'master' into refactor-loginMain
make linter happy
refactor addLoginMain()
Co-authored-by: Norwin Roosen <git@nroo.de>
Reviewed-on: https://gitea.com/gitea/tea/pulls/201
Reviewed-by: 6543 <6543@noreply.gitea.io>
Reviewed-by: Andrew Thornton <art27@cantab.net>
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>
repos ls: use owner filter and remove org&user one
better desc
refactor
rm local filter, let us fix upstream
split user org
add archive and private filters
use SearchRepos
migrate to sdk v0.13.0
print URL
add CmdRepoCreate,
Add RepoDetails
ListRepos: better desc, add aliases, add note for sdk-release
Co-authored-by: 6543 <6543@obermui.de>
Reviewed-on: https://gitea.com/gitea/tea/pulls/173
Reviewed-by: Andrew Thornton <art27@cantab.net>
Reviewed-by: Norwin <noerw@noreply.gitea.io>