Giter Site home page Giter Site logo

Easier install about git-radar HOT 23 OPEN

michaeldfallen avatar michaeldfallen commented on July 20, 2024
Easier install

from git-radar.

Comments (23)

emirozer avatar emirozer commented on July 20, 2024

+1

from git-radar.

codelitt avatar codelitt commented on July 20, 2024

+1

from git-radar.

michaeldfallen avatar michaeldfallen commented on July 20, 2024

Awesome, thanks for the suggestion. As I work mostly on mac when I release something that's usually my first port of call. Sorry about that.

Would this assume that the PS1 set in the .git-radar.bashrc file you propose would augment the existing PS1? Something like:

export PS1="$PS1$(render-radar)"

Just trying to think through how this hangs together. It's definitely something I'm interested in doing, especially since I'm switching soon off Mac (sore wrists from the crappy keyboards).

from git-radar.

michaeldfallen avatar michaeldfallen commented on July 20, 2024

👍

from git-radar.

TinOo512 avatar TinOo512 commented on July 20, 2024

+1

from git-radar.

Fuxy22 avatar Fuxy22 commented on July 20, 2024

👍 Wish there was a fast and easy way to install in Linux to.

from git-radar.

DanielJonesEB avatar DanielJonesEB commented on July 20, 2024

+1, not least of all to get this working on Bash in MinGW on Windows.

from git-radar.

paddykontschak avatar paddykontschak commented on July 20, 2024

+1

from git-radar.

jdutriaux avatar jdutriaux commented on July 20, 2024

👍 for easy install on Linux. (Particularly for zsh)

from git-radar.

jackmaney avatar jackmaney commented on July 20, 2024

👍

from git-radar.

hallzy avatar hallzy commented on July 20, 2024

+1

from git-radar.

otoolep avatar otoolep commented on July 20, 2024

+1

Interesting project, but yeah, I ain't going to mess with my existing git setup without explicit directions on installing on Linux. Suggested instructions for Linux could act as a guide.

from git-radar.

hallzy avatar hallzy commented on July 20, 2024

What I was able to is clone this repo, add the git-radar executable to a bin (some directory like /bin or something you have added to your path), and add that export command that is in the readme of this repo to my bashrc and that seems to have made it work on ubuntu.

As per issue #16 I did need to make that quick fix given by dbrown, but we should not need that soon as it seems that issue should be resolved once the pull request is merged.

from git-radar.

marcvangend avatar marcvangend commented on July 20, 2024

Great to see you're working on this, I'd love to give git-radar a try on Linux.

from git-radar.

jart avatar jart commented on July 20, 2024

@michaeldfallen No I would propose the .git-radar.bashrc replace the existing PS1 entirely. If someone installs your script, they've given you permission to replace their bash prompt. If they want their own prefix, they can add it in their own .bashrc after your script is sourced. Also embedding the override in the file itself also makes it easier for people to upgrade.

from git-radar.

marcvangend avatar marcvangend commented on July 20, 2024

@jart I wouldn't be so sure. Someone may have committed to the git-radar prompt for git-controlled directories, but what if you want to include something similar for bzr-controlled directories, for instance? IMHO users should be able to add the git-radar output to the prompt the way he/she wants to.

from git-radar.

jart avatar jart commented on July 20, 2024

@marcvangend Then they would just say in their .bashrc:

source ~/.git-radar.bashrc
PS1="rofl bzr $PS1"

from git-radar.

sargas avatar sargas commented on July 20, 2024

Have you guys realized that parts of git-radar doesn't pass existing tests under Linux? The first priority should be getting the tests to pass on a GNU userland. As of right now, the code uses BSD touch and stat options that probably break the auto-fetching capability (and makes some wrong assumptions about padding).

@jart 👎 to overriding PS1. I'm trying to picture how this would work in oh-my-zsh:

source ~/.git-radar.zshrc
git_radar_prompt=$PROMPT
source $ZSH/oh-my-zsh.sh
export PROMPT="$PROMPT$git_radar_prompt"

As opposed to:

source ~/.git-radar.sh
source $ZSH/oh-my-zsh.sh
export PROMPT="$PROMPT$(git-radar --zsh --fetch)"

where git-radar is now a shell function and .git-radar.sh is a generated file that works in zsh or bash (although the option to the function would still control what control characters are outputted)

or a simple:

source $ZSH/oh-my-zsh.sh
export PROMPT="$PROMPT$(git-radar --zsh --fetch)"

where git-radar is just a self-contained program from cat-ing the existing git-radar and radar-base.sh files, with prompt.* turned into shell functions in radar-base.sh

And what is the motivation for the sed line in your example instructions? It'll give anyone who already has source ~/.git-radar.bashrc in their ~/.bashrc an error on shell startup.

from git-radar.

mtyurt avatar mtyurt commented on July 20, 2024

Is there any official instruction to install on Linux? I couldn't manage to do it, I'm a shame to my father...

from git-radar.

cbandera avatar cbandera commented on July 20, 2024

@mtyurt There are no "official" instructions. But I just symlinked the git-radar executable into /usr/local/bin and added the export PS1... line into my .bashrc

from git-radar.

oceatoon avatar oceatoon commented on July 20, 2024

+1 to make simple linux install instructions

from git-radar.

vladimir-1980 avatar vladimir-1980 commented on July 20, 2024

👍

from git-radar.

kain88-de avatar kain88-de commented on July 20, 2024

Solved by #51

from git-radar.

Related Issues (20)

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.