Code Monkey home page Code Monkey logo

gvc's Introduction


gvc QQ group:

What's GVC?

At the very beginning, GVC is just the abbreviation for Go-Version-Controller, which means, it provides auto-installation, environment variables handling, as well as multi-versions management only for Go compilers.

As we know, we already have gvm or g with the similar features implemented. So, why do we need a new one?

The reason to create GVC is for more convenience and a better UI(maybe TUI more pricisely).

However, this never becomes the end of the story. After the version-management for Go has been implemented, an idea for managing other languages flashes across my mind. Therefore, GVC starts to support version-control and auto-installation also for Java/Python/NodeJS/Flutter/Julia/Protoc/Rust/Cpp/Vlang/Typst.

At this point, GVC becomes General-Version-Controller.

And the story still continues.

Auto-installation for Visual Studio Code(VSCode) and NeoVim is adopted.The WebDAV support is also introduced for saving config files from VSCode/NeoVim to user's netdisk(eg. jianguoyun.com). So, you can rebuild your Development Environment using these files on any machine.

Besides, GVC also supports asciinema terminal recording, browser data management, counting lines of code, etc.

Finally, GVC becomes something just like a Scaffolding Tool for local development environments management.


What's supported?

Lang/App additions
go homepage go homepage cn|aliyun mirror
java/jdk homepage java/jdk cn
maven homepage maven downloads
gradle homepage gradle releases
python homepage pyenv|pyenv-win
nodejs homepage nodejs versions
rust homepage rust homepage cn
Cygwin homepage Cygwin installation
Msys2 homepage Msys2 tsinghua mirror
vcpkg-tool vcpkg
julia homepage julia community cn
vlang homepage vlang github
typst homepage typst github
flutter homepage flutter nju mirror
vscode homepage vscode cdn acceleration
NeoVim homepage NeoVim github
Homebrew homepage Homebrew shell script
Browser data management Browser data management github
neobox vpns sing-box|xray-core|wgcf
github hosts file github hosts file
asciinema asciinema for full-platform
count lines of code(cloc) cloc
protobuf protoc-go-gen
docker-for-windows docker-for-MacOS
git command using a local proxy go-git
openai go-openai
Iflytek spark-api

Download & Install

  • Download the latest release.

  • Unzip, double click the executable file, or run executable file in Terminal/PowerShell.

  • Open a new Terminal/PowerShell, then the command g is available. Help info will be displayed using 'g help'.

  • Or install by go install

go install -tags "with_wireguard with_shadowsocksr with_utls with_gvisor with_grpc with_ech with_dhcp" github.com/moqsien/gvc@latest

Main features

GVC is a command-line tool, use "g help" or "gvc help", to see help info.

$moqsien> g help

NAME:
   g.exe - gvc <Command> <SubCommand>...

USAGE:
   g.exe [global options] command [command options] [arguments...]

DESCRIPTION:
   A productive tool to manage your development environment.

COMMANDS:
   go, g                                            Go version management.
   proto, protobuf, protoc, pt                      Protoc installation.
   python, py                                       Python version management.
   java, jdk, j                                     Java jdk version management.
   maven, mav, ma                                   Maven version management.
   gradle, gra, gr                                  Gradle version management.
   nodejs, node, no                                 NodeJS version management.
   flutter, flu, fl                                 Flutter version management.
   julia, jul, ju                                   Julia version management.
   rust, rustc, ru, r                               Rust installation.
   cpp                                              C/C++ management.
   typst, ty                                        Typst installation.
   vlang, vl                                        Vlang installation.
   vscode, vsc, vs, v                               VSCode and extensions installation.
   nvim, neovim, nv, n                              Neovim installation.
   gpt-spark, gpt, gspark                           ChatGPT/Spark bot.
   neobox-shell, shell, box, ns                     Start a neobox shell.
   neobox-runner, nbrunner, nbr                     Start a neobox client.
   neobox-keeper, nbkeeper, nbk                     Start a neobox keeper.
   browser, br                                      Browser data management.
   homebrew, brew, hb                               Homebrew installation or update.
   gsudo, winsudo, gs, ws                           Gsudo for windows.
   hosts, h, host                                   Sytem hosts file management(need admistrator or root).
   git-set-proxy, gsproxy, gsp                      Set default proxy for git [default: http://localhost:2023].
   git-clone, gclone, gclo                          Git Clone using a proxy.
   git-pull, gpull, gpul                            Git Pull using a proxy.
   git-push, gpush, gpus                            Git Push using a proxy.
   git-commit-push, gcpush, gcp                     Git commit and push to remote using a proxy.
   git-add-tag-push, gaddtag, gatag, gat            Git add a new tag and push to remote using a proxy.
   git-del-tag-push, gdeltag, gdtag, gdt            Git delete a tag and push to remote using a proxy.
   git-show-tag-latest, gshowtaglatest, gstag, gst  Git show the latest tag of a local repository.
   win-git-install, wgit, wgi                       Install git for windows.
   github, gh                                       Github download speedup.
   cloc, cl                                         Count lines of code.
   asciinema, ascii, asc                            Asciinema terminal recorder.
   docker, dck, dock                                Docker installation.
   config, conf, cnf, c                             Config file management for gvc.
   ssh-files, sshf, ssh                             Backup your ssh files.
   version, ver, vsi                                Show gvc version info.
   check, checklatest, checkupdate                  Check and download the latest version of gvc.
   show, sho, sh                                    Show [gvc] installation path and config file path.
   uninstall, unins, delete, del                    [Caution] Remove gvc and softwares installed by gvc!
   help, h                                          Shows a list of commands or help for one command

GLOBAL OPTIONS:
   --help, -h  show help
$moqsien> g version
      Name: GVC
      Version: v1.5.7(c7d768d9)
      UpdateAt: Tue Sep 26 13:14:49 2023 +0800
      Homepage: https://github.com/moqsien/gvc
      Email: [email protected]

Subcommand: gpt

$moqsien> g gpt help

NAME:
   g.exe gpt-spark - ChatGPT/Spark bot.

USAGE:
   g.exe gpt-spark [command options] [arguments...]

OPTIONS:
   --help, -h  show help

A TUI client for ChatGPT and Spark.

Subcommand: go

$moqsien> g go help

NAME:
   g.exe go - Go version management.

USAGE:
   g.exe go command [command options] [arguments...]

COMMANDS:
   remote, r                                Show remote versions.
   use, u                                   Download and use version.
   local, l                                 Show installed versions.
   remove-unused, ru                        Remove unused versions.
   remove-version, rm                       Remove a version.
   add-envs, env, e, ae                     Add envs for go.
   search-package, sp, search               Search for third-party packages.
   build, bui, b                            Compiles go code for multi-platforms [with <-ldflags "-s -w"> builtin].
   renameTo, rnt, rto                       Rename a local go module[gvc go rto NEW_MODULE_NAME].
   list-distributions, list-dist, dist, ld  List the platforms supported by go compilers.
   help, h                                  Shows a list of commands or help for one command

OPTIONS:
   --help, -h  show help

In this subcommand, you can show/install/remove/change go compiler versions, search third-party packages written in Go, and build Go source code for multi-platforms without prepare any scripts. You can also rename a local go module using subcommand: g go rto NEW_MODULE_NAME.

Subcommand: proto

$moqsien> g proto help

NAME:
   g.exe proto - Protoc installation.

USAGE:
   g.exe proto command [command options] [arguments...]

COMMANDS:
   install, ins, i                  Install protoc.
   install-go-plugin, igo, ig       Install protoc-gen-go.
   install-grpc-plugin, igrpc, igr  Install protoc-gen-go-grpc.
   help, h                          Shows a list of commands or help for one command

OPTIONS:
   --help, -h  show help

In this subcommand, you can auto-install protoc, protoc-gen-go and protoc-gen-go-grpc.

Subcommand: python

$moqsien> g python help

NAME:
   g.exe python - Python version management.

USAGE:
   g.exe python command [command options] [arguments...]

COMMANDS:
   remote, r           Show remote versions.
   use, u              Download and use a version.
   local, l            Show installed versions.
   remove-version, rm  Remove a version.
   update, up          Install or update pyenv.
   path, pth           Show pyenv versions path.
   rmfix, rfix         Automatically remove python.exe generated by Windows system in ~/AppData/Local/Microsoft/WindowsApps .
   help, h             Shows a list of commands or help for one command

OPTIONS:
   --help, -h  show help

This subcommand benifits a lot from pyenv/pyenv-win.

Subcommand: java

$moqsien> g java help

NAME:
   g.exe java - Java jdk version management.

USAGE:
   g.exe java command [command options] [arguments...]

COMMANDS:
   use, u                  Download and use jdk. <Command> {gvc jdk use [-z] xxx}
   remote, r               Show available versions.  <Command> {gvc jdk remote [-z]}
   local, l                Show installed versions.
   remove, rm              Remove an installed version.
   remove-unused, rmu, ru  Remove unused versions.
   help, h                 Shows a list of commands or help for one command

OPTIONS:
   --help, -h  show help

In this subcommand, the option "-z" if for users in China.

Subcommand: cpp

$moqsien> g cpp help

NAME:
   g.exe cpp - C/C++ management.

USAGE:
   g.exe cpp command [command options] [arguments...]

COMMANDS:
   install-msys2, insm, im                Install the latest msys2.
   uninstall-msys2, unim, um, remove, rm  Uninstall msys2.
   install-cygwin, insc, ic               Install Cygwin.
   install-vcpkg, insv, iv                Install vcpkg.
   help, h                                Shows a list of commands or help for one command

OPTIONS:
   --help, -h  show help

This subcommand is for Windows users. It will install Msys2 or Cygwin, just to your preference. You can also install the Cpp-package-manager vcpkg maintained by Microsoft.

Subcommand: vlang

$moqsien> g vlang help

NAME:
   g.exe vlang - Vlang installation.

USAGE:
   g.exe vlang command [command options] [arguments...]

COMMANDS:
   install, ins, i             Install Vlang.
   install-analyzer, insa, ia  Install v-analyzer and related extension for vscode.
   setenv, env, se, e          Set env for Vlang.
   help, h                     Shows a list of commands or help for one command

OPTIONS:
   --help, -h  show help

Vlang is a fantastic new language with high performance. This subcommand will install or update to the latest version of Vlang. You can also install v-analyser, which brings vlang the code completion/IntelliSense/go to definition features for VSCode and other editors. If you have VSCode installed, this subcommand will automatically install related extensions and config the settings for you.

Subcommand: vscode

$moqsien> g vscode help

NAME:
   g.exe vscode - VSCode and extensions installation.

USAGE:
   g.exe vscode command [command options] [arguments...]

COMMANDS:
   install, i, ins                    Automatically install vscode.
   install-extensions, ie, iext       Automatically install extensions for vscode.
   use-msys2-cygwin-git, use-git, ug  Repair and make use of git.exe from Msys2/Cygwin.
   help, h                            Shows a list of commands or help for one command

OPTIONS:
   --help, -h  show help

This subcommand will install VSCode for you. You can also install extensions using the extension-info-files saved to WebDAV by GVC. An adapter for git tools in Msys2/Cygwin to VSCode usage is available in this subcommand. You can easily make use of the git tool from either Msys2 or Cygwin in VSCode.

Subcommand: hosts

$moqsien> g hosts help

NAME:
   g.exe hosts - Sytem hosts file management(need admistrator or root).

USAGE:
   g.exe hosts command [command options] [arguments...]

COMMANDS:
   fetch, f  Fetch github hosts info.
   show, s   Show hosts file path.
   help, h   Shows a list of commands or help for one command

OPTIONS:
   --help, -h  show help

This subcommand will automatically update the hosts file. Main purpose of this subcommand is to speedup visits to github, microsoft, steam, etc.

Subcommand: github

$moqsien> g github help

NAME:
   g.exe github - Github download speedup.

USAGE:
   g.exe github command [command options] [arguments...]

COMMANDS:
   download, dl, d        Download files from github project.
   openbrowser, open, ob  Open acceleration website in browser.
   help, h                Shows a list of commands or help for one command

OPTIONS:
   --help, -h  show help

This subcommand speedups github downloadings in China.

Subcommand: git-XXX

$moqsien> g help
...
git-clone, gclone, gclo                Git Clone using a proxy.
git-pull, gpull, gpul                  Git Pull using a proxy.
git-push, gpush, gpus                  Git Push using a proxy.
git-commit-push, gcpush, gcp           Git commit and push to remote using a proxy.
git-add-tag-push, gaddtag, gatag, gat  Git add a new tag and push to remote using a proxy.
git-del-tag-push, gdeltag, gdtag, gdt  Git delete a tag and push to remote using a proxy.
...

These subcommands will accelerate your git command by using a proxy. Note that, they will use "http://localhost:2023" provided by neobox if you haven't specified one.

Subcommand: browser

$moqsien> g browser help

NAME:
   g.exe browser - Browser data management.

USAGE:
   g.exe browser command [command options] [arguments...]

COMMANDS:
   show-info, show, sh  Show supported browsers and data restore dir.
   push, psh, pu        Push browser Bookmarks/Password/ExtensionInfo to webdav.
   save, sa, s          Save browser Bookmarks/Password/ExtensionInfo to local dir.
   pull, pul, pl        Pull browser data from webdav to local dir.
   help, h              Shows a list of commands or help for one command

OPTIONS:
   --help, -h  show help

This subcommand handles browser data, save data to WebDAV.

Subcommand: asciinema

$moqsien> g asciinema help

NAME:
   g.exe asciinema - Asciinema terminal recorder.

USAGE:
   g.exe asciinema command [command options] [arguments...]

COMMANDS:
   record, rec, r  Record terminal operations.
   play, pl, p     Play local asciinema file.
   auth, au, a     Bind local install-id to your asciinem.org account.
   upload, up, u   Upload local asciinema file to asciinema.org.
   help, h         Shows a list of commands or help for one command

OPTIONS:
   --help, -h  show help

This subcommand provides terminal recording features for both Powershell and Unix-Like Shells.

Subcommand: cloc

$moqsien> g cloc help

NAME:
   g.exe cloc - Count lines of code.

USAGE:
   g.exe cloc [command options] [arguments...]

OPTIONS:
   --by-file, --bf                                    Report results for every encountered source file. (default: false)
   --debug, --de, -d                                  Dump debug log for developer. (default: false)
   --skip-duplicated, --skipdup, --sd                 Skip duplicated files. (default: false)
   --show-lang, --shlang, --sl                        Print about all languages and extensions. (default: false)
   --sort-tag value, --sort value, --st value         Sort based on a certain column["name", "files", "blank", "comment", "code"]. (default: "name")
   --output-type value, --output value, --ot value    Output type [values: default,cloc-xml,sloccount,json]. (default: "default")
   --exclude-ext value, --excl value, --ee value      Exclude file name extensions (separated commas).
   --include-lang value, --langs value, --il value    Include language name (separated commas).
   --match value, --mat value, -m value               Include file name (regex).
   --not-match value, --nmat value, --nm value        Exclude file name (regex).
   --match-dir value, --matd value, --md value        Include dir name (regex).
   --not-match-dir value, --nmatd value, --nmd value  Exclude dir name (regex).
   --help, -h                                         show help

This subcommand provides CLOC(Count Lines of Code) features.

Subcommand: config

$moqsien> g config help

NAME:
   g.exe config - Config file management for gvc.

USAGE:
   g.exe config command [command options] [arguments...]

COMMANDS:
   webdav, dav, w  Setup webdav account info.
   pull, pl        Pull settings from remote webdav and apply them to applications.
   push, ph        Gather settings from applications and sync them to remote webdav.
   reset, rs, r    Reset the gvc config file to default values.
   help, h         Shows a list of commands or help for one command

OPTIONS:
   --help, -h  show help

The subcommand webdav will interactively direct you to configure your WebDAV Account info and secrets for encrytion of browser data. The subcommand push and pull will interact with remote WebDAV. The subcommand reset will reset gvc-config-files to default values.

Subcommand: neobox-shell

PS C:\Users\moqsien> g neobox-shell help
NAME:
   g.exe neobox-shell - Start a neobox shell.

USAGE:
   g.exe neobox-shell [command options] [arguments...]

OPTIONS:
   --help, -h  show help

This subcommand will start the neobox-shell. neobox provides some available free VPNs for user.

Supported command in neobox-shell

>>> help

Commands:
  add            Add proxies to neobox mannually.
  added          Add edgetunnel proxies to neobox.
  cfip           Test speed for cloudflare IPv4s.
  clear          clear the screen
  dedge          Download rawList for a specified edgeTunnel proxy [dedge proxy_index].
  domain         Download selected domains file for edgeTunnels.
  exit           exit the program
  filter         Start filtering proxies by verifier manually.
  gc             Start GC manually.
  geoinfo        Install/Update geoip&geosite for neobox client.
  graw           Manually dowload rawUri list(conf.txt from gitlab) for neobox client.
  guuid          Generate UUIDs.
  help           display help
  parse          Parse rawUri of a proxy to xray-core/sing-box outbound string [xray-core by default].
  pingd          Ping selected domains for edgeTunnels.
  qcode          Generate QRCode for a chosen proxy. [qcode proxy_index]
  remove         Remove a manually added proxy [manually or edgetunnel].
  restart        Restart the running neobox client with a chosen proxy. [restart proxy_index]
  setkey         Setup rawlist encrytion key for neobox. [With no args will set key to default value]
  setping        Setup ping without root for Linux.
  show           Show neobox info.
  start          Start a neobox client/keeper.
  stop           Stop neobox client.
  sys-proxy      To enable or disable System Proxy.
  wireguard      Register wireguard account and update licenseKey to Warp+ [if a licenseKey is specified].

Note: You should read the docs for neobox. For details, please see neobox.


special statement

gvc provides no paid services, so, users should make use of it within the limits permitted by law in his/her country.


Demo

  • gvc installation asciicast

  • go version management. asciicast

  • neobox free vpns. asciicast

  • vscode installation, and vscode extensions installation asciicast

thanks to


buy me a coffee

wechat alipay

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.