Compare commits
1 Commits
8659cb1c15
...
59fd954130
Author | SHA1 | Date | |
---|---|---|---|
|
59fd954130 |
@ -19,7 +19,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||
- don't have to use user for basic auth
|
||||
|
||||
### Other
|
||||
- removed unused code
|
||||
- move projects list into separate file
|
||||
- separate files
|
||||
- move config out
|
||||
|
@ -200,6 +200,31 @@ impl GiteaProvider {
|
||||
Ok(repos)
|
||||
}
|
||||
|
||||
// fn get_config_from_user(
|
||||
// &self,
|
||||
// api: &str,
|
||||
// user: &str,
|
||||
// access_token: Option<&GiteaAccessToken>,
|
||||
// ) -> anyhow::Result<Configuration> {
|
||||
// let mut config = gitea_rs::apis::configuration::Configuration::new();
|
||||
// config.base_path = api.into();
|
||||
// match access_token {
|
||||
// Some(GiteaAccessToken::Env { env }) => {
|
||||
// let token =
|
||||
// std::env::var(env).context(format!("{env} didn't have a valid value"))?;
|
||||
|
||||
// // config.basic_auth = Some((user.into(), Some(token)));
|
||||
// config.basic_auth = Some(("".into(), Some(token)));
|
||||
// }
|
||||
// Some(GiteaAccessToken::Direct(var)) => {
|
||||
// config.basic_auth = Some(("".into(), Some(var.to_owned())));
|
||||
// }
|
||||
// None => {}
|
||||
// }
|
||||
|
||||
// Ok(config)
|
||||
// }
|
||||
|
||||
fn get_config(
|
||||
&self,
|
||||
api: &str,
|
||||
|
Loading…
Reference in New Issue
Block a user