Code Monkey home page Code Monkey logo

http-downloader's Introduction

Gitpod ready-to-code Codacy Badge Codacy Badge Contributors GitHub release GitHub All Releases

Get started

hd is a HTTP download tool.

Install it via: brew install linuxsuren/linuxsuren/hd

Or download it directly (for Linux):

curl https://linuxsuren.github.io/tools/install.sh|sh

Or download it via proxy:

curl -L https://ghproxy.com/https://github.com/linuxsuren/http-downloader/releases/latest/download/hd-linux-amd64.tar.gz | tar xzv hd
mv hd /usr/bin/hd

Want to go through the code? GitPod definitely can help you.

Usage

Download

hd get https://github.com/jenkins-zh/jenkins-cli/releases/latest/download/jcli-linux-amd64.tar.gz --thread 6

Or use a simple way instead of typing the whole URL:

hd get jcli

Or you might want to download a pre-released binary package from GitHub:

hd get --pre ks

Install

You can also install a package from GitHub:

hd install jcli -t 6

or install by a category name:

hd install --category security

Search

hd can download or install via the format of $org/$repo. If you find that it's not working. It might because of there's no record in hd-home. You're welcome to help us to maintain it.

When you first run it, please init via: hd fetch

then you can search it by a keyword: hd search jenkins

Use multi-stage builds

Do you want to download tools in the Docker builds? It's pretty easy. Please see the following example:

FROM ghcr.io/linuxsuren/hd:v0.0.42 as downloader
RUN hd install kubesphere-sigs/[email protected]

FROM alpine:3.10
COPY --from=downloader /usr/local/bin/ks /usr/local/bin/ks
CMD ["ks"]

As a library

You can import it from github.com/linuxsuren/http-downloader/pkg/installer, then put the following code to your CLI. It can help you to download desired tools:

is := installer.Installer{
    Provider: "github",
}
if err = is.CheckDepAndInstall(map[string]string{
    "ks": "linuxsuren/ks",
    "kk": "kubekey",
}); err != nil {
    return
}

Install other services

It supports to install other services, for example: bitbucket.

hd install bitbucket

Features

  • go library for HTTP
  • multi-thread
  • continuously (TODO)
  • GitHub release asset friendly

Release

This project can be released via linuxsuren-versions.

Visitor Count

http-downloader's People

Contributors

linuxsuren avatar dependabot[bot] avatar linuxsuren-bot avatar amoghrajesh avatar johnniang avatar seanly avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.