wget

package
v0.3.27 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 8, 2025 License: BSD-3-Clause Imports: 8 Imported by: 0

README

WGET

Uses WGET command line tool

https://linuxize.com/post/wget-command-examples/

Saving the Downloaded File Under Different Name

To save the downloaded file under a different name, pass the -O option followed by the chosen name:

wget -O latest-hugo.zip https://github.com/gohugoio/hugo/archive/master.zip

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type WgetExec

type WgetExec struct {
	// contains filtered or unexported fields
}

func NewExec

func NewExec(execPath string) *WgetExec

func (*WgetExec) Download

func (instance *WgetExec) Download(sourceURL string, target string) (response string, err error)

func (*WgetExec) DownloadBytes added in v0.3.16

func (instance *WgetExec) DownloadBytes(sourceURL string) (response []byte, err error)

func (*WgetExec) ExecuteCommand

func (instance *WgetExec) ExecuteCommand(arguments ...string) (out string, err error)

func (*WgetExec) GetPath

func (instance *WgetExec) GetPath(path string) (response string)

func (*WgetExec) Help

func (instance *WgetExec) Help() (response string, err error)

func (*WgetExec) IsInstalled

func (instance *WgetExec) IsInstalled() bool

func (*WgetExec) Root

func (instance *WgetExec) Root() string

func (*WgetExec) SetRoot

func (instance *WgetExec) SetRoot(dir string) *WgetExec

func (*WgetExec) Version

func (instance *WgetExec) Version() (response string, err error)

type WgetHelper

type WgetHelper struct {
}
var (
	Wget *WgetHelper
)

func (*WgetHelper) IsInstalled

func (instance *WgetHelper) IsInstalled() bool

func (*WgetHelper) NewExec

func (instance *WgetHelper) NewExec() *WgetExec

NewExec Creates new Git command

func (*WgetHelper) Version

func (instance *WgetHelper) Version() (version string, err error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL