mirror of
https://github.com/chshersh/github-tui.git
synced 2024-09-11 18:37:56 +03:00
WIP: Add CLI
This commit is contained in:
parent
e9d760cf39
commit
06f9cf2b45
@ -17,4 +17,4 @@ query {
|
|||||||
|}
|
|}
|
||||||
*)
|
*)
|
||||||
|
|
||||||
let () = Github_tui.Tui.start ()
|
let () = Github_tui.Main.main ()
|
10
dune-project
10
dune-project
@ -17,11 +17,13 @@
|
|||||||
(synopsis "A short synopsis")
|
(synopsis "A short synopsis")
|
||||||
(description "A longer description")
|
(description "A longer description")
|
||||||
(depends
|
(depends
|
||||||
ocaml
|
(ocaml (>= "5.1"))
|
||||||
dune
|
dune
|
||||||
ezcurl
|
(core (>= "v0.16.2"))
|
||||||
minttea
|
(core_unix (>= "v0.16.0"))
|
||||||
terminal
|
(ezcurl (>= "0.2.4"))
|
||||||
|
(minttea (>= "0.0.2"))
|
||||||
|
(ppx_jane (>= "v0.16.0"))
|
||||||
)
|
)
|
||||||
(tags
|
(tags
|
||||||
(tui cli git github)))
|
(tui cli git github)))
|
||||||
|
@ -9,11 +9,13 @@ tags: ["tui" "cli" "git" "github"]
|
|||||||
homepage: "https://github.com/chshersh/github-tui"
|
homepage: "https://github.com/chshersh/github-tui"
|
||||||
bug-reports: "https://github.com/chshersh/github-tui/issues"
|
bug-reports: "https://github.com/chshersh/github-tui/issues"
|
||||||
depends: [
|
depends: [
|
||||||
"ocaml"
|
"ocaml" {>= "5.1"}
|
||||||
"dune" {>= "3.12"}
|
"dune" {>= "3.12"}
|
||||||
"ezcurl"
|
"core" {>= "v0.16.2"}
|
||||||
"minttea"
|
"core_unix" {>= "v0.16.0"}
|
||||||
"terminal"
|
"ezcurl" {>= "0.2.4"}
|
||||||
|
"minttea" {>= "0.0.2"}
|
||||||
|
"ppx_jane" {>= "v0.16.0"}
|
||||||
"odoc" {with-doc}
|
"odoc" {with-doc}
|
||||||
]
|
]
|
||||||
build: [
|
build: [
|
||||||
|
10
lib/cli.ml
Normal file
10
lib/cli.ml
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
open Core
|
||||||
|
|
||||||
|
let repo_param =
|
||||||
|
let open Command.Param in
|
||||||
|
anon ("owner/repo" %: string)
|
||||||
|
|
||||||
|
let command =
|
||||||
|
Command.basic
|
||||||
|
~summary:"Display GitHub TUI for the selected repository"
|
||||||
|
(Command.Param.map repo_param ~f:(fun _repo () -> Tui.start ()))
|
6
lib/dune
6
lib/dune
@ -3,8 +3,12 @@
|
|||||||
(library
|
(library
|
||||||
(name github_tui)
|
(name github_tui)
|
||||||
(libraries
|
(libraries
|
||||||
|
core
|
||||||
|
core_unix.command_unix
|
||||||
ezcurl
|
ezcurl
|
||||||
minttea
|
minttea
|
||||||
terminal
|
)
|
||||||
|
(preprocess
|
||||||
|
(pps ppx_jane)
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
1
lib/main.ml
Normal file
1
lib/main.ml
Normal file
@ -0,0 +1 @@
|
|||||||
|
let main () = Command_unix.run ~version:"0.1.0" ~build_info:"RWO" Cli.command
|
Loading…
Reference in New Issue
Block a user