Documentation
¶
Overview ¶
Copyright © 2024 NAME HERE <EMAIL ADDRESS>
Copyright © 2024 NAME HERE <EMAIL ADDRESS>
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var CommitCmd = &cobra.Command{ Use: "commit <group>", Short: "Commit udpated diary records to history", Long: ``, SilenceUsage: true, RunE: func(cmd *cobra.Command, args []string) error { if len(args) != 1 { return mmerr.NewArgsError( mmerr.DiaryCmdType, fmt.Sprintf("accepts 1 args, received %d", len(args)), ) } group := args[0] model, err := tui.InitCommitDiaryModel(group) if err != nil { return fmt.Errorf("diary commit sub-command failed: %w", err) } if _, err := tea.NewProgram(model, tea.WithAltScreen()).Run(); err != nil { return fmt.Errorf("diary commit sub-command failed: %w", err) } return nil }, }
commitCmd represents the commit command
View Source
var DiaryCmd = &cobra.Command{ Use: "diary <group> <plugin>", Short: "Show notes of resources in a group", Long: ``, SilenceUsage: true, RunE: func(cmd *cobra.Command, args []string) error { if len(args) != 2 { return mmerr.NewArgsError( mmerr.DiaryCmdType, fmt.Sprintf("accepts 2 args, received %d", len(args)), ) } group := args[0] plugin := args[1] model, err := tui.InitDiaryModel(group, plugin) if err != nil { return fmt.Errorf("diary sub-command failed: %w", err) } if _, err := tea.NewProgram(model, tea.WithAltScreen()).Run(); err != nil { return fmt.Errorf("diary sub-command failed: %w", err) } return nil }, }
diaryCmd represents the diary command
Functions ¶
This section is empty.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.