diff options
| author | nsfisis <nsfisis@gmail.com> | 2025-04-27 23:23:25 +0900 |
|---|---|---|
| committer | nsfisis <nsfisis@gmail.com> | 2025-04-27 23:24:17 +0900 |
| commit | 531820f3d60a301751c41d0aac5bbf5615f677b1 (patch) | |
| tree | d178e7878ca2d8049388182e2fbabf1c273fa364 /cmd/root.go | |
| parent | f42703288ce166381febfe8bcdc01c412f414772 (diff) | |
| download | term-clock-531820f3d60a301751c41d0aac5bbf5615f677b1.tar.gz term-clock-531820f3d60a301751c41d0aac5bbf5615f677b1.tar.zst term-clock-531820f3d60a301751c41d0aac5bbf5615f677b1.zip | |
feat: run "clock" subcommand if no subcommand is givenv1.0.0
Diffstat (limited to 'cmd/root.go')
| -rw-r--r-- | cmd/root.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/cmd/root.go b/cmd/root.go index 3efadab..5a91eae 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -7,6 +7,10 @@ import ( var rootCmd = &cobra.Command{ Use: "term-clock", Short: "A clock on your terminal", + // Run 'clock' subcommand by default. + Run: func(cmd *cobra.Command, args []string) { + clockCmd.Run(cmd, args) + }, } func init() { |
