Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/branching.rs
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ impl Context {
let mut github = self.config.github().unwrap();
let mut token = github.token("rust-lang/cargo")?;
let new_beta = future_beta_version.content()?.trim().to_owned();
token.create_ref(&format!("refs/heads/rust-{}", new_beta), &cargo_sha)?;
token.create_ref(&format!("refs/heads/rust-{new_beta}"), &cargo_sha)?;

Ok(())
}
Expand Down
2 changes: 1 addition & 1 deletion src/build_manifest.rs
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ impl<'a> BuildManifest<'a> {
fn extract(builder: &'a Context) -> Result<NamedTempFile, Error> {
let release = builder.config.channel.release_name(builder);
let tarball_name = format!("build-manifest-{}-{}", release, crate::TARGET);
let tarball_path = builder.dl_dir().join(format!("{}.tar.xz", tarball_name));
let tarball_path = builder.dl_dir().join(format!("{tarball_name}.tar.xz"));

let binary_path = Path::new(&tarball_name)
.join("build-manifest")
Expand Down
5 changes: 2 additions & 3 deletions src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -333,10 +333,9 @@ where
R: FromStr,
Error: From<R::Err>,
{
match std::env::var(format!("{}{}", ENVIRONMENT_VARIABLE_PREFIX, name)) {
match std::env::var(format!("{ENVIRONMENT_VARIABLE_PREFIX}{name}")) {
Ok(val) => Ok(Some(val.parse().map_err(Error::from).context(format!(
"the {} environment variable has invalid content",
name
"the {name} environment variable has invalid content"
))?)),
Err(VarError::NotPresent) => Ok(None),
Err(VarError::NotUnicode(_)) => {
Expand Down
2 changes: 1 addition & 1 deletion src/fastly.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ impl Fastly {
self.client.post(true)?;
self.client.url(&url)?;

println!("invalidating Fastly cache with POST '{}'", url);
println!("invalidating Fastly cache with POST '{url}'");

self.client.perform().map_err(|error| error.into())
}
Expand Down
7 changes: 3 additions & 4 deletions src/github.rs
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,7 @@ impl Github {
self.start_jwt_request()?;
self.client.get(true)?;
self.client.url(&format!(
"https://api.github.com/repos/{}/installation",
repository
"https://api.github.com/repos/{repository}/installation"
))?;
#[derive(serde::Deserialize)]
struct InstallationResponse {
Expand Down Expand Up @@ -174,7 +173,7 @@ impl RepositoryClient<'_> {
.client
.with_body(&request)
.send_with_response::<CreatedTag>()
.with_context(|| format!("tag request {:?}", request))?;
.with_context(|| format!("tag request {request:?}"))?;

self.create_ref(&format!("refs/tags/{}", tag.tag_name), &created.sha)?;

Expand Down Expand Up @@ -407,7 +406,7 @@ impl RepositoryClient<'_> {
self.client.url(&format!(
"https://api.github.com/repos/{repo}/contents/{path}{maybe_ref}",
repo = self.repo,
maybe_ref = sha.map(|s| format!("?ref={}", s)).unwrap_or_default()
maybe_ref = sha.map(|s| format!("?ref={s}")).unwrap_or_default()
))?;
self.client.without_body().send_with_response::<GitFile>()
}
Expand Down
Loading