kalvn's links
Tag cloud
Picture wall
Daily
RSS Feed
  • RSS Feed
  • Daily Feed
  • Weekly Feed
  • Monthly Feed
Filters

Links per page

  • 20 links
  • 50 links
  • 100 links

Filters

Untagged links
11 results tagged bash  ✕
Note: Running SSH Agent when starting Git Bash on Windows /shaare/OUk-hw
21/10/2022 13:55:53

Sous Windows, petit script à coller dans ~/.bashrc pour que l'agent SSH démarre lors de votre premier lancement de Git Bash et soit conservé d'un terminal à l'autre.

env=~/.ssh/agent.env

agent_load_env () { test -f "$env" && . "$env" >| /dev/null ; }

agent_start () {
    (umask 077; ssh-agent >| "$env")
    . "$env" >| /dev/null ; }

agent_load_env

# agent_run_state: 0=agent running w/ key; 1=agent w/o key; 2= agent not running
agent_run_state=$(ssh-add -l >| /dev/null 2>&1; echo $?)

if [ ! "$SSH_AUTH_SOCK" ] || [ $agent_run_state = 2 ]; then
    agent_start
    ssh-add
elif [ "$SSH_AUTH_SOCK" ] && [ $agent_run_state = 1 ]; then
    ssh-add
fi

unset env

Source

git bash ssh snippet
Note: Customisation du look de Git Bash /shaare/lggohA
18/10/2022 17:54:29

Voici ma config pour lui donner un air de Cmder.

Le fichier est à mettre dans ~/.config/git/git-prompt.sh.

PS1='\[\033]0;\w\007\]' # set window title
PS1="$PS1"'\n'                 # new line
PS1="$PS1"'\[\033[38;5;112m\]'       # change to green 256 bits
PS1="$PS1"'\w'                 # current working directory
if test -z "$WINELOADERNOEXEC"
then
    GIT_EXEC_PATH="$(git --exec-path 2>/dev/null)"
    COMPLETION_PATH="${GIT_EXEC_PATH%/libexec/git-core}"
    COMPLETION_PATH="${COMPLETION_PATH%/lib/git-core}"
    COMPLETION_PATH="$COMPLETION_PATH/share/git/completion"
    if test -f "$COMPLETION_PATH/git-prompt.sh"
    then
        . "$COMPLETION_PATH/git-completion.bash"
        . "$COMPLETION_PATH/git-prompt.sh"
        PS1="$PS1"'\[\033[36m\]'  # change color to cyan
        PS1="$PS1"'`__git_ps1`'   # bash function
    fi
fi
PS1="$PS1"'\[\033[0m\]'        # change color
PS1="$PS1"'\n'                 # new line
PS1="$PS1"'λ '                 # prompt
git bash
How To Customize GitBash For Windows | Automation Dojos https://www.automationdojos.com/how-to-customize-gitbash-for-windows/
18/10/2022 13:21:58

Comment customiser GitBash (le titre de la fenêtre, les couleurs et infos qui apparaissent avant le curseur, etc.).

git bash customisation
explainshell.com - match command-line arguments to their help text https://explainshell.com/
26/02/2021 14:37:00

Un outil pour expliquer une commande shell. La différence avec man par exemple c'est qu'ici vous pouvez coller la commande complète avec les arguments. Et à la manière des outils pour analyser les regex, l'application va décomposer la commande et vous expliquer chaque morceau.

Je ne l'ai pas essayé en détail mais ça peut clairement aider.

bash shell
bash-guide/README.md at master · Idnan/bash-guide · GitHub https://github.com/Idnan/bash-guide/blob/master/README.md
27/01/2018 18:49:29

Un guide Bash.

bash shell tuto
Trucs et Astuces pour votre terminal (bash/zsh) – Hassane Moustapha – Medium https://medium.com/@hkairi/trucs-et-astuces-pour-votre-terminal-bash-zsh-e552cc905e84
04/08/2017 09:42:39

Quelques raccourcis utiles pour le terminal.

bash terminal console raccourci astuce
ShellCheck – shell script analysis tool https://www.shellcheck.net/
30/03/2017 10:53:25

Collez votre script shell, et vous obtenez une analyse assez détaillée.

Très bon outil !

shell bash check
The Best Keyboard Shortcuts for Bash (aka the Linux and macOS Terminal) https://www.howtogeek.com/howto/ubuntu/keyboard-shortcuts-for-bash-command-shell-for-ubuntu-debian-suse-redhat-linux-etc/
20/03/2017 10:04:46

Des raccourcis clavier bien utiles pour bash.

Parmi les plus utiles, il y a notamment ceux-ci:

Ctrl+R: Recall the last command matching the characters you provide. Press this shortcut and start typing to search your bash history for a command.
Ctrl+O: Run a command you found with Ctrl+R.
Ctrl+G: Leave history searching mode without running a command.

raccourci bash
Learn X in Y Minutes: Scenic Programming Language Tours https://learnxinyminutes.com/docs/bash/
21/02/2017 12:00:59

Une sorte de cheatsheet bash.

shell bash cheatsheet
Installer le shell Bash (Linux) sous Windows 10 - Korben http://korben.info/installer-shell-bash-linux-windows-10.html
13/01/2017 16:30:30

Sous le coude pour le jour où ça sortira de beta.

tuto bash commandline windows unix
ssh - How do I tell Git for Windows where to find my private RSA key? - Server Fault http://serverfault.com/questions/194567/how-do-i-tell-git-for-windows-where-to-find-my-private-rsa-key
18/12/2015 16:40:48

Comment inclure une clé ssh privée pour que le Git Bash sous Windows en tienne compte.
En gros il faut l'exporter en OpenSSH via PUTTYGEN, renommer le fichier en id_rsa et le placer dans le HOME/.ssh/ de Git Bash.

git ssh putty bash windows
3845 links, including 129 private
Shaarli - The personal, minimalist, super fast, database-free, bookmarking service by the Shaarli community - Theme by kalvn