Command Line Tool
Introduction
gz-cli
is a command line tool developed by GPUGEEK specifically for file management. This tool aims to provide users with an efficient and convenient way to manage their data on the GPUGEEK platform. With gz-cli
, users can perform various operations, including uploading, downloading, viewing file lists, and managing files.
The tool was developed based on a deep understanding of platform users' file management needs, aiming to simplify the process of accessing and storing files, and to improve efficiency when handling large amounts of data. Whether for data backup, data sharing, or daily file management, gz-cli
provides flexible command line solutions to meet a wide range of user needs.
Installation Guide
gz-cli
supports multiple operating systems. Please select the appropriate download link according to your OS.
Windows
Click to download
to a specific file directory.
For example: here I download the file to the directory: C:\gz-cli
The path of the downloaded executable file is: C:\gz-cli\gz-cli.exe
Open the Windows command prompt window. In the bottom-left search box, type cmd
, click Command Prompt
, and enter the command prompt window.
To make using the command easier, we need to set environment variables.
Note: Please replace this with the directory where your own executable file is located.
Still in the command prompt interface, enter the following command to set the environment variable, then print the command version information:
setx path "%path%;C:\"
As shown below:
Mac (x86-64)
Open terminal:
curl -o gz-cli http://oss-high-qy01.cdsgss.com/public-static-prod-gpuzoom/installation/gz-cli/latest/gz-cli-darwin-amd64
chmod +x gz-cli
sudo mv gz-cli /usr/local/bin/
Mac (Apple Silicon)
Open terminal:
curl -o gz-cli http://oss-high-qy01.cdsgss.com/public-static-prod-gpuzoom/installation/gz-cli/latest/gz-cli-darwin-arm64
chmod +x gz-cli
sudo mv gz-cli /usr/local/bin/
Linux (x86-64)
curl -o gz-cli http://oss-high-qy01.cdsgss.com/public-static-prod-gpuzoom/installation/gz-cli/latest/gz-cli-linux-amd64
chmod +x gz-cli
sudo mv gz-cli /usr/local/bin/
Linux (arm64)
curl -o gz-cli http://oss-high-qy01.cdsgss.com/public-static-prod-gpuzoom/installation/gz-cli/latest/gz-cli-linux-arm64
chmod +x gz-cli
sudo mv gz-cli /usr/local/bin/
Verify Installation
gz-cli --version
Quick Start
The following demonstration environment is Mac. If you are using Windows, please note the path differences.
Here are the basic steps for using gz-cli
to help new users get started quickly. These steps include login, uploading files, and viewing file lists.
Login:
To use
gz-cli
, you first need to log in to the GPUGEEK platform. Use the following command to log in. A demo account is provided for testing:
gz-cli login --user=135xxxxxxxx --password=123456
--user
parameter is the GPUGEEK platform login phone number.
--password
parameter is the corresponding login password.
Select the datacenter for uploading data using arrow keys
(base) ~ » gz-cli dc
? Choose a datacenter: [Use arrows to move, type to filter]
suqian-b - East China Zone 1
> qingyang-a - Northwest Zone 1【Current】
dallas-n - North America Zone 1
jinhua-a - East China Zone 6
Select the endpoint using arrow keys
When upload/download is slow, you can interrupt and switch the endpoint before retrying the data transfer.
(base) ~ » gz-cli ep
? Choose a endpoint: [Use arrows to move, type to filter]
> Origin - https://s3-qy.gpugeek.com/【Current】
BGP - https://s3-bgp-qy.gpugeek.com
Upload file to the root directory of the cloud drive:
gz-cli put ~/test.txt /
View file list in the root directory of the cloud drive:
gz-cli ls /
You can also use --help
to learn more information.
Command Details
Command | Description |
---|---|
login | Log in to GPUGEEK, using platform credentials to access the file management system. |
put | Upload objects to the cloud drive, upload local files to the specified directory. |
ls | List objects, showing the files and folders in the current directory. |
cp | Copy objects, copy files between different directories in storage. |
find | Search objects, search files in storage based on specific conditions. |
get | Download objects to local, retrieve files from remote storage to a local directory. |
mv | Move objects, change the location of files in storage. |
rm | Delete objects, remove specified files from storage. |
tree | List objects in tree format, showing a hierarchical view. |
update | Update gz-cli to the latest version, keeping the client software up to date. |
dc | List and set GPUGEEK datacenter, for selecting or changing the datacenter for data storage. |
ep | List and set GPUGEEK data transfer endpoint, switch endpoints when transfer is slow. |
logout | Log out from GPUGEEK, end the current user session. |
Common operation examples:
- List file list in the root directory
gz-cli ls /
- Copy from local to remote storage
Copy file /Users/mymacbook/Downloads/test.zip to /app
directory in remote storage:
gz-cli put /Users/mymacbook/Downloads/test.zip /app/
- Download file to local
Download test.data
from the root directory to local:
gz-cli get /test.data ./
- Delete file from remote storage
Delete test.data
in the root directory:
gz-cli rm /test.data
Version History
Below is the version update history of the gz-cli
command line tool.
1.0.0
- First release of the
gz-cli
tool. - Provided full file management commands, such as upload (
put
), download (get
), file listing (ls
), login (login
), etc. - Implemented basic file operation functions such as copy (
cp
), move (mv
), delete (rm
). - Supported tree display of cloud drive contents (
tree
) and file search (find
). - Included version update functionality (
update
) to ensure the tool stays current. - Simplified command line interface, optimizing user interaction experience.
Release date: [2024.11.18]