new: scaffold new Debian source packages (non-interactive core)
This commit is contained in:
+7
-1
@@ -259,7 +259,13 @@ fn prepend_to_file(path: &Path, content: &str) -> Result<(), Box<dyn std::error:
|
||||
Ok(())
|
||||
}
|
||||
|
||||
fn get_maintainer_info() -> Result<(String, String), Box<dyn std::error::Error>> {
|
||||
/// Discover the maintainer identity for changelog entries and package
|
||||
/// scaffolding: `$DEBFULLNAME`/`$DEBEMAIL` when both are set, else the git
|
||||
/// configuration (`user.name`/`user.email`).
|
||||
///
|
||||
/// Returns `(name, email)`, with a pointed error telling the user how to
|
||||
/// configure the missing piece.
|
||||
pub fn get_maintainer_info() -> Result<(String, String), Box<dyn std::error::Error>> {
|
||||
// From environment variables
|
||||
if let (Ok(name), Ok(email)) = (std::env::var("DEBFULLNAME"), std::env::var("DEBEMAIL")) {
|
||||
return Ok((name, email));
|
||||
|
||||
Reference in New Issue
Block a user