feat(bindings): add Java bindings
This commit is contained in:
parent
8ca17d1bb1
commit
b9c2d1dc89
9 changed files with 369 additions and 22 deletions
|
|
@ -772,6 +772,14 @@ impl Init {
|
|||
.map(|e| Some(e.trim().to_string()))
|
||||
};
|
||||
|
||||
let namespace = || {
|
||||
Input::<String>::with_theme(&ColorfulTheme::default())
|
||||
.with_prompt("Package namespace")
|
||||
.default("io.github.tree-sitter".to_string())
|
||||
.allow_empty(true)
|
||||
.interact()
|
||||
};
|
||||
|
||||
let bindings = || {
|
||||
let languages = Bindings::default().languages();
|
||||
|
||||
|
|
@ -801,6 +809,7 @@ impl Init {
|
|||
"author",
|
||||
"email",
|
||||
"url",
|
||||
"namespace",
|
||||
"bindings",
|
||||
"exit",
|
||||
];
|
||||
|
|
@ -821,6 +830,7 @@ impl Init {
|
|||
"author" => opts.author = author()?,
|
||||
"email" => opts.email = email()?,
|
||||
"url" => opts.url = url()?,
|
||||
"namespace" => opts.namespace = Some(namespace()?),
|
||||
"bindings" => opts.bindings = bindings()?,
|
||||
"exit" => break,
|
||||
_ => unreachable!(),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue