From 6b578a80cd53116c8344a5d413e832685fcc99e7 Mon Sep 17 00:00:00 2001 From: Chewing_Bever Date: Thu, 5 Jan 2023 13:00:18 +0100 Subject: [PATCH] refactor: rename some image functions --- images.v | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/images.v b/images.v index d879cd9..15b6861 100644 --- a/images.v +++ b/images.v @@ -12,8 +12,8 @@ pub fn (mut d DockerConn) image_inspect(image string) !Image { return data } -// pull_image pulls the given image:tag. -pub fn (mut d DockerConn) pull_image(image string, tag string) ! { +// image_pull pulls the given image:tag. +pub fn (mut d DockerConn) image_pull(image string, tag string) ! { d.request(.post, '/images/create', { 'fromImage': image 'tag': tag @@ -33,7 +33,7 @@ pub fn (mut d DockerConn) pull_image(image string, tag string) ! { } // create_image_from_container creates a new image from a container. -pub fn (mut d DockerConn) create_image_from_container(id string, repo string, tag string) !Image { +pub fn (mut d DockerConn) image_from_container(id string, repo string, tag string) !Image { d.request(.post, '/commit', { 'container': id 'repo': repo @@ -45,7 +45,7 @@ pub fn (mut d DockerConn) create_image_from_container(id string, repo string, ta } // remove_image removes the image with the given id. -pub fn (mut d DockerConn) remove_image(id string) ! { +pub fn (mut d DockerConn) image_remove(id string) ! { d.request(.delete, '/images/$id', {}) d.send()! d.read_response()!