nakabonne / pbgopy

Copy and paste between devices
MIT License
814 stars 30 forks source link

Using a version library to power it #31

Open LinuxSuRen opened 3 years ago

LinuxSuRen commented 3 years ago

After using this library, the version help output is:

Print the version of pbgopy

Usage:
  pbgopy version [flags]
  pbgopy version [command]

Available Commands:
  upgrade     Upgrade pbgopy itself

Flags:
  -c, --changelog     Output the changelog
  -h, --help          help for version
  -s, --show-latest   Output the latest version

Use "pbgopy version [command] --help" for more information about a command.

This is the testing output of the upgrade:

➜  pbgopy git:(ver-upgrade) ✗ pbgopy version upgrade  
prepare to upgrade to v0.3.0
start to download from https://github.com/nakabonne/pbgopy/releases/download/v0.3.0/pbgopy_0.3.0_darwin_amd64.tar.gz
Downloading:  [--------------------------------------------------------------------]   1%

As we can see above, users can upgrade it directly via: pbgopy version upgrade