Skip to content

Commit

Permalink
Update main.rs
Browse files Browse the repository at this point in the history
  • Loading branch information
Joker666 committed Jul 9, 2024
1 parent df2f091 commit a124cd8
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/main.rs
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
mod server_config;
mod container;
mod deploy;
mod git;
mod logger;
mod misc;
mod model;
mod server_config;

use std::env;
use std::path::Path;

use crate::git::Git;
use bollard::Docker;
use clap::{Parser, Subcommand};
use container::Container;
Expand Down Expand Up @@ -107,6 +108,8 @@ async fn main() {
std::process::exit(1);
});

let git = Git::new(&server_config);

let app_name = config
.name
.as_deref()
Expand Down Expand Up @@ -153,12 +156,15 @@ async fn main() {
}
Commands::GitHook { repo } => {
println!("Running git hook for {}", repo);
git.cmd_git_hook(repo).unwrap();
}
Commands::GitReceivePack { repo } => {
println!("Running git receive pack for {}", repo);
git.cmd_git_receive_pack(repo).unwrap();
}
Commands::GitUploadPack { repo } => {
println!("Running git upload pack for {}", repo);
git.cmd_git_upload_pack(repo).unwrap();
}
}
}
Expand Down

0 comments on commit a124cd8

Please sign in to comment.