Code Monkey home page Code Monkey logo

g's Issues

add website link to CLI help

g is such a vague command name and there is no way to find out what the tool is, even when running g --help. Please add the repo URL and possibly a description.

[question] naming of the tool - conflict with other commands

Thanks for the nice tool that support fish! Yey!

Just small feedback on the naming of the tool. Single character naming is I think not very fortunate because it might collide with user's aliases or some other utilities. In this case, I have a conflict with git aliases (https://github.com/simnalamburt/cgitc) and I can imagine there will be quiet some people who might have same problem.

Do you know if simply renaming the installed binary will break things or not?

ERROR: invalid version

Describe the bug

ERROR: invalid version

To Reproduce

g install latest

Error output

ERROR: invalid version

Environment

Please give us more info about the system you're getting issues at by running the following commands (copy & paste into your terminal and hit ENTER) and replacing the content here with the output of your terminal:

echo Architecuture: x86_64
echo Full uname: Linux Cyshall-Desktop 5.15.79.1-microsoft-standard-WSL2 #1 SMP Wed Nov 23 01:01:46 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
echo Dollar-sign zero expansion: "/usr/bin/zsh"
echo SHELL: "/usr/bin/zsh"
echo /etc/shells content:

/bin/sh
/bin/bash
/usr/bin/bash
/bin/rbash
/usr/bin/rbash
/usr/bin/sh
/bin/dash
/usr/bin/dash
/usr/bin/tmux
/usr/bin/screen
/bin/zsh
/usr/bin/zsh

echo go location: go version go1.20 linux/amd64
echo g location: /root/.go/bin/g && 0.9.1
echo GOROOT: "/root/.g/goT"
echo GOPATH: "/root/.go"


**Additional context**

Add any other context about the problem here.

Can't install versions bellow 1.4.3 on macOS

Whenever I try installing any version of Go lower than 1.5, I get the following error:

tar: Unrecognized archive format
tar: Error exit delayed from previous errors.

I believe this is because the script tries downloading from https://dl.google.com/go/go1.4.darwin-amd64.tar.gz, but if you go to https://golang.org/dl/ , there are no such links that follow the format that the script expects. It seems as if they only started following that format with 1.5 and later.

[question] ls as an alias `g list-all`

It would be great to keep the usage of g similar to n. For example, n ls lists all the available node versions, but the corresponding command in g is g list-all. Is there any reason why ?

Invalid version when install go version < 1.16 on Mac M1 Apple Silicon

Describe the bug

Can not install/download Go version below 1.16. i.e: 1.13 and 1.15

To Reproduce

Steps to reproduce the behavior:

  1. check all that avail versions using g list-all. Version 1.13 and 1.15 exist on the list.
  2. execute g install 1.13

Error output

selected: 1.13

ERROR: invalid version 1.13

Environment

Please give us more info about the system you're getting issues at by running the following commands (copy & paste into your terminal and hit ENTER) and replacing the content here with the output of your terminal:

echo Architecuture: arm64
echo Full uname: Darwin my-mac.local 21.3.0 Darwin Kernel Version 21.3.0: Wed Jan  5 21:37:58 PST 2022; root:xnu-8019.80.24~20/RELEASE_ARM64_T8101 arm64
echo Dollar-sign zero expansion: -zsh
echo SHELL: /bin/zsh
echo /etc/shells content:
# List of acceptable shells for chpass(1).
# Ftpd will not allow users to connect who are not using
# one of these shells.
/bin/bash
/bin/csh
/bin/dash
/bin/ksh
/bin/sh
/bin/tcsh
/bin/zsh

echo go location: /Users/myusername/go/bin/go
go version go1.16 darwin/arm64
echo g location: /Users/myusername/go/bin/g
0.9.0
echo GOROOT: /Users/myusername/.go
echo GOPATH:  /Users/myusername/go

Additional context

Add any other context about the problem here.

provide a flag to override dotfile_for_shell

Hi @stefanmaric thanks for this version manager.

Is it possible to provide a flag to the installer to specify the dotfile for shell.

I'm using the installer in an ansible role (https://galaxy.ansible.com/damianoneill/smg). Ansible uses a non-login shell over ssh, therefore for bash this will always select ~/.bashrc where ideally I want to update the dotfile for the login shell i.e. ~/.bash_profile.

Therefore if you could provide a way for me to overload the get_dotfile_for_shell response that would be fantastic.

Alternatively, if you have another suggestion that would be great.

Thanks,
Damian.

tmp: parameter not set

Recently, when running g self-upgrade I get the following error:

/home/[username]/go/bin/g: 748: /home/[username]/go/bin/g: tmp: parameter not set

Content of my .bashrc:

[...]
export GOPATH="$HOME/go"; export GOROOT="$HOME/.go"; export PATH="$GOPATH/bin:$PATH"; # g-install: do NOT edit, see https://github.com/stefanmaric/g

Is there anything I can add to help debugging this?

Git IO issues

I am unable to reach git.io. The download links may have to be changed

Allow installing this with the `yes` command on Linux

When installing this using a script it would be nice to be able to do the following:

wget -O g-install.sh https://git.io/g-install
sudo chmod ug+x g-install.sh
yes | ./g-install.sh

The yes command prints out "y" to the input stream of the command it is piped to. This is to prevent having to manually type "y" whilst installing g and the latest version of Go.

The yes command works with most other scripts, including the installer for n (Node version manager).

Install failed: gzip error

To Reproduce

Steps to reproduce the behavior:

  1. Install with command: curl -sSL https://git.io/g-install | sh -s
  2. Install go: g install 1.22.1

Error output

gzip: stdin: not in gzip format
tar: Child returned status 1
tar: Error is not recoverable: exiting now

Environment

Windows MSYS2 zsh

Additional context

image

Support go env as fallback for setting GOPATH and GOROOT in env

Sorry, I opened a PR without reading the contributing guidelines.

I'm proposing to support using go env as fallback for explicitly setting GOPATH and GOROOT. Go will read those values from a config file, e.g. ~/.config/go/env`, and thus setting them in the environment is not required.

GOPATH default value is wrong

Even though README says that default values are:

GOROOT: $HOME/.go
GOPATH: $HOME/go

Upon g installation, the GOPATH variable in my config.fish is set to $HOME/.go, which then mess up everything, because upon installation of any version the g binary is removed. Not sure if it is only Fish specific or affects also other shells.

When I have corrected manually this error, everything worked as expected.

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.