Questions tagged [posh-git]

A PowerShell environment for Git, providing prompt status, tab expansion, and helpful functions.

posh-git is PowerShell module that provides support for Git similar to what is provided by default with Git Bash. Details at https://github.com/dahlbyk/posh-git

83 questions
5
votes
2 answers

How to get my cursor on a new line after the highlight line of OhMyPosh theme?

I want the cursor to be on a new line currently it is on the same line as the highlight line. I have tried adding "newline" : true, but it didn't work. How can I resolve it ?
Shashank KR
  • 83
  • 1
  • 9
5
votes
1 answer

Trouble installing posh-git

I want to install posh-git on laptop but when I try installing w/command "PowerShellGet\Install-Module posh-git -Scope CurrentUser -AllowPrerelease -Force" I get error: Install-Module : A parameter cannot be found that matches parameter…
Alan
  • 1,067
  • 1
  • 23
  • 37
5
votes
3 answers

git blame throws a bad revision error with the -L option

One of the git blame options processes a line range. The manual says: -L Process only line range n,m, counting from 1 Now, I have a file that has over 100 lines. When I run git blame -L 5,15 myFile.txt, git complains: fatal: bad revision…
Shaun Luttin
  • 133,272
  • 81
  • 405
  • 467
5
votes
1 answer

Installing posh-git in visual studio package manager

I'm trying to install posh-git to the visual studio package manager console (vs 2012) and I'm getting the following error when running .\install.ps1 in the poshgit directory and reloading the profile: Register-TabExpansion : A parameter cannot be…
Daniel Powell
  • 8,143
  • 11
  • 61
  • 108
5
votes
2 answers

How can I make visual studio use the same powershell that Github for windows does

I'm using Github for windows for a non-github project and I am using its powershell prompt. I'd like to configure visual studio to use the same prompt (via package manager). I'd also like to not have to install poshgit separately and maintain 2…
Daniel Powell
  • 8,143
  • 11
  • 61
  • 108
4
votes
2 answers

Proxy Issues with Install Module

Running the following setup: Server 2012 R2 PSVersion: 4.0 WSManStackVersion: 3.0 Git version 2.11.1 Package Management Preview - x64: 10.0.10586.117 SharpZipLib: 0.86.0 NuGet:…
J1raya
  • 320
  • 1
  • 6
  • 20
4
votes
2 answers

Using variables in git alias

I'm trying to create an alias for checking out the master branch and merging the branch I was on before switching. Right now, my alias looks like this: med = "!f() { git checkout master; git merge ${1}; git branch -d ${1}; }; f" It means that every…
ulu
  • 5,872
  • 4
  • 42
  • 51
4
votes
0 answers

The git ssh agent is running but is not saving my username or password

Initial Setup I am using Posh-Git and have followed Phil Haack's advice for using SSH. That is, I have done the following: Install msysgit. Update Posh-Git Add the ssh-agent to PATH. Initial Test Now, when I start Powershell, the ssh-agent does…
Shaun Luttin
  • 133,272
  • 81
  • 405
  • 467
4
votes
1 answer

How to automate a nightly push to a GitHub branch from a live website with powershell and a batch file

I have a live website (served via IIS on a Windows Server 2008 R2) and a github repo on that server as well. I work in a small development team (3 people) and we want to every night, automatically have our live website: Copy from the IIS hosted…
3
votes
1 answer

Not getting Cascadia Code PL in Powershell

I wanted to get started with posh and oh-my-posh so I installed them according to this article. Microsoft docs. I got the theme but the edges didn't had that arrow(that coolness). I then downloaded the windows terminal and edited the setting.json…
Shobhit Tewari
  • 535
  • 5
  • 20
3
votes
1 answer

Is it possible to disable posh-git for individual repositories?

I like the posh-git powershell env for git but on some (very large) repositories it noticeably slows down the ps prompt. I'd like to know if it is possible to disable it on certain specific repositories
Stewart_R
  • 13,764
  • 11
  • 60
  • 106
3
votes
1 answer

When pushing to github, why am I always asked for my ssh password?

Some facts: I'm on Windows 10 I'm using Power Shell with PoshGit (I don't want to use the cygwin bash shell or any derivative thereof) My repositories are all git@..., i.e. they don't use https remotes When I start a new shell session, if not…
Nathan Ridley
  • 33,766
  • 35
  • 123
  • 197
3
votes
2 answers

Powershell commands?

Ok I'm having trouble and google isn't helping, so I thought I'd come to you geniuses. I'm using Powershell and posh-git, and it keeps doing something that I'm sure I can exit out of with a magic command, I just don't know it yet. Basically, when I…
Bobo
  • 976
  • 2
  • 10
  • 25
3
votes
1 answer

posh-git doesn't show branch in package manager console

I installed posh-git for Windows PowerShell and it works great in the shell. However, it is supposed to work in the package manager console as well. It does work but it doesn't show the current branch like the normal powershell window does. I…
CatDadCode
  • 58,507
  • 61
  • 212
  • 318
2
votes
3 answers

Package Manager Console prompt is messed up after installing oh-my-posh

I have oh-my-posh and posh-git installed and added to my Powershell profile, which looks like this Import-Module posh-git Import-Module oh-my-posh oh-my-posh init pwsh --config "$env:POSH_THEMES_PATH\thecyberden.omp.json" | Invoke-Expression I'm…
Ben Rubin
  • 6,909
  • 7
  • 35
  • 82